PCM audio plays back too quickly

For questions and discussion that is NOT (I repeat NOT) specific to a certain Operating System.
karthiksarangan
New Cone
New Cone
Posts: 6
Joined: 03 May 2011 02:40

PCM audio plays back too quickly

Postby karthiksarangan » 03 May 2011 02:59

Hi.

I run vlc on a Core 2 Duo with integrated digital audio (stereo) support on windows 7 ulti. I have a .ogg file that is streamed as audio/L16 via an RTSP Server.
I use vlc to play this stream using rtsp.

vlc plays the audio stream but this playback is quite faster than the playback of the .ogg file. However the audio/L16 stream sounds, music just like the .ogg file. Only the speed of audio stream is much faster. I clicked on media information in vlc, it shows 44100Hz, 2 channels, S16 BE when the audio stream is being played.

Could somebody point me in the right direction / give info on how to resolve this problem.

karthiksarangan
New Cone
New Cone
Posts: 6
Joined: 03 May 2011 02:40

Re: PCM audio plays back too quickly

Postby karthiksarangan » 03 May 2011 03:01

P.S. the .ogg file when played is 44100 Hz, stereo, 16 bit samples. Thanks.

Rémi Denis-Courmont
Developer
Developer
Posts: 15324
Joined: 07 Jun 2004 16:01
VLC version: master
Operating System: Linux
Contact:

Re: PCM audio plays back too quickly

Postby Rémi Denis-Courmont » 03 May 2011 09:11

When RTP (RTSP) is used, VLC must play the file at the speed it is sent by the server. If the server sends the stream too fast, VLC will automatically upsample to keep up.
Rémi Denis-Courmont
https://www.remlab.net/
Private messages soliciting support will be systematically discarded

karthiksarangan
New Cone
New Cone
Posts: 6
Joined: 03 May 2011 02:40

Re: PCM audio plays back too quickly

Postby karthiksarangan » 03 May 2011 10:57

vlc bitrate (i saw content bitrate) matches the stream bitrate.

karthiksarangan
New Cone
New Cone
Posts: 6
Joined: 03 May 2011 02:40

Re: PCM audio plays back too quickly

Postby karthiksarangan » 03 May 2011 13:38

Thanks for replying. I tried reducing the stream rate but then there is a silent period in the music. the music plays too fast then stops and then continues at the same too fast speed repeatedly.

karthiksarangan
New Cone
New Cone
Posts: 6
Joined: 03 May 2011 02:40

Re: PCM audio plays back too quickly

Postby karthiksarangan » 04 May 2011 22:27

The RTP stream is being sent with 350 pcm samples per packet, with a timestamp increasing by 350. The rtp packet is sent every 7.9365 ms. That amount to 1411.2kbps stream. Still the music is played too fast in vlc. Why? Please do reply.

Rémi Denis-Courmont
Developer
Developer
Posts: 15324
Joined: 07 Jun 2004 16:01
VLC version: master
Operating System: Linux
Contact:

Re: PCM audio plays back too quickly

Postby Rémi Denis-Courmont » 05 May 2011 08:38

Your statements are contradictary. VLC cannot play an RTP stream faster than it receives it... because that is physically impossible. (It could play slower, not faster.)
Rémi Denis-Courmont
https://www.remlab.net/
Private messages soliciting support will be systematically discarded

karthiksarangan
New Cone
New Cone
Posts: 6
Joined: 03 May 2011 02:40

Re: PCM audio plays back too quickly

Postby karthiksarangan » 08 May 2011 06:21

My file reader class was the problem. Corrected it, the stream now buzzes often but is legible.


Return to “General VLC media player Troubleshooting”

Who is online

Users browsing this forum: No registered users and 37 guests