mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 04:01:08 +00:00
pass on all possible mime types as hints add extra debug info to detectendless loop
Original commit message from CVS: pass on all possible mime types as hints add extra debug info to detectendless loop
This commit is contained in:
parent
53a8aaa820
commit
2e4e4c9ec9
2 changed files with 20 additions and 5 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2004-02-17 Thomas Vander Stichele <thomas at apestaart dot org>
|
||||||
|
|
||||||
|
* ext/gdk_pixbuf/gstgdkpixbuf.c: (gst_gdk_pixbuf_type_find):
|
||||||
|
pass on all possible mime types as typefind hints
|
||||||
|
|
||||||
2004-02-17 Julien MOUTTE <julien@moutte.net>
|
2004-02-17 Julien MOUTTE <julien@moutte.net>
|
||||||
|
|
||||||
* sys/ximage/ximagesink.c: (gst_ximagesink_ximage_new):
|
* sys/ximage/ximagesink.c: (gst_ximagesink_ximage_new):
|
||||||
|
|
|
@ -403,7 +403,7 @@ gst_gdk_pixbuf_type_find (GstTypeFind *tf, gpointer ignore)
|
||||||
data = gst_type_find_peek (tf, 0, GST_GDK_PIXBUF_TYPE_FIND_SIZE);
|
data = gst_type_find_peek (tf, 0, GST_GDK_PIXBUF_TYPE_FIND_SIZE);
|
||||||
if (data == NULL) return;
|
if (data == NULL) return;
|
||||||
|
|
||||||
GST_DEBUG ("gst_gdk_pixbuf_type_find");
|
GST_DEBUG ("creating new loader");
|
||||||
|
|
||||||
pixbuf_loader = gdk_pixbuf_loader_new();
|
pixbuf_loader = gdk_pixbuf_loader_new();
|
||||||
|
|
||||||
|
@ -414,15 +414,25 @@ gst_gdk_pixbuf_type_find (GstTypeFind *tf, gpointer ignore)
|
||||||
|
|
||||||
if (format != NULL) {
|
if (format != NULL) {
|
||||||
GstCaps *caps;
|
GstCaps *caps;
|
||||||
gchar **mlist = gdk_pixbuf_format_get_mime_types(format);
|
gchar **p;
|
||||||
|
gchar **mlist = gdk_pixbuf_format_get_mime_types (format);
|
||||||
|
|
||||||
caps = gst_caps_new_simple (mlist[0], NULL);
|
for (p = mlist; *p; ++p)
|
||||||
gst_type_find_suggest (tf, GST_TYPE_FIND_MINIMUM, caps);
|
{
|
||||||
gst_caps_free (caps);
|
GST_DEBUG ("suggesting mime type %s", *p);
|
||||||
|
caps = gst_caps_new_simple (*p, NULL);
|
||||||
|
gst_type_find_suggest (tf, GST_TYPE_FIND_MINIMUM, caps);
|
||||||
|
gst_caps_free (caps);
|
||||||
|
}
|
||||||
g_strfreev (mlist);
|
g_strfreev (mlist);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
GST_DEBUG ("closing pixbuf loader, hope it doesn't hang ...");
|
||||||
|
/* librsvg 2.4.x has a bug where it triggers an endless loop in trying
|
||||||
|
to close a gzip that's not an svg; fixed upstream but no good way
|
||||||
|
to work around it */
|
||||||
gdk_pixbuf_loader_close (pixbuf_loader, NULL);
|
gdk_pixbuf_loader_close (pixbuf_loader, NULL);
|
||||||
|
GST_DEBUG ("closed pixbuf loader");
|
||||||
g_object_unref (G_OBJECT (pixbuf_loader));
|
g_object_unref (G_OBJECT (pixbuf_loader));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue