After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 424728 - function that reports which mime types are supported
function that reports which mime types are supported
Status: RESOLVED WONTFIX
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
git master
Other Linux
: Normal enhancement
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2007-03-31 01:38 UTC by Kristof Vansant
Modified: 2011-05-18 13:00 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Kristof Vansant 2007-03-31 01:38:06 UTC
could be handy to use with gtkfilechooser filter

filter = gtk_file_filter_new ();
gtk_file_filter_set_name (filter, _("Media playable with gstreamer"));

get_gstreamer_decoder_mime(gstreamermime);

for(){
gtk_file_filter_add_mime_type (filter, gstreamermime[i]);
}

gtk_file_chooser_add_filter (GTK_FILE_CHOOSER (chooser), filter);

dirty code just as example
Comment 1 Tim-Philipp Müller 2007-04-25 16:49:02 UTC
I can see a few problems with this:

(a) GStreamer doesn't use mime types it uses 'media types'.
    Often these will be the same, but often enough they will
    not (one could create mappings of course, which might
    also be useful for other purposes).

(b) The mime type system in its current form is pretty much
    useless for anything but the most simple media types. For
    container formats (avi, wma/wmv/asf, matroska, quicktime,
    mpeg) it could only really tell you if the container format
    is supported, but not so much if the audio/video within the
    container is actually supported, so it's not really
    particularly useful (IMHO).

(c) I'm not entirely convinced that xdg-mime as used by the
    filechooser dialog returns useful mime types for all
    media formats, or even for the mostcommon formats
   (for example, mpeg transport stream dumps seem to be
    recognised as something different).

And I'm pretty sure there's more that I'm forgetting right now :)
Comment 2 David Schleef 2007-04-25 22:21:16 UTC
Wandering off into pedantry...

There's no such thing as a "MIME type".  There are "MIME media types", which are the same as "Media Types", and the latter term is used almost exclusively in relevant RFCs.  

GStreamer's caps use media types when possible, but also uses a lot of strings that should never, ever, be used outside of GStreamer.  And there is no automatic way to determine which is which.
Comment 3 Sebastian Dröge (slomo) 2011-05-18 13:00:31 UTC
Right, lets close this as WONTFIX then because it's not possible to fix this properly.