Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: VLC messes up pitch (Read 19410 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

VLC messes up pitch

Hi all,

Recently I changed my system (KDE's Phonon) to play music through a VLC backend and noticed that pitch wasn't correct. At first I blamed my hearing but I've found out that VLC changes pitch very slightly, about 1%, for the first few seconds of playing a track. This is not only the case with the phonon backend, but also with VLC itself. Apparently (according to the bug reports) this has to do something with resampling, but I don't see why this is so hard to get right in the first place. The thing is: there have been bug reports out for this issue for years, but they don't seem to bother.

Probably only a few people will really notice this difference, but it bothers me that developers audio software that is so widely used don't seem to care about something like a 1% pitch shift, which isn't even constant? Here's a bug report that nicely lists other people noticing this: https://trac.videolan.org/vlc/ticket/10056

Can anyone enlighten me on why this is so hard to get right? Does it bother others? Has anyone else noticed this? I used to recommend VLC, but I think I'll stop doing that
Music: sounds arranged such that they construct feelings.

VLC messes up pitch

Reply #1
Skimming those linked tasks, it sounds like its trying to sync the music to an external clock provided by the OS, and sometimes screws up depending on the power settings?  I actually don't know anything about VLC, but I guess it has to do with how they try to sync audio and video together when playing a movie.  I guess they use the same code even when there is no video.

VLC messes up pitch

Reply #2
While I appreciate what the devs have done with VLC, in my opinion they place a much lower priority on the audio player aspect of VLC. A glaring example is that a project as long lived, mature, and widely used as VLC still doesn't support gapless playback even for codecs that are natively gapless. From the forum posts I've read the general attitude from the devs is they don't care enough to do the necessary work to implement it. Also of note is an 8 year old feature request, still untouched.

https://trac.videolan.org/vlc/ticket/549


VLC messes up pitch

Reply #3
Probably only a few people will really notice this difference
I heard it and always assumed there was something weird on my system causing it. Thanks for the info.

Cheers,
David.

VLC messes up pitch

Reply #4
it bothers me that developers audio software that is so widely used don't seem to care about something like a 1% pitch shift


Video LAN Client is definitely not a music player.

I used to recommend VLC


Please don't, not for music playback.

VLC messes up pitch

Reply #5
it bothers me that developers audio software that is so widely used don't seem to care about something like a 1% pitch shift


Video LAN Client is definitely not a music player.


From the website:
Quote
VLC is a free and open source cross-platform multimedia player and framework that plays most multimedia files as well as DVD, Audio CD, VCD, and various streaming protocols.
daefeatures.co.uk

VLC messes up pitch

Reply #6
The original idea (13 years ago!) behind Video LAN Client was, well, to stream video across a LAN. Music playback is a distant afterthought, as demonstrated here with the pitch bug and lack of gapless playback, neither of which the dev team seems to care about.

VLC messes up pitch

Reply #7
The original idea (13 years ago!) behind Video LAN Client was, well, to stream video across a LAN. Music playback is a distant afterthought, as demonstrated here with the pitch bug and lack of gapless playback, neither of which the dev team seems to care about.

The devs at KDE seem to have a different opinion. http://userbase.kde.org/Phonon#Backend_libraries 

edit: I just filed a bug report there as well, https://bugs.kde.org/show_bug.cgi?id=331954
Music: sounds arranged such that they construct feelings.


VLC messes up pitch

Reply #9
The original idea (13 years ago!) behind Video LAN Client was, well, to stream video across a LAN. Music playback is a distant afterthought, as demonstrated here with the pitch bug and lack of gapless playback, neither of which the dev team seems to care about.

The devs at KDE seem to have a different opinion. http://userbase.kde.org/Phonon#Backend_libraries 

edit: I just filed a bug report there as well, https://bugs.kde.org/show_bug.cgi?id=331954


I'm interested in knowing my they think it is a good idea.

One of the MtGox developers thought it would be a good idea to implement an SSH server/client in php. As a result they got hacked, that's really not what php is good for. Just because devs are working on something doesn't mean it makes real-world sense even if they think it does.

KDE is usually run on *nix systems and I would suggest GStreamer. Xine use to be a popular media backend but I don't hear about it much more.

I was personally never a big fan of VLC's interface, it's only benefit to me is that if I have a media file I can't play with a GStreamer app, chances are VLC can play it. But I rarely run into that scenario now.

VLC messes up pitch

Reply #10
KDE is usually run on *nix systems and I would suggest GStreamer. Xine use to be a popular media backend but I don't hear about it much more.

I was using GStreamer, but for some reason the MP3 decoder is broken. I have the bulk of my collection in FLAC but I got one album in 320kbps MP3 and can clearly hear some ringing when using GStreamer, so I tried a different backend. VLC did a much better job on decoding MP3 but messed up the pitch. I'm back with GStreamer now.
Music: sounds arranged such that they construct feelings.

VLC messes up pitch

Reply #11
KDE is usually run on *nix systems and I would suggest GStreamer. Xine use to be a popular media backend but I don't hear about it much more.

I was using GStreamer, but for some reason the MP3 decoder is broken. I have the bulk of my collection in FLAC but I got one album in 320kbps MP3 and can clearly hear some ringing when using GStreamer, so I tried a different backend. VLC did a much better job on decoding MP3 but messed up the pitch. I'm back with GStreamer now.


Many Linux distrubutions don't ship with an mp3 decoder in GStreamer because of patents. I think Fluendo gives a closed source one away for free, and there is an open-source one based on libmad for decode and liblame for encode that you probably find for your distribution, assuming the problem is you don't have the plugin.

VLC messes up pitch

Reply #12
I haven't noticed problems with pitch, but VLC stubbornly filters/resamples audio even if there is no reason to do so. I'm not even using it for video anymore.
They couldn't even fix a simple hotkey problem for ~5 years.
"I hear it when I see it."

VLC messes up pitch

Reply #13
The claim that VLC is not a "music player", implying that music is unimportant, is ridiculous. How about music videos?  What about the music in movies?  It cannot be avoided that music is integral to many videos, and it is audibly affected by VLC's synchronzation method.

It is an unfortunate reality that our PCs have video and audio hardware with unsynchronized clocks between them, but I see no good reason why VLC's way of synchronizing can't optionally favor preserving audio pitch over avoiding video judder.  In other words, synchronize by dropping or inserting video frames and leave the audio stream intact and unaltered. Make it an option and let the user decide.