From 5bb80c9f5359a446d52ad7824095ae4c67bf3cdf Mon Sep 17 00:00:00 2001 From: Benjamin Otte Date: Tue, 28 Oct 2003 20:52:41 +0000 Subject: merge TYPEFIND branch. Major changes: Original commit message from CVS: merge TYPEFIND branch. Major changes: - totally reworked type(find) system - all typefind functions are in gst/typefind now - more typefind functions then before - some plugins might fail to compile now because I don't have them installed and they a) require bytestream or b) haven't had their typefind fixed. Please fix those plugins and put the typefind functions into gst/typefind if they don't have dependencies --- ext/swfdec/gstswfdec.c | 27 --------------------------- 1 file changed, 27 deletions(-) (limited to 'ext/swfdec') diff --git a/ext/swfdec/gstswfdec.c b/ext/swfdec/gstswfdec.c index 58e96e87..78ed29b4 100644 --- a/ext/swfdec/gstswfdec.c +++ b/ext/swfdec/gstswfdec.c @@ -626,34 +626,10 @@ gst_swfdec_get_property (GObject *object, guint prop_id, GValue *value, GParamSp } } -static GstCaps * -swf_type_find(GstByteStream *bs, gpointer private) -{ - GstBuffer *buf; - gchar *data; - - gst_bytestream_peek (bs, &buf, 4); - data = GST_BUFFER_DATA(buf); - - if (GST_BUFFER_SIZE (buf) < 4) - return NULL; - - if((data[0] != 'F' && data[0] != 'C') || - data[1] != 'W' || data[2] != 'S')return NULL; - - return gst_caps_new("swf_type_find","application/x-shockwave-flash", - NULL); -} - -static GstTypeDefinition swftype_definition = - { "swfdecode/x-shockwave-flash", "application/x-shockwave-flash", - ".swf .swfl", swf_type_find }; - static gboolean plugin_init (GModule *module, GstPlugin *plugin) { GstElementFactory *factory; - GstTypeFactory *type; /* create an elementfactory for the swfdec element */ factory = gst_element_factory_new("swfdec",GST_TYPE_SWFDEC, @@ -670,9 +646,6 @@ plugin_init (GModule *module, GstPlugin *plugin) gst_plugin_add_feature (plugin, GST_PLUGIN_FEATURE (factory)); - type = gst_type_factory_new(&swftype_definition); - gst_plugin_add_feature(plugin, GST_PLUGIN_FEATURE(type)); - return TRUE; } -- cgit v1.2.1