mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 20:21:24 +00:00
gst/typefind/gsttypefindfunctions.c: Add simple typefinder for the CELT codec (www.celt-codec.org).
Original commit message from CVS: * gst/typefind/gsttypefindfunctions.c: (celt_type_find), (plugin_init): Add simple typefinder for the CELT codec (www.celt-codec.org).
This commit is contained in:
parent
cd3fef0f39
commit
63b89f5625
2 changed files with 28 additions and 0 deletions
|
@ -1,3 +1,9 @@
|
|||
2008-07-28 Sebastian Dröge <sebastian.droege@collabora.co.uk>
|
||||
|
||||
* gst/typefind/gsttypefindfunctions.c: (celt_type_find),
|
||||
(plugin_init):
|
||||
Add simple typefinder for the CELT codec (www.celt-codec.org).
|
||||
|
||||
2008-07-27 Sebastian Dröge <sebastian.droege@collabora.co.uk>
|
||||
|
||||
Patch by: Jan Gerber <j at oil21 dot org>
|
||||
|
|
|
@ -2530,6 +2530,26 @@ speex_type_find (GstTypeFind * tf, gpointer private)
|
|||
}
|
||||
}
|
||||
|
||||
/*** audio/x-celt ***/
|
||||
|
||||
static GstStaticCaps celt_caps = GST_STATIC_CAPS ("audio/x-celt");
|
||||
|
||||
#define CELT_CAPS (gst_static_caps_get(&celt_caps))
|
||||
static void
|
||||
celt_type_find (GstTypeFind * tf, gpointer private)
|
||||
{
|
||||
guint8 *data = gst_type_find_peek (tf, 0, 8);
|
||||
|
||||
if (data) {
|
||||
/* 8 byte string "CELT " */
|
||||
if (memcmp (data, "CELT ", 8) != 0)
|
||||
return;
|
||||
|
||||
/* TODO: Check other values of the CELT header */
|
||||
gst_type_find_suggest (tf, GST_TYPE_FIND_MAXIMUM, CELT_CAPS);
|
||||
}
|
||||
}
|
||||
|
||||
/*** application/x-ogg-skeleton ***/
|
||||
static GstStaticCaps ogg_skeleton_caps =
|
||||
GST_STATIC_CAPS ("application/x-ogg-skeleton, parsed=(boolean)FALSE");
|
||||
|
@ -3166,6 +3186,8 @@ plugin_init (GstPlugin * plugin)
|
|||
ogmtext_type_find, NULL, OGMTEXT_CAPS, NULL, NULL);
|
||||
TYPE_FIND_REGISTER (plugin, "audio/x-speex", GST_RANK_PRIMARY,
|
||||
speex_type_find, NULL, SPEEX_CAPS, NULL, NULL);
|
||||
TYPE_FIND_REGISTER (plugin, "audio/x-celt", GST_RANK_PRIMARY,
|
||||
celt_type_find, NULL, CELT_CAPS, NULL, NULL);
|
||||
TYPE_FIND_REGISTER (plugin, "application/x-ogg-skeleton", GST_RANK_PRIMARY,
|
||||
oggskel_type_find, NULL, OGG_SKELETON_CAPS, NULL, NULL);
|
||||
TYPE_FIND_REGISTER (plugin, "text/x-cmml", GST_RANK_PRIMARY, cmml_type_find,
|
||||
|
|
Loading…
Reference in a new issue