Commit f1b435d1 authored by Mark Nauwelaerts's avatar Mark Nauwelaerts

update for riff field rename

parent fc578e76
......@@ -769,11 +769,11 @@ gst_avi_mux_audsink_set_caps (GstPad * pad, GstCaps * vscaps)
switch (fmt) {
case GST_AUDIO_FORMAT_U8:
avipad->auds.blockalign = 8;
avipad->auds.size = 8;
avipad->auds.bits_per_sample = 8;
break;
case GST_AUDIO_FORMAT_S16:
avipad->auds.blockalign = 16;
avipad->auds.size = 16;
avipad->auds.bits_per_sample = 16;
break;
default:
goto refuse_caps;
......@@ -789,7 +789,7 @@ gst_avi_mux_audsink_set_caps (GstPad * pad, GstCaps * vscaps)
/* set some defaults */
avipad->auds.blockalign = 1;
avipad->auds.av_bps = 0;
avipad->auds.size = 16;
avipad->auds.bits_per_sample = 16;
if (!strcmp (mimetype, "audio/mpeg")) {
gint mpegversion;
......@@ -859,12 +859,12 @@ gst_avi_mux_audsink_set_caps (GstPad * pad, GstCaps * vscaps)
avipad->auds.format = GST_RIFF_WAVE_FORMAT_A52;
} else if (!strcmp (mimetype, "audio/x-alaw")) {
avipad->auds.format = GST_RIFF_WAVE_FORMAT_ALAW;
avipad->auds.size = 8;
avipad->auds.bits_per_sample = 8;
avipad->auds.blockalign = avipad->auds.channels;
avipad->auds.av_bps = avipad->auds.blockalign * avipad->auds.rate;
} else if (!strcmp (mimetype, "audio/x-mulaw")) {
avipad->auds.format = GST_RIFF_WAVE_FORMAT_MULAW;
avipad->auds.size = 8;
avipad->auds.bits_per_sample = 8;
avipad->auds.blockalign = avipad->auds.channels;
avipad->auds.av_bps = avipad->auds.blockalign * avipad->auds.rate;
} else if (!strcmp (mimetype, "audio/x-wma")) {
......@@ -1298,7 +1298,7 @@ gst_avi_mux_riff_get_avi_header (GstAviMux * avimux)
hdl &= gst_byte_writer_put_uint32_le (&bw, audpad->auds.rate);
hdl &= gst_byte_writer_put_uint32_le (&bw, audpad->auds.av_bps);
hdl &= gst_byte_writer_put_uint16_le (&bw, audpad->auds.blockalign);
hdl &= gst_byte_writer_put_uint16_le (&bw, audpad->auds.size);
hdl &= gst_byte_writer_put_uint16_le (&bw, audpad->auds.bits_per_sample);
hdl &= gst_byte_writer_put_uint16_le (&bw, codec_size);
if (audpad->auds_codec_data) {
gst_buffer_map (audpad->auds_codec_data, &map, GST_MAP_READ);
......
......@@ -5337,11 +5337,11 @@ gst_matroska_demux_audio_caps (GstMatroskaTrackAudioContext *
auds.rate = GST_READ_UINT32_LE (data + 4);
auds.av_bps = GST_READ_UINT32_LE (data + 8);
auds.blockalign = GST_READ_UINT16_LE (data + 12);
auds.size = GST_READ_UINT16_LE (data + 16);
auds.bits_per_sample = GST_READ_UINT16_LE (data + 16);
/* 18 is the waveformatex size */
codec_data = gst_buffer_new_wrapped_full (GST_MEMORY_FLAG_READONLY,
data + 18, auds.size, 0, auds.size, NULL, NULL);
data + 18, auds.bits_per_sample, 0, auds.bits_per_sample, NULL, NULL);
if (riff_audio_fmt)
*riff_audio_fmt = auds.format;
......
......@@ -1203,7 +1203,7 @@ gst_wavparse_stream_headers (GstWavParse * wav)
wav->rate = header->rate;
wav->channels = header->channels;
wav->blockalign = header->blockalign;
wav->depth = header->size;
wav->depth = header->bits_per_sample;
wav->av_bps = header->av_bps;
wav->vbr = FALSE;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment