[gst-devel] type finding

Erik Walthinsen omega at temple-baptist.com
Mon Feb 3 13:34:27 CET 2003

On Mon, 3 Feb 2003, Benjamin Otte wrote:

> I don't think it's a good idea to detect filetypes based on extensions,
> though it might be a nice idea to use it as a hint on which typefind to
> try first.
The src element would only set the mime/type, which isn't sufficient by
itself generally.  It does give a hint though.  There should be a
provision for mime/type to be a strong hint to typefind...

> I think that needed effort should be a parameter when registering the
> typefind func, not when calling it. Mp3 would then register 2 functions,
> one with less effort and one with more effort.
While I think an effort/likeliness/certainty metric would be worth
something, we definitely do *not* want to force plugins to have multiple
typefinds.  If they *want* to do that, we might want to support it.  But
the key thing to keep in mind is that GStreamer's main purpose in life is
to deal with all the hard stuff.  Wherever possible, applications and
elements should not have to code anything that GStreamer can't deal with
in some efficient, reasonable way.  Forcing two typefind functions would
defeat that.

THe primary goal in this case should be to maximize certainty, reduce
effort, and sort be likelihood.  The first two are a function of the
coding of the plugin, the last is a system-wide metric we have to assign
to each plugin, with mp3 being rather high on the list <g>

      Erik Walthinsen <omega at temple-baptist.com> - System Administrator
       /  \                GStreamer - The only way to stream!
      |    | M E G A        ***** http://gstreamer.net/ *****
      _\  /_

More information about the gstreamer-devel mailing list