gst-libs/gst/riff/: Add WMS caps.

Original commit message from CVS:
* gst-libs/gst/riff/riff-ids.h:
* gst-libs/gst/riff/riff-media.c: (gst_riff_create_audio_caps),
(gst_riff_create_audio_template_caps):
Add WMS caps.
This commit is contained in:
Wim Taymans 2006-10-10 16:50:06 +00:00
parent 4de10dacb6
commit 98b1630fdc
3 changed files with 25 additions and 0 deletions

View file

@ -1,3 +1,10 @@
2006-10-10 Wim Taymans <wim@fluendo.com>
* gst-libs/gst/riff/riff-ids.h:
* gst-libs/gst/riff/riff-media.c: (gst_riff_create_audio_caps),
(gst_riff_create_audio_template_caps):
Add WMS caps.
2006-10-10 Zaheer Abbas Merali <zaheerabbas at merali dot org>
Patch by: Josep Torre Valles <josep@fluendo.com>

View file

@ -280,6 +280,7 @@ typedef struct _gst_riff_strf_auds { /* == WaveHeader (?) */
#define GST_RIFF_WAVE_FORMAT_IBM_CVSD (0x0005)
#define GST_RIFF_WAVE_FORMAT_ALAW (0x0006)
#define GST_RIFF_WAVE_FORMAT_MULAW (0x0007)
#define GST_RIFF_WAVE_FORMAT_WMS (0x000a) /* WMS Windows Media Audio Speech */
#define GST_RIFF_WAVE_FORMAT_OKI_ADPCM (0x0010)
#define GST_RIFF_WAVE_FORMAT_DVI_ADPCM (0x0011)
#define GST_RIFF_WAVE_FORMAT_DIGISTD (0x0015)

View file

@ -805,6 +805,22 @@ gst_riff_create_audio_caps (guint16 codec_id,
*codec_name = g_strdup ("A-law audio");
break;
case GST_RIFF_WAVE_FORMAT_WMS:
caps = gst_caps_new_simple ("audio/x-wms", NULL);
if (strf != NULL) {
gst_caps_set_simple (caps,
"bitrate", G_TYPE_INT, strf->av_bps * 8,
"width", G_TYPE_INT, strf->size,
"depth", G_TYPE_INT, strf->size, NULL);
} else {
gst_caps_set_simple (caps,
"bitrate", GST_TYPE_INT_RANGE, 0, G_MAXINT, NULL);
}
if (codec_name)
*codec_name = g_strdup ("Windows Media Audio Speech");
block_align = TRUE;
break;
case GST_RIFF_WAVE_FORMAT_MULAW:
if (strf != NULL) {
if (strf->size != 8) {
@ -1173,6 +1189,7 @@ gst_riff_create_audio_template_caps (void)
GST_RIFF_WAVE_FORMAT_AAC,
GST_RIFF_WAVE_FORMAT_ALAW,
GST_RIFF_WAVE_FORMAT_MULAW,
GST_RIFF_WAVE_FORMAT_WMS,
GST_RIFF_WAVE_FORMAT_ADPCM,
GST_RIFF_WAVE_FORMAT_DVI_ADPCM,
GST_RIFF_WAVE_FORMAT_WMAV1,