VLC changes pitch/playrate randomly on audio playback

Microsoft Windows specific usage questions
Forum rules
Please post only Windows specific questions in this forum category. If you don't know where to post, please read the different forums' rules. Thanks.
Xpenetrator
New Cone
New Cone
Posts: 7
Joined: 26 Sep 2006 21:33

VLC changes pitch/playrate randomly on audio playback

Postby Xpenetrator » 04 Sep 2008 20:29

Hi,

I think I found a funny but serious glitch: Audio file playback is changing the playrate slightly upwards at times. Being a musician, I'm probably a bit more sensitive to variations in pitch and wondered why VLC sounds sometimes like a broken record player. Now I had this phenomenon again on the 4th computer with a clean VLC 0.8.6i install and decided to document that.

I recorded a 2 minute test tone in my DAW software and rendered it as MP3 (160kBit/s CBR). Then I played the file back in VLC and recorded its output to the next track in the DAW. Here's what it sounds if I playback the two tracks together at the same level:

http://shup.com/Shup/60333/VLC_TestTone_1k_Drift.mp3

Here's the nominal pitch of the test tone (MIDI playable tone generator, hence not exactly 1kHz) played back by VLC:

Image

And here is what happens after a while on VLC playback:

Image

As you can see, the pitch drifts up by 10Hz which is not neglectable.
This does not happen always and it comes at random, but always somewhat into the file, mostly near the end. And it drives me nuts when it happens. :mrgreen: I'm sure the most basic job - playing back audio files (it happens on WAV as well) - is supposed to be working flawlessly and hence I call it a "serious glitch". Since it happens on Windows XP here I posted it in this forum, I hope that was right.

XPenetrator

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: VLC changes pitch/playrate randomly on audio playback

Postby Jean-Baptiste Kempf » 04 Sep 2008 22:07

Hello,

Interesting post ...

Have you tried VLC 0.9.x builds ?
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.

Xpenetrator
New Cone
New Cone
Posts: 7
Joined: 26 Sep 2006 21:33

Re: VLC changes pitch/playrate randomly on audio playback

Postby Xpenetrator » 04 Sep 2008 23:29

Good idea! I just tried 0.9.2 Grishenko (Woo! Cool new GUI!), alas with the same results.
I'm not sure but I think it started somewhere with the latest versions of 0.8.5 but unfortunately I didn't use VLC so much for music at that time and I thought that might be a problem on my side too, so I didn't pay much attention to it.

If I can do something to help busting this little bugger, let me know! :)

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: VLC changes pitch/playrate randomly on audio playback

Postby Jean-Baptiste Kempf » 05 Sep 2008 03:03

Well, 0.8.5 is old and dead. So, let's focus on 0.9.2

You should try the pitch correction module, named scaledtempo in the preferences.
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.

Xpenetrator
New Cone
New Cone
Posts: 7
Joined: 26 Sep 2006 21:33

Re: VLC changes pitch/playrate randomly on audio playback

Postby Xpenetrator » 05 Sep 2008 04:58

I think I can narrow it down now:

VLC seems to use DirectX as default output module. The problem doesn't seem to arise when I select the "waveout extension output" instead. So the culprit is probably in the DirectX output module or maybe even in DirectSound itself, who knows... :)

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: VLC changes pitch/playrate randomly on audio playback

Postby Jean-Baptiste Kempf » 05 Sep 2008 07:12

This is an interesting bug then. Fill it in trac.
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.

Lotesdelere
Cone Master
Cone Master
Posts: 9971
Joined: 08 Sep 2006 04:39
Location: Europe

Re: VLC changes pitch/playrate randomly on audio playback

Postby Lotesdelere » 07 Sep 2008 16:49

VLC seems to use DirectX as default output module. The problem doesn't seem to arise when I select the "waveout extension output" instead. So the culprit is probably in the DirectX output module or maybe even in DirectSound itself, who knows... :)
DirectSound is the default sound output module on NT based systems, WaveOut is still available for compatibilty reasons but it's poorly implemented and should be used as the output module on Windows 9x/ME only.

However I experienced some really audible pitch issues (several tones down) with a MKV video containing H264/AVC video (encoded with x264) and AC-3 audio. Looks like the video was running at normal speed though.
But it's a 23.976 FPS video and the default setting for the H264 and VC-1 demuxers is set to 25 FPS so maybe that's the reason why ?

VLC_help
Mega Cone Master
Mega Cone Master
Posts: 25661
Joined: 13 Sep 2006 14:16

Re: VLC changes pitch/playrate randomly on audio playback

Postby VLC_help » 08 Sep 2008 11:18

I don't think audio decoders use video FPS because they don't need it. Audio doesn't has FPS concept.

brezik.ad
New Cone
New Cone
Posts: 2
Joined: 28 Jan 2021 08:20

Re: VLC changes pitch/playrate randomly on audio playback

Postby brezik.ad » 08 May 2021 14:13

On multiple Android phones vlc slows the rate a bit after starting playback and then speeds up a bit, most probably to compensate. Then it goes back to normal. I've tried every friggin setting there is in the application, yet to no avail.

Also, the last version update on windows started to lose rate every time I use skip and the effect stacks until I stop the playback and stay out again. It stacks heavy. 🤘🏻 But if it stacks some too many times (probably 25 cents or even more) then it goes back up after some 3 seconds.

Both these drive me crazy and also the fact this is the best player for Android, having only usable eq I've found. On win, I used to go Winamp even all these after the support ended, but lately I'm having some crashes and window control issues with multiple screens, so I considered switching to vlc as my primary audio player. Not any more. I'm going back to those crashes and window control issues. The clear playback with no performance problems is my top priority. And also the adorable modern skin.... 🥲

wilsonhenley
New Cone
New Cone
Posts: 2
Joined: 24 Oct 2021 05:41

Re: VLC changes pitch/playrate randomly on audio playback

Postby wilsonhenley » 24 Oct 2021 05:50

(please forgive in advance my bad english, I'm french-canadian)

Oh wow... :(
Thank you for your thorough analysis of the problem. SO glad to see I'm not alone and it's not my ears degenerating. I noticed it a while back but didn't make much of it. I'm a musician too and I like to listen in loop to my recordings - when the songs starts again, it's off-pitch enough for me to scratch my head and wonder if I'm becoming senile - or is my mix total crap?!

After years of this I suddenly decided to google "song offpitch after restart in VLC" and this post was the first one above.

Its. A. Real. Problem. :shock:
I'm using VLC 3.0.16 Vetinari and the problem is OBVIOUS if you take the time to listen correctly. Ayayaye.

Thank you again for your enlightening me,
Wilson H.

Lotesdelere
Cone Master
Cone Master
Posts: 9971
Joined: 08 Sep 2006 04:39
Location: Europe

Re: VLC changes pitch/playrate randomly on audio playback

Postby Lotesdelere » 24 Oct 2021 11:02

when the songs starts again, it's off-pitch

https://forum.videolan.org/viewtopic.php?f=14&t=156965


Return to “VLC media player for Windows Troubleshooting”

Who is online

Users browsing this forum: No registered users and 27 guests