Commit 8ad3f148 authored by Sebastian Dröge's avatar Sebastian Dröge

spc: Add the OpenSPC spc plugin again

The gme plugin obsoletes it but it might still be useful
for users that don't have gme yet or prefer openspc for some reason.
parent 24217ee3
......@@ -1369,6 +1369,22 @@ AG_GST_CHECK_FEATURE(SOUNDTOUCH, [soundtouch plug-in], soundtouch, [
fi
])
dnl *** spc ***
translit(dnm, m, l) AM_CONDITIONAL(USE_SPC, true)
AG_GST_CHECK_FEATURE(SPC, [spc decoder], spc, [
AC_CHECK_HEADER(openspc.h, [
AC_CHECK_LIB(openspc, OSPC_Init, [
SPC_LIBS="-lopenspc"
AC_SUBST(SPC_LIBS)
HAVE_SPC=yes
], [
HAVE_SPC=no
])
], [
HAVE_SPC=no
])
])
dnl *** gme ***
translit(dnm, m, l) AM_CONDITIONAL(USE_GME, true)
AG_GST_CHECK_FEATURE(GME, [gme decoder], gme, [
......@@ -1567,6 +1583,7 @@ AM_CONDITIONAL(USE_SDL, false)
AM_CONDITIONAL(USE_SNDFILE, false)
AM_CONDITIONAL(USE_SOUNDTOUCH, false)
AM_CONDITIONAL(USE_GME, false)
AM_CONDITIONAL(USE_SPC, false)
AM_CONDITIONAL(USE_SWFDEC, false)
AM_CONDITIONAL(USE_THEORADEC, false)
AM_CONDITIONAL(USE_TIMIDITY, false)
......@@ -1768,6 +1785,7 @@ ext/sdl/Makefile
ext/sndfile/Makefile
ext/soundtouch/Makefile
ext/gme/Makefile
ext/spc/Makefile
ext/swfdec/Makefile
ext/theora/Makefile
ext/timidity/Makefile
......
......@@ -306,6 +306,12 @@ else
SOUNDTOUCH_DIR=
endif
if USE_SPC
SPC_DIR=gme
else
SPC_DIR=
endif
if USE_GME
GME_DIR=gme
else
......@@ -393,6 +399,7 @@ SUBDIRS=\
$(SNDFILE_DIR) \
$(SOUNDTOUCH_DIR) \
$(GME_DIR) \
$(SPC_DIR) \
$(SWFDEC_DIR) \
$(TARKIN_DIR) \
$(THEORA_DIR) \
......@@ -439,6 +446,7 @@ DIST_SUBDIRS = \
sdl \
sndfile \
soundtouch \
spc \
gme \
swfdec \
theora \
......
plugin_LTLIBRARIES = libgstspc.la
libgstspc_la_SOURCES = gstspc.c tag.c
libgstspc_la_CFLAGS = $(GST_CFLAGS) $(SPC_CFLAGS)
libgstspc_la_LIBADD = $(GST_LIBS) $(SPC_LIBS)
libgstspc_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
libgstspc_la_LIBTOOLFLAGS = --tag=disable-static
noinst_HEADERS = gstspc.h tag.h
This diff is collapsed.
/* Copyright (C) 2004-2005 Michael Pyne <michael dot pyne at kdemail net>
* Copyright (C) 2004-2006 Chris Lee <clee at kde org>
* Copyright (C) 2007 Brian Koropoff <bkoropoff at gmail com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public
* License along with this library; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#ifndef __GST_SPC_DEC_H__
#define __GST_SPC_DEC_H__
#include <gst/gst.h>
#include <openspc.h>
#include "tag.h"
G_BEGIN_DECLS
#define GST_TYPE_SPC_DEC \
(gst_spc_dec_get_type())
#define GST_SPC_DEC(obj) \
(G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_SPC_DEC,GstSpcDec))
#define GST_SPC_DEC_CLASS(klass) \
(G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_SPC_DEC,GstSpcDecClass))
#define GST_IS_SPC_DEC(obj) \
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_SPC_DEC))
#define GST_IS_SPC_DEC_CLASS(klass) \
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SPC_DEC))
typedef struct _GstSpcDec GstSpcDec;
typedef struct _GstSpcDecClass GstSpcDecClass;
struct _GstSpcDec
{
GstElement element;
GstPad *sinkpad;
GstPad *srcpad;
GstBuffer *buf;
gboolean initialized;
gboolean seeking;
guint32 seekpoint;
spc_tag_info tag_info;
guint32 byte_pos;
};
struct _GstSpcDecClass
{
GstElementClass parent_class;
};
G_END_DECLS
#endif /* __GST_SPC_DEC_H__ */
This diff is collapsed.
/* Copyright (C) 2007 Brian Koropoff <bkoropoff at gmail com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public
* License along with this library; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#include <glib/gtypes.h>
#include <glib.h>
typedef struct
{
gchar *title, *game, *artist, *album, *publisher;
gchar *dumper, *comment;
enum { EMU_SNES9X = 2, EMU_ZSNES = 1, EMU_UNKNOWN = 0 } emulator;
guint8 track, disc, muted, loop_count;
guint16 year;
guint32 time_seconds, time_fade_milliseconds;
guint32 time_intro, time_loop, time_end, time_fade;
guint32 amplification;
GDate *dump_date;
} spc_tag_info;
void spc_tag_clear(spc_tag_info* info);
void spc_tag_get_info(guchar* data, guint length, spc_tag_info* info);
void spc_tag_free(spc_tag_info* info);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment