What might cause tracks to be out of tune when exported?

Hi all,

When recording a simple 3 track backing track (bass, drums, guitar) I have noticed that, sometimes, if I play it back within audacity, it sounds perfectly in tune and I can play along to it fine in real time. However, when exporting the track to a wav file and playing over that in real time (outside Audacity), it is very very slightly flat. I am wondering what might cause this.

I reiterate that this doesn’t happen all the time, which makes the problem stranger.

Are there any common conversion/exporting issues that can cause very subtle pitch changes (not quality, that’s not the issue here) in the finished audio that I should know about? I know 100% certain it is not simply my guitar going out of tune for playback, as I retune it to double check.

Here is how I am recording/exporting:

Record: 48khz, 24-bit, stereo
Export to: wav, 44khz, 16-bit, stereo

Any suggestions appreciated!

Mike

By “slightly” out of tune do you mean 44/48ths (~92%) speed ?.

Hmm, never thought about it in terms of speed before. The exported tracks I have noticed this on have been more like 99% speed if that was the factor altering the pitch! It is very subtle and admittingly I am a bit of a perfectionist when it comes to pitch accuracy!

I have been playing around with it today and it has been exporting fine. I can’t think of another explanation why it would occur so infrequently.

Anyway, I was just wondering if there are any factors known to affect the actual pitch of exported audio from Audacity. E.g. hardware? Compression? Dithering on/off?

Cheers

What I was getting at is if you just change the sample rate but don’t resample the track it will run ~8% slower (flat).
A before after example is attached of the sample rate being changed from 48KHz to 44.1KHz but without resampling (it goes flat).
48KHz to 44KHz conversion (before and after).zip (172 KB)

Thanks for that. Sorry, can’t listen to audio as am at work at the moment!

When I export, am I right in that Audacity will automatically resample the tracks if you select a lower rate from the bottom left drop down menu?

Changing the sample rate on that menu will also change the speed (and pitch) of your track.

You need to resample before exporting to avoid this speed/pitch change. In Audacity 1.3 “Resample” is in the “Tracks” menu.

Just listened to that audio clip you linked to (thanks for that)… it doesn’t seem to be as dramatic a shift in pitch as that. Sounds like the 44 sample is a whole step lower than 48 sample. Definitely less subtle than what I’m experiencing.

In light of the above, it does seem as if Audacity resamples automatically when saving, if you’ve changed the rate in the drop down menu.

Is there anything else that could potentially alter the pitch of recordings after exporting?

Cheers

I use Audacity (on a Linux platform) to record music but (seemingly) randomly tracks are out of tune on playback. Weird thing is that I record one track. then I record another and find the 1st track to be detuned while the second is in tune… No changes made except for input volume changes. I use an Alesis usb in/out device. Session is at 44.1K so I dont know…
Audio in Linux has always been buggy, which often makes me revert back to Win which I dont like as an OS but much more reliable as a a/v editing platform…
I record an instrument or vocals to find it out of tune to another track also just recorded… Thats very frustrating…

What version of Linux and version number? Does this distro use pulseaudio?

What version of Audacity? All three numbers from Help > About Audacity. Did you install Audacity from the repository or compile it?

Is the Alesis both the output and input device in Device Toolbar? Model number of the Alesis? Have
you seen if there are Linux drivers for it, or does your distro say it needs none?

Are you really saying that the first track sounds in tune until you play it with the second track? Is the second track out of tune if you solo it?

Have you tried setting Audacity project rate to 48000 Hz? Can the Alesis be set to 48000 Hz?


Gale

One thing that jumps out to me is the down-grade from 24 bit to 16 bit. This is like doing a compression of an already compressed file. Each compression scheme sets limits on what can be captured and digitalized, when uncompressed, it cannot sound like the original as some content was dicarded during the original conversion and can not be replicated or replaced. Now you’re taking a 24 bit file and compressing it even more, down to 16 bits and more content gets discarded. Even equalization can’t make up for the content loss.

While it is true that converting from 24 bit to 16 bit may reduce the sound quality very very slightly, there is no way that such a conversion in itself could account for a change in pitch. At most it will add a tiny (virtually inaudible) amount of distortion or noise.

Have you checked the pitch before exporting?
Have you tried importing the exported file back into Audacity?
Is there a difference in length between the original audio project (before exporting) and the length of the file if you import it back into Audacity?

How are you playing the audio file when it sounds out of tune?