[MPlayer-dev-eng] Re: Problems playing non-MPEG streams using RTSP

Ross Finlayson finlayson at live.com
Wed Aug 7 12:04:44 CEST 2002


>as you didn't provided info for the codec, about samplerate etc etc
>the format itself is not sufficient for most codecs, they need the whole
>WAVEFORMATEX (audio) or BITMAPINFOHEADER (video) filled

Thanks Arpi, that was very helpful.  I am now able to receive PCM audio 
streams OK.

I'm still having trouble receiving GSM audio streams, however.  Can you 
tell me what the various WAVEFORMATEX fields should be for GSM?

(Recall that GSM compresses each block of 160 samples into a resulting 
33-byte frame, and that there are 8000 samples/second - so that each 
33-byte frame corresponds to 20 ms (i.e., 50 frames.second).)

Here's what I've been trying:
wf->nChannels = 1;
wf->nSamplesPerSec = 8000;
wf->nAvgBytesPerSec = 1650;  // == 33*50
wf->nBlockAlign = 33;  // IS THIS CORRECT???
wf->wBitsPerSample = 16; // CORRECT??? - the samples have been compressed
wf->cbSize = 0;  // IS THIS CORRECT???

However, I still get the
         ACM_Decoder: Unappropriate audio format
error.

Has gotten the Win32 GSM decoder to work with "mplayer"?  If so, what 
WAVEFORMATEX parameters were used?


>some native codecs, like ac3,mp3 work without these, but it's possible 
>only with
>audio/video formats containing every information (about channels, samplerate
>etc) inside teh audio stream, so don't need extra headers from teh container
>file parser.

Yes, that explains why I had been able to play MPEG streams OK.

         Ross.




More information about the MPlayer-dev-eng mailing list