[MPlayer-cvslog] r29490 - trunk/libmpdemux/demux_rtp_codec.cpp
cehoyos
subversion at mplayerhq.hu
Tue Aug 11 20:07:43 CEST 2009
Author: cehoyos
Date: Tue Aug 11 20:07:43 2009
New Revision: 29490
Log:
Parse BitsPerSample and SamplesPerSec when playing PCM in X-QT over
RTSP.
Modified:
trunk/libmpdemux/demux_rtp_codec.cpp
Modified: trunk/libmpdemux/demux_rtp_codec.cpp
==============================================================================
--- trunk/libmpdemux/demux_rtp_codec.cpp Tue Aug 11 19:56:19 2009 (r29489)
+++ trunk/libmpdemux/demux_rtp_codec.cpp Tue Aug 11 20:07:43 2009 (r29490)
@@ -317,6 +317,10 @@ void rtpCodecInitialize_audio(demuxer_t*
wf->wFormatTag = sh_audio->format = fourcc;
wf->nChannels = numChannels;
+ if (qtRTPSource->qtState.sdAtomSize > 33) {
+ wf->wBitsPerSample = qtRTPSource->qtState.sdAtom[27];
+ wf->nSamplesPerSec = qtRTPSource->qtState.sdAtom[32]<<8|qtRTPSource->qtState.sdAtom[33];
+ }
uint8_t *pos = (uint8_t*)qtRTPSource->qtState.sdAtom + 52;
uint8_t *endpos = (uint8_t*)qtRTPSource->qtState.sdAtom
+ qtRTPSource->qtState.sdAtomSize;
More information about the MPlayer-cvslog
mailing list