diff --git a/ChangeLog b/ChangeLog index 128752c789..734e067335 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,69 @@ +2005-04-24 David Schleef + + * configure.ac: Remove idct and resample libs + * gst-libs/gst/Makefile.am: same + + Remove usage of gst_library_load(): + * ext/alsa/gstalsaplugin.c: (plugin_init): + * ext/libvisual/visual.c: (plugin_init): + * ext/ogg/gstogg.c: (plugin_init): + * ext/theora/theora.c: (plugin_init): + * ext/vorbis/vorbis.c: (plugin_init): + * gst-libs/gst/audio/gstaudiofiltertemplate.c: (plugin_init): + * gst/audioscale/gstaudioscale.c: + * gst/adder/gstadder.c: (plugin_init): + * gst/audioconvert/plugin.c: (plugin_init): + * sys/ximage/ximagesink.c: (plugin_init): + * sys/xvimage/xvimagesink.c: (plugin_init): + * gst/tcp/gsttcpplugin.c: (plugin_init): + + Link plugins against libraries: + * ext/ogg/Makefile.am: + * ext/theora/Makefile.am: + * ext/vorbis/Makefile.am: + * gst/audioconvert/Makefile.am: + + Create proper libraries: + * gst-libs/gst/riff/Makefile.am: + * gst-libs/gst/audio/Makefile.am: + * gst-libs/gst/video/Makefile.am: + + Move resample library to audioscale plugin directory: + * gst-libs/gst/resample/Makefile.am: + * gst-libs/gst/resample/README: + * gst-libs/gst/resample/dtof.c: + * gst-libs/gst/resample/dtos.c: + * gst-libs/gst/resample/functable.c: + * gst-libs/gst/resample/private.h: + * gst-libs/gst/resample/resample.c: + * gst-libs/gst/resample/resample.h: + * gst-libs/gst/resample/resample.vcproj: + * gst-libs/gst/resample/test.c: + * gst/audioscale/Makefile.am: + * gst/audioscale/README: + * gst/audioscale/dtof.c: + * gst/audioscale/dtos.c: + * gst/audioscale/functable.c: + * gst/audioscale/private.h: + * gst/audioscale/resample.c: + * gst/audioscale/resample.h: + * gst/audioscale/test.c: + + Move tagedit library to gst-libs: + * gst-libs/gst/tag/Makefile.am: + * gst-libs/gst/tag/gstid3tag.c: + * gst-libs/gst/tag/gsttagediting.c: + * gst-libs/gst/tag/gsttageditingprivate.h: + * gst-libs/gst/tag/gstvorbistag.c: + * gst/tags/Makefile.am: + * gst/tags/gstid3tag.c: + * gst/tags/gstvorbistag.c: + + Fix for core changes: + * gst/sine/gstsinesrc.c: (gst_sinesrc_class_init), + (gst_sinesrc_init), (gst_sinesrc_src_fixate), (gst_sinesrc_link), + (gst_sinesrc_getrange): + 2005-04-23 David Schleef * gst-libs/gst/Makefile.am: Remove idct. It hasn't been used diff --git a/configure.ac b/configure.ac index 48d2ff2b47..d6703a1dbf 100644 --- a/configure.ac +++ b/configure.ac @@ -902,13 +902,11 @@ gst-libs/gst/audio/Makefile gst-libs/gst/colorbalance/Makefile gst-libs/gst/floatcast/Makefile gst-libs/gst/gconf/Makefile -gst-libs/gst/idct/Makefile gst-libs/gst/media-info/Makefile gst-libs/gst/mixer/Makefile gst-libs/gst/navigation/Makefile gst-libs/gst/play/Makefile gst-libs/gst/propertyprobe/Makefile -gst-libs/gst/resample/Makefile gst-libs/gst/riff/Makefile gst-libs/gst/tag/Makefile gst-libs/gst/tuner/Makefile diff --git a/ext/alsa/gstalsaplugin.c b/ext/alsa/gstalsaplugin.c index 4061f46457..9486c3ade7 100644 --- a/ext/alsa/gstalsaplugin.c +++ b/ext/alsa/gstalsaplugin.c @@ -56,9 +56,6 @@ plugin_init (GstPlugin * plugin) { int err; - if (!gst_library_load ("gstaudio")) - return FALSE; - if (!gst_element_register (plugin, "alsamixer", GST_RANK_NONE, GST_TYPE_ALSA_MIXER)) return FALSE; diff --git a/ext/libvisual/visual.c b/ext/libvisual/visual.c index b1cac80470..28219020b3 100644 --- a/ext/libvisual/visual.c +++ b/ext/libvisual/visual.c @@ -405,9 +405,6 @@ plugin_init (GstPlugin * plugin) guint i; VisList *list; - if (!gst_library_load ("gstbytestream")) - return FALSE; - if (!visual_is_initialized ()) if (visual_init (NULL, NULL) != 0) return FALSE; diff --git a/ext/ogg/Makefile.am b/ext/ogg/Makefile.am index b303c938b5..1f3700a1d7 100644 --- a/ext/ogg/Makefile.am +++ b/ext/ogg/Makefile.am @@ -9,5 +9,7 @@ libgstogg_la_SOURCES = \ gstogmparse.c libgstogg_la_CFLAGS = $(GST_CFLAGS) $(OGG_CFLAGS) -libgstogg_la_LIBADD = $(OGG_LIBS) $(top_builddir)/gst-libs/gst/riff/libgstriff.la +libgstogg_la_LIBADD = $(OGG_LIBS) \ + $(top_builddir)/gst-libs/gst/riff/libgstriff-@GST_MAJORMINOR@.la libgstogg_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) + diff --git a/ext/ogg/gstogg.c b/ext/ogg/gstogg.c index b4ddf00f45..ac0ac23afc 100644 --- a/ext/ogg/gstogg.c +++ b/ext/ogg/gstogg.c @@ -32,9 +32,6 @@ GST_DEBUG_CATEGORY (vorbisdec_debug); static gboolean plugin_init (GstPlugin * plugin) { - if (!gst_library_load ("riff")) - return FALSE; - gst_ogg_demux_plugin_init (plugin); gst_ogg_mux_plugin_init (plugin); gst_ogm_parse_plugin_init (plugin); diff --git a/ext/theora/Makefile.am b/ext/theora/Makefile.am index ee28fcf243..02e8c47019 100644 --- a/ext/theora/Makefile.am +++ b/ext/theora/Makefile.am @@ -2,6 +2,7 @@ plugin_LTLIBRARIES = libgsttheora.la libgsttheora_la_SOURCES = theora.c theoraenc.c theoradec.c libgsttheora_la_CFLAGS = $(GST_CFLAGS) $(THEORA_CFLAGS) -libgsttheora_la_LIBADD = $(THEORA_LIBS) $(top_builddir)/gst/tags/libgsttagedit.la +libgsttheora_la_LIBADD = $(THEORA_LIBS) \ + $(top_builddir)/gst-libs/gst/tag/libgsttagedit-@GST_MAJORMINOR@.la libgsttheora_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) diff --git a/ext/theora/theora.c b/ext/theora/theora.c index 9f82b721b3..44482774ff 100644 --- a/ext/theora/theora.c +++ b/ext/theora/theora.c @@ -29,9 +29,6 @@ extern GType gst_theora_enc_get_type (void); static gboolean plugin_init (GstPlugin * plugin) { - if (!gst_library_load ("gsttags")) - return FALSE; - if (!gst_element_register (plugin, "theoradec", GST_RANK_PRIMARY, gst_theora_dec_get_type ())) return FALSE; diff --git a/ext/vorbis/Makefile.am b/ext/vorbis/Makefile.am index 38fca3ad50..603129935f 100644 --- a/ext/vorbis/Makefile.am +++ b/ext/vorbis/Makefile.am @@ -5,7 +5,8 @@ libgstvorbis_la_SOURCES = vorbis.c \ libgstvorbis_la_CFLAGS = $(GST_CFLAGS) $(VORBIS_CFLAGS) ## AM_PATH_VORBIS also sets VORBISENC_LIBS libgstvorbis_la_LIBADD = $(VORBIS_LIBS) $(VORBISENC_LIBS) $(VORBISFILE_LIBS) \ - $(top_builddir)/gst/tags/libgsttagedit.la + $(top_builddir)/gst-libs/gst/tag/libgsttagedit-@GST_MAJORMINOR@.la \ + $(top_builddir)/gst-libs/gst/audio/libgstaudio-@GST_MAJORMINOR@.la libgstvorbis_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) noinst_HEADERS = vorbisenc.h vorbisdec.h vorbisparse.h diff --git a/ext/vorbis/vorbis.c b/ext/vorbis/vorbis.c index fab0856a87..46f76d7edb 100644 --- a/ext/vorbis/vorbis.c +++ b/ext/vorbis/vorbis.c @@ -32,9 +32,6 @@ GST_DEBUG_CATEGORY (vorbisparse_debug); static gboolean plugin_init (GstPlugin * plugin) { - if (!gst_library_load ("gstaudio") || !gst_library_load ("gsttags")) - return FALSE; - if (!gst_element_register (plugin, "vorbisenc", GST_RANK_NONE, GST_TYPE_VORBISENC)) return FALSE; diff --git a/gst-libs/gst/Makefile.am b/gst-libs/gst/Makefile.am index 40c2d3aef9..b1f7434979 100644 --- a/gst-libs/gst/Makefile.am +++ b/gst-libs/gst/Makefile.am @@ -19,7 +19,6 @@ SUBDIRS = \ mixer \ navigation \ propertyprobe \ - resample \ riff \ tag \ tuner \ @@ -39,7 +38,6 @@ DIST_SUBDIRS = \ navigation \ play \ propertyprobe \ - resample \ riff \ tag \ tuner \ diff --git a/gst-libs/gst/audio/Makefile.am b/gst-libs/gst/audio/Makefile.am index 58d9c219fb..1437091f61 100644 --- a/gst-libs/gst/audio/Makefile.am +++ b/gst-libs/gst/audio/Makefile.am @@ -7,24 +7,23 @@ built_sources = multichannel-enumtypes.c built_headers = multichannel-enumtypes.h BUILT_SOURCES = $(built_sources) $(built_headers) -librarydir = $(libdir)/gstreamer-@GST_MAJORMINOR@ - -library_LTLIBRARIES = libgstaudio.la libgstaudiofilter.la +lib_LTLIBRARIES = libgstaudio-@GST_MAJORMINOR@.la libgstaudiofilter-@GST_MAJORMINOR@.la noinst_LTLIBRARIES = libgstaudiofilterexample.la EXTRA_DIST = gstaudiofiltertemplate.c make_filter CLEANFILES = gstaudiofilterexample.c \ $(BUILT_SOURCES) -libgstaudio_la_SOURCES = audio.c audioclock.c \ +libgstaudio_@GST_MAJORMINOR@_la_SOURCES = audio.c audioclock.c \ multichannel.c \ gstaudiosink.c \ gstbaseaudiosink.c \ - gstringbuffer.c + gstringbuffer.c \ + multichannel-enumtypes.c nodist_libgstaudio_la_SOURCES = $(built_sources) -libgstaudioincludedir = $(includedir)/gstreamer-@GST_MAJORMINOR@/gst/audio -libgstaudioinclude_HEADERS = \ +libgstaudio_@GST_MAJORMINOR@includedir = $(includedir)/gstreamer-@GST_MAJORMINOR@/gst/audio +libgstaudio_@GST_MAJORMINOR@include_HEADERS = \ audio.h \ audioclock.h \ gstaudiofilter.h \ @@ -34,13 +33,13 @@ libgstaudioinclude_HEADERS = \ multichannel.h \ multichannel-enumtypes.h -libgstaudio_la_LIBADD = -libgstaudio_la_CFLAGS = $(GST_CFLAGS) -libgstaudio_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) $(GST_BASE_LIBS) +libgstaudio_@GST_MAJORMINOR@_la_LIBADD = +libgstaudio_@GST_MAJORMINOR@_la_CFLAGS = $(GST_CFLAGS) +libgstaudio_@GST_MAJORMINOR@_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) $(GST_BASE_LIBS) -libgstaudiofilter_la_SOURCES = gstaudiofilter.c gstaudiofilter.h -libgstaudiofilter_la_CFLAGS = $(GST_CFLAGS) -libgstaudiofilter_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) +libgstaudiofilter_@GST_MAJORMINOR@_la_SOURCES = gstaudiofilter.c gstaudiofilter.h +libgstaudiofilter_@GST_MAJORMINOR@_la_CFLAGS = $(GST_CFLAGS) +libgstaudiofilter_@GST_MAJORMINOR@_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) libgstaudiofilterexample_la_SOURCES = gstaudiofilterexample.c libgstaudiofilterexample_la_CFLAGS = $(GST_CFLAGS) diff --git a/gst-libs/gst/audio/gstaudiofiltertemplate.c b/gst-libs/gst/audio/gstaudiofiltertemplate.c index f18520377a..508aa11fff 100644 --- a/gst-libs/gst/audio/gstaudiofiltertemplate.c +++ b/gst-libs/gst/audio/gstaudiofiltertemplate.c @@ -210,9 +210,6 @@ gst_audiofilter_template_get_property (GObject * object, guint prop_id, static gboolean plugin_init (GstPlugin * plugin) { - if (!gst_library_load ("gstaudiofilter")) - return FALSE; - return gst_element_register (plugin, "audiofiltertemplate", GST_RANK_NONE, GST_TYPE_AUDIOFILTER_TEMPLATE); } diff --git a/gst-libs/gst/resample/Makefile.am b/gst-libs/gst/resample/Makefile.am deleted file mode 100644 index 94ebea5bbc..0000000000 --- a/gst-libs/gst/resample/Makefile.am +++ /dev/null @@ -1,14 +0,0 @@ -librarydir = $(libdir)/gstreamer-@GST_MAJORMINOR@ - -library_LTLIBRARIES = libgstresample.la - -libgstresample_la_SOURCES = dtos.c dtof.c functable.c resample.c resample.h -libgstresample_la_LIBADD = -libgstresample_la_CFLAGS = $(GST_CFLAGS) -libgstresample_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) - -libgstresampleincludedir = $(includedir)/gstreamer-@GST_MAJORMINOR@/gst/resample -libgstresampleinclude_HEADERS = resample.h - -noinst_HEADERS = private.h - diff --git a/gst-libs/gst/resample/resample.vcproj b/gst-libs/gst/resample/resample.vcproj deleted file mode 100644 index 18d8812a71..0000000000 --- a/gst-libs/gst/resample/resample.vcproj +++ /dev/null @@ -1,156 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/gst-libs/gst/riff/Makefile.am b/gst-libs/gst/riff/Makefile.am index 03cd8d5457..0ca9fea74b 100644 --- a/gst-libs/gst/riff/Makefile.am +++ b/gst-libs/gst/riff/Makefile.am @@ -1,16 +1,16 @@ -plugin_LTLIBRARIES = libgstriff.la +lib_LTLIBRARIES = libgstriff-@GST_MAJORMINOR@.la -libgstriff_la_SOURCES = \ +libgstriff_@GST_MAJORMINOR@_la_SOURCES = \ riff.c \ riff-media.c \ riff-read.c -libgstriffincludedir = $(includedir)/gstreamer-@GST_MAJORMINOR@/gst/riff -libgstriffinclude_HEADERS = \ +libgstriff_@GST_MAJORMINOR@includedir = $(includedir)/gstreamer-@GST_MAJORMINOR@/gst/riff +libgstriff_@GST_MAJORMINOR@include_HEADERS = \ riff-ids.h \ riff-media.h \ riff-read.h -libgstriff_la_LIBADD = -libgstriff_la_CFLAGS = $(GST_CFLAGS) -libgstriff_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) +libgstriff_@GST_MAJORMINOR@_la_LIBADD = +libgstriff_@GST_MAJORMINOR@_la_CFLAGS = $(GST_CFLAGS) +libgstriff_@GST_MAJORMINOR@_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) diff --git a/gst-libs/gst/tag/Makefile.am b/gst-libs/gst/tag/Makefile.am index 002d6ffbfa..02add72d2b 100644 --- a/gst-libs/gst/tag/Makefile.am +++ b/gst-libs/gst/tag/Makefile.am @@ -3,3 +3,13 @@ libgsttagincludedir = \ libgsttaginclude_HEADERS = \ tag.h + +lib_LTLIBRARIES = libgsttagedit-@GST_MAJORMINOR@.la + +libgsttagedit_@GST_MAJORMINOR@_la_SOURCES = gstvorbistag.c gsttagediting.c gstid3tag.c +libgsttagedit_@GST_MAJORMINOR@_la_CFLAGS = $(GST_CFLAGS) -I$(top_srcdir)/gst/tags +libgsttagedit_@GST_MAJORMINOR@_la_LIBADD = $(GST_LIBS) +libgsttagedit_@GST_MAJORMINOR@_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) + +noinst_HEADERS = gsttageditingprivate.h + diff --git a/gst/tags/gstid3tag.c b/gst-libs/gst/tag/gstid3tag.c similarity index 100% rename from gst/tags/gstid3tag.c rename to gst-libs/gst/tag/gstid3tag.c diff --git a/gst-libs/gst/tag/gsttagediting.c b/gst-libs/gst/tag/gsttagediting.c new file mode 100644 index 0000000000..e02dce3c35 --- /dev/null +++ b/gst-libs/gst/tag/gsttagediting.c @@ -0,0 +1,44 @@ +/* GStreamer + * Copyright (C) 2003 Benjamin Otte + * + * gsttagediting.c: tag editing plugin + * + * 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. + */ + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#include "gsttageditingprivate.h" +#include + +static gboolean +plugin_init (GstPlugin * plugin) +{ + if (!gst_element_register (plugin, "vorbistag", + GST_RANK_PRIMARY, gst_vorbis_tag_get_type ())) { + return FALSE; + } + + return TRUE; +} + +GST_PLUGIN_DEFINE (GST_VERSION_MAJOR, + GST_VERSION_MINOR, + "gsttags", + "elements for manipulating data from ogg streams", + plugin_init, VERSION, GST_LICENSE, GST_PACKAGE, GST_ORIGIN) diff --git a/gst-libs/gst/tag/gsttageditingprivate.h b/gst-libs/gst/tag/gsttageditingprivate.h new file mode 100644 index 0000000000..04ae4f8277 --- /dev/null +++ b/gst-libs/gst/tag/gsttageditingprivate.h @@ -0,0 +1,41 @@ +/* GStreamer + * Copyright (C) 2003 Benjamin Otte + * + * 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_TAG_EDIT_PRIVATE_H__ +#define __GST_TAG_EDIT_PRIVATE_H__ + +#include + +G_BEGIN_DECLS + + +typedef struct _GstTagEntryMatch GstTagEntryMatch; +struct _GstTagEntryMatch { + gchar * gstreamer_tag; + gchar * original_tag; +}; + + +GType gst_vorbis_tag_get_type (void); + + +G_END_DECLS + +#endif /* __GST_TAG_EDIT_PRIVATE_H__ */ diff --git a/gst/tags/gstvorbistag.c b/gst-libs/gst/tag/gstvorbistag.c similarity index 100% rename from gst/tags/gstvorbistag.c rename to gst-libs/gst/tag/gstvorbistag.c diff --git a/gst-libs/gst/video/Makefile.am b/gst-libs/gst/video/Makefile.am index cbc40d67f3..760b39f7c5 100644 --- a/gst-libs/gst/video/Makefile.am +++ b/gst-libs/gst/video/Makefile.am @@ -1,12 +1,11 @@ -librarydir = $(libdir)/gstreamer-@GST_MAJORMINOR@ -library_LTLIBRARIES = libgstvideo.la +lib_LTLIBRARIES = libgstvideo-@GST_MAJORMINOR@.la -libgstvideo_la_SOURCES = video.c gstvideosink.c +libgstvideo_@GST_MAJORMINOR@_la_SOURCES = video.c gstvideosink.c libgstvideoincludedir = $(includedir)/gstreamer-@GST_MAJORMINOR@/gst/video libgstvideoinclude_HEADERS = video.h videosink.h -libgstvideo_la_LIBADD = -libgstvideo_la_CFLAGS = $(GST_CFLAGS) -libgstvideo_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) $(GST_BASE_LIBS) +libgstvideo_@GST_MAJORMINOR@_la_LIBADD = +libgstvideo_@GST_MAJORMINOR@_la_CFLAGS = $(GST_CFLAGS) +libgstvideo_@GST_MAJORMINOR@_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) $(GST_BASE_LIBS) diff --git a/gst/adder/gstadder.c b/gst/adder/gstadder.c index 9e1e82872e..63478e494a 100644 --- a/gst/adder/gstadder.c +++ b/gst/adder/gstadder.c @@ -517,9 +517,6 @@ gst_adder_change_state (GstElement * element) static gboolean plugin_init (GstPlugin * plugin) { - if (!gst_library_load ("gstbytestream")) - return FALSE; - if (!gst_element_register (plugin, "adder", GST_RANK_NONE, GST_TYPE_ADDER)) { return FALSE; } diff --git a/gst/audioconvert/Makefile.am b/gst/audioconvert/Makefile.am index 9ee562ef30..66d2f00ee5 100644 --- a/gst/audioconvert/Makefile.am +++ b/gst/audioconvert/Makefile.am @@ -8,15 +8,17 @@ libgstaudioconvert_la_SOURCES = \ libgstaudioconvert_la_CFLAGS = $(GST_CFLAGS) libgstaudioconvert_la_LIBADD = -libgstaudioconvert_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) $(top_builddir)/gst-libs/gst/audio/libgstaudio.la +libgstaudioconvert_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) \ + $(top_builddir)/gst-libs/gst/audio/libgstaudio-@GST_MAJORMINOR@.la noinst_HEADERS = \ gstchannelmix.h \ plugin.h -TESTS = channelmixtest -noinst_PROGRAMS = channelmixtest +#TESTS = channelmixtest +#noinst_PROGRAMS = channelmixtest channelmixtest_CFLAGS = $(GST_CFLAGS) -channelmixtest_LDADD = libgstaudioconvert.la $(top_builddir)/gst-libs/gst/audio/libgstaudio.la +channelmixtest_LDADD = libgstaudioconvert.la \ + $(top_builddir)/gst-libs/gst/audio/libgstaudio-@GST_MAJORMINOR@.la channelmixtest_LDFLAGS = $(GST_LIBS) diff --git a/gst/audioconvert/plugin.c b/gst/audioconvert/plugin.c index 8f765c1eb7..aeb1b96868 100644 --- a/gst/audioconvert/plugin.c +++ b/gst/audioconvert/plugin.c @@ -28,9 +28,6 @@ static gboolean plugin_init (GstPlugin * plugin) { - if (!gst_library_load ("gstaudio")) - return FALSE; - if (!gst_element_register (plugin, "audioconvert", GST_RANK_PRIMARY, gst_audio_convert_get_type ()) || !gst_element_register (plugin, "buffer-frames-convert", diff --git a/gst/audioscale/Makefile.am b/gst/audioscale/Makefile.am index bd54146d15..ea24f4f37a 100644 --- a/gst/audioscale/Makefile.am +++ b/gst/audioscale/Makefile.am @@ -1,9 +1,17 @@ -plugin_LTLIBRARIES = libgstaudioscale.la +#plugin_LTLIBRARIES = libgstaudioscale.la +noinst_LTLIBRARIES = libgstresample.la libgstaudioscale_la_SOURCES = gstaudioscale.c libgstaudioscale_la_CFLAGS = $(GST_CFLAGS) libgstaudioscale_la_LIBADD = libgstaudioscale_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) -noinst_HEADERS = gstaudioscale.h +noinst_HEADERS = gstaudioscale.h private.h + +libgstresample_la_SOURCES = dtos.c dtof.c functable.c resample.c resample.h +libgstresample_la_LIBADD = +libgstresample_la_CFLAGS = $(GST_CFLAGS) +libgstresample_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) + + diff --git a/gst-libs/gst/resample/README b/gst/audioscale/README similarity index 100% rename from gst-libs/gst/resample/README rename to gst/audioscale/README diff --git a/gst-libs/gst/resample/dtof.c b/gst/audioscale/dtof.c similarity index 100% rename from gst-libs/gst/resample/dtof.c rename to gst/audioscale/dtof.c diff --git a/gst-libs/gst/resample/dtos.c b/gst/audioscale/dtos.c similarity index 100% rename from gst-libs/gst/resample/dtos.c rename to gst/audioscale/dtos.c diff --git a/gst-libs/gst/resample/functable.c b/gst/audioscale/functable.c similarity index 100% rename from gst-libs/gst/resample/functable.c rename to gst/audioscale/functable.c diff --git a/gst/audioscale/gstaudioscale.c b/gst/audioscale/gstaudioscale.c index c0e7c0701b..1dffa6117b 100644 --- a/gst/audioscale/gstaudioscale.c +++ b/gst/audioscale/gstaudioscale.c @@ -726,10 +726,6 @@ gst_audioscale_get_property (GObject * object, guint prop_id, static gboolean plugin_init (GstPlugin * plugin) { - /* load support library */ - if (!gst_library_load ("gstresample")) - return FALSE; - if (!gst_element_register (plugin, "audioscale", GST_RANK_SECONDARY, GST_TYPE_AUDIOSCALE)) { return FALSE; diff --git a/gst-libs/gst/resample/private.h b/gst/audioscale/private.h similarity index 100% rename from gst-libs/gst/resample/private.h rename to gst/audioscale/private.h diff --git a/gst-libs/gst/resample/resample.c b/gst/audioscale/resample.c similarity index 99% rename from gst-libs/gst/resample/resample.c rename to gst/audioscale/resample.c index c73b118634..3622655e64 100644 --- a/gst-libs/gst/resample/resample.c +++ b/gst/audioscale/resample.c @@ -268,8 +268,7 @@ gst_resample_nearest_s16 (gst_resample_t * r) SCALE_LOOP (o_ptr[0] = i_ptr[0], 1); break; case 2: - SCALE_LOOP (o_ptr[0] = i_ptr[0]; - o_ptr[1] = i_ptr[1], 2); + SCALE_LOOP (o_ptr[0] = i_ptr[0]; o_ptr[1] = i_ptr[1], 2); break; default: { @@ -630,8 +629,7 @@ gst_resample_nearest_float (gst_resample_t * r) SCALE_LOOP (o_ptr[0] = i_ptr[0], 1); break; case 2: - SCALE_LOOP (o_ptr[0] = i_ptr[0]; - o_ptr[1] = i_ptr[1], 2); + SCALE_LOOP (o_ptr[0] = i_ptr[0]; o_ptr[1] = i_ptr[1], 2); break; default: { diff --git a/gst-libs/gst/resample/resample.h b/gst/audioscale/resample.h similarity index 100% rename from gst-libs/gst/resample/resample.h rename to gst/audioscale/resample.h diff --git a/gst-libs/gst/resample/test.c b/gst/audioscale/test.c similarity index 100% rename from gst-libs/gst/resample/test.c rename to gst/audioscale/test.c diff --git a/gst/sine/gstsinesrc.c b/gst/sine/gstsinesrc.c index 838e7107e4..962d8c05e1 100644 --- a/gst/sine/gstsinesrc.c +++ b/gst/sine/gstsinesrc.c @@ -76,7 +76,7 @@ static void gst_sinesrc_set_property (GObject * object, guint prop_id, const GValue * value, GParamSpec * pspec); static void gst_sinesrc_get_property (GObject * object, guint prop_id, GValue * value, GParamSpec * pspec); -static GstPadLinkReturn gst_sinesrc_link (GstPad * pad, const GstCaps * caps); +static GstPadLinkReturn gst_sinesrc_link (GstPad * pad, GstPad * peerpad); static GstElementStateReturn gst_sinesrc_change_state (GstElement * element); static void gst_sinesrc_set_clock (GstElement * element, GstClock * clock); @@ -88,8 +88,9 @@ static const GstQueryType *gst_sinesrc_get_query_types (GstPad * pad); static gboolean gst_sinesrc_src_query (GstPad * pad, GstQueryType type, GstFormat * format, gint64 * value); -static GstData *gst_sinesrc_get (GstPad * pad); -static GstCaps *gst_sinesrc_src_fixate (GstPad * pad, const GstCaps * caps); +static GstFlowReturn gst_sinesrc_getrange (GstPad * pad, guint64 offset, + guint length, GstBuffer ** buffer); +static GstCaps *gst_sinesrc_src_fixate (GstPad * pad, GstCaps * caps); static GstElementClass *parent_class = NULL; @@ -136,7 +137,11 @@ gst_sinesrc_class_init (GstSineSrcClass * klass) parent_class = g_type_class_ref (GST_TYPE_ELEMENT); - g_object_class_install_property (G_OBJECT_CLASS (klass), ARG_TABLESIZE, + gobject_class->set_property = gst_sinesrc_set_property; + gobject_class->get_property = gst_sinesrc_get_property; + gobject_class->dispose = gst_sinesrc_dispose; + + g_object_class_install_property (gobject_class, ARG_TABLESIZE, g_param_spec_int ("tablesize", "tablesize", "tablesize", 1, G_MAXINT, 1024, G_PARAM_READWRITE)); g_object_class_install_property (G_OBJECT_CLASS (klass), @@ -144,20 +149,16 @@ gst_sinesrc_class_init (GstSineSrcClass * klass) g_param_spec_int ("samplesperbuffer", "Samples per buffer", "Number of samples in each outgoing buffer", 1, G_MAXINT, 1024, G_PARAM_READWRITE)); - g_object_class_install_property (G_OBJECT_CLASS (klass), ARG_FREQ, + g_object_class_install_property (gobject_class, ARG_FREQ, g_param_spec_double ("freq", "Frequency", "Frequency of sine source", 0.0, 20000.0, 440.0, G_PARAM_READWRITE)); - g_object_class_install_property (G_OBJECT_CLASS (klass), ARG_VOLUME, + g_object_class_install_property (gobject_class, ARG_VOLUME, g_param_spec_double ("volume", "Volume", "Volume", 0.0, 1.0, 0.8, G_PARAM_READWRITE)); - g_object_class_install_property (G_OBJECT_CLASS (klass), ARG_SYNC, + g_object_class_install_property (gobject_class, ARG_SYNC, g_param_spec_boolean ("sync", "Sync", "Synchronize to clock", FALSE, G_PARAM_READWRITE)); - gobject_class->set_property = gst_sinesrc_set_property; - gobject_class->get_property = gst_sinesrc_get_property; - gobject_class->dispose = gst_sinesrc_dispose; - gstelement_class->change_state = gst_sinesrc_change_state; gstelement_class->set_clock = gst_sinesrc_set_clock; } @@ -169,8 +170,8 @@ gst_sinesrc_init (GstSineSrc * src) gst_pad_new_from_template (gst_static_pad_template_get (&gst_sinesrc_src_template), "src"); gst_pad_set_link_function (src->srcpad, gst_sinesrc_link); - gst_pad_set_fixate_function (src->srcpad, gst_sinesrc_src_fixate); - gst_pad_set_get_function (src->srcpad, gst_sinesrc_get); + gst_pad_set_fixatecaps_function (src->srcpad, gst_sinesrc_src_fixate); + gst_pad_set_getrange_function (src->srcpad, gst_sinesrc_getrange); gst_pad_set_query_function (src->srcpad, gst_sinesrc_src_query); gst_pad_set_query_type_function (src->srcpad, gst_sinesrc_get_query_types); gst_element_add_pad (GST_ELEMENT (src), src->srcpad); @@ -227,7 +228,7 @@ gst_sinesrc_set_clock (GstElement * element, GstClock * clock) } static GstCaps * -gst_sinesrc_src_fixate (GstPad * pad, const GstCaps * caps) +gst_sinesrc_src_fixate (GstPad * pad, GstCaps * caps) { GstStructure *structure; GstCaps *newcaps; @@ -242,13 +243,14 @@ gst_sinesrc_src_fixate (GstPad * pad, const GstCaps * caps) return newcaps; } - gst_caps_free (newcaps); + gst_caps_unref (newcaps); return NULL; } static GstPadLinkReturn -gst_sinesrc_link (GstPad * pad, const GstCaps * caps) +gst_sinesrc_link (GstPad * pad, GstPad * peerpad) { + GstCaps *caps; GstSineSrc *sinesrc; const GstStructure *structure; gboolean ret; @@ -256,6 +258,7 @@ gst_sinesrc_link (GstPad * pad, const GstCaps * caps) GST_DEBUG ("gst_sinesrc_src_link"); sinesrc = GST_SINESRC (gst_pad_get_parent (pad)); + caps = gst_pad_get_caps (pad); structure = gst_caps_get_structure (caps, 0); ret = gst_structure_get_int (structure, "rate", &sinesrc->samplerate); @@ -312,8 +315,9 @@ gst_sinesrc_src_query (GstPad * pad, return res; } -static GstData * -gst_sinesrc_get (GstPad * pad) +static GstFlowReturn +gst_sinesrc_getrange (GstPad * pad, guint64 offset, + guint length, GstBuffer ** buffer) { GstSineSrc *src; GstBuffer *buf; @@ -322,7 +326,7 @@ gst_sinesrc_get (GstPad * pad) gint16 *samples; gint i = 0; - g_return_val_if_fail (pad != NULL, NULL); + g_return_val_if_fail (pad != NULL, GST_FLOW_ERROR); src = GST_SINESRC (gst_pad_get_parent (pad)); if (!src->tags_pushed) { @@ -334,10 +338,13 @@ gst_sinesrc_get (GstPad * pad) gst_tag_list_add (taglist, GST_TAG_MERGE_APPEND, GST_TAG_DESCRIPTION, "sine wave", NULL); +#if 0 gst_element_found_tags (GST_ELEMENT (src), taglist); +#endif event = gst_event_new_tag (taglist); src->tags_pushed = TRUE; - return GST_DATA (event); + *buffer = GST_BUFFER (event); + return GST_FLOW_OK; } tdiff = src->samples_per_buffer * GST_SECOND / src->samplerate; @@ -348,7 +355,9 @@ gst_sinesrc_get (GstPad * pad) GST_BUFFER_TIMESTAMP (buf) = src->timestamp; if (src->sync) { if (src->clock) { +#if 0 gst_element_wait (GST_ELEMENT (src), GST_BUFFER_TIMESTAMP (buf)); +#endif } } /* offset is the number of samples */ @@ -400,6 +409,7 @@ gst_sinesrc_get (GstPad * pad) i++; } +#if 0 if (!GST_PAD_CAPS (src->srcpad)) { if (gst_sinesrc_link (src->srcpad, gst_pad_get_allowed_caps (src->srcpad)) <= 0) { @@ -407,8 +417,10 @@ gst_sinesrc_get (GstPad * pad) return NULL; } } +#endif - return GST_DATA (buf); + *buffer = buf; + return GST_FLOW_OK; } static void diff --git a/gst/tags/Makefile.am b/gst/tags/Makefile.am index 07cf79ec76..9cc87ac3f8 100644 --- a/gst/tags/Makefile.am +++ b/gst/tags/Makefile.am @@ -1,7 +1,7 @@ plugin_LTLIBRARIES = libgsttagedit.la -libgsttagedit_la_SOURCES = gstvorbistag.c gsttagediting.c gstid3tag.c +libgsttagedit_la_SOURCES = gsttagediting.c libgsttagedit_la_CFLAGS = $(GST_CFLAGS) -I$(top_srcdir)/gst/tags libgsttagedit_la_LIBADD = $(GST_LIBS) libgsttagedit_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) diff --git a/gst/tcp/gsttcpplugin.c b/gst/tcp/gsttcpplugin.c index 0e9c9ee030..369bdd3b98 100644 --- a/gst/tcp/gsttcpplugin.c +++ b/gst/tcp/gsttcpplugin.c @@ -34,9 +34,6 @@ GST_DEBUG_CATEGORY (tcp_debug); static gboolean plugin_init (GstPlugin * plugin) { - if (!gst_library_load ("gstdataprotocol")) - return FALSE; - if (!gst_element_register (plugin, "tcpsink", GST_RANK_NONE, GST_TYPE_TCPSINK)) return FALSE; diff --git a/sys/ximage/ximagesink.c b/sys/ximage/ximagesink.c index 20ae85d2df..e2e5bba6e0 100644 --- a/sys/ximage/ximagesink.c +++ b/sys/ximage/ximagesink.c @@ -1767,10 +1767,6 @@ gst_ximagesink_get_type (void) static gboolean plugin_init (GstPlugin * plugin) { - /* Loading the library containing GstVideoSink, our parent object */ - if (!gst_library_load ("gstvideo")) - return FALSE; - if (!gst_element_register (plugin, "ximagesink", GST_RANK_SECONDARY, GST_TYPE_XIMAGESINK)) return FALSE; diff --git a/sys/xvimage/xvimagesink.c b/sys/xvimage/xvimagesink.c index 5bc66371ed..3732b82343 100644 --- a/sys/xvimage/xvimagesink.c +++ b/sys/xvimage/xvimagesink.c @@ -2166,10 +2166,6 @@ gst_xvimagesink_get_type (void) static gboolean plugin_init (GstPlugin * plugin) { - /* Loading the library containing GstVideoSink, our parent object */ - if (!gst_library_load ("gstvideo")) - return FALSE; - if (!gst_element_register (plugin, "xvimagesink", GST_RANK_PRIMARY, GST_TYPE_XVIMAGESINK)) return FALSE;