Export Selection produces tracks out of sync./ wrong length

This section is now closed.
Forum rules
Audacity 1.3.x is now obsolete. Please use the current Audacity 2.1.x version.

The final version of Audacity for Windows 98/ME is the legacy 2.0.0 version.
steve
Site Admin
Posts: 81627
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Export Selection produces tracks out of sync./ wrong len

Post by steve » Wed Nov 26, 2008 12:14 am

eeeehaw wrote:The Red Book CD format spec calls for some quiet lead-in time (1-2 seconds typically) for the first track only
That pause is usually* applied by the CD writing software when you have selected to create an audio CD. You do not have to add this silence manually, and Audacity does not do this. All of your Exported tracks can start immediately, but when written to an audio CD, there will be a short pause (typically 2 seconds) added by the CD burning software.

* Every CD writing program that supports authoring audio CD's that I have ever heard of does this.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

TSMusic
Posts: 48
Joined: Sun Nov 02, 2008 12:40 am
Operating System: Please select

Re: Export Selection produces tracks out of sync./ wrong len

Post by TSMusic » Fri Dec 26, 2008 11:10 pm

I finally got some time to work on a new project yesterday and kept track of what was going on with the export. The song consisted of a recorded guitar track, then split into 2 mono tracks, a mono bass track, and a bodhran track that was recorded in stereo and also split into 2 mono tracks.

I got everything lined up perfectly in Audacity. Exported them as 24 bit WAV files. The guitar tracks came out fine, the pair matched up perfectly. The bass track, it added .1025 seconds to the beginning of the file. The bodhran tracks, it added 1.5 seconds to the beginning of the files (and to both of them even though they were exported separately). I had to import the WAV files back into Audacity, get everything lined up again and them exported them again and they were fine. (And I just exported the bass track again from Audacity to compare with the cleaned up track and it did it again).

I'm starting to think that the problem is where Audacity is putting the beginning of the track markers with each newly recorded track. I hit <HOME> to make sure I'm starting all the way over at the beginning. Somehow they are going into that nebulous -0.000 track position even though it shouldn't be, not hitting <HOME>, that should go back to 0.00 which it looks like it is doing but somehow it ain't.

For what it's worth

Tony
Art & Lutherie Cedar Folk CW 6 String Acoustic
Pre-Martin Goya 12 String
Vestor Bass
And a bunch of other ends and odds!
http://www.tonyseomusic.com/
http://www.myspace.com/tonyseomusic
http://www.soundclick.com/tonyseo

steve
Site Admin
Posts: 81627
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Export Selection produces tracks out of sync./ wrong len

Post by steve » Sat Dec 27, 2008 2:39 pm

to ensure that tracks start at time = 0.000 seconds, select the track and render it using "Mix and Render". Repeat this for each track. This will solve all of the problems regarding incorrect starting positions.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

TSMusic
Posts: 48
Joined: Sun Nov 02, 2008 12:40 am
Operating System: Please select

Re: Export Selection produces tracks out of sync./ wrong len

Post by TSMusic » Sat Dec 27, 2008 2:54 pm

stevethefiddle wrote:to ensure that tracks start at time = 0.000 seconds, select the track and render it using "Mix and Render". Repeat this for each track. This will solve all of the problems regarding incorrect starting positions.
Nope. I just tried that. It worked for the bass track, but the drum tracks were still off after mixing and rendering by .14 seconds.

I really hope the core problem get's fixed.

Tony
Art & Lutherie Cedar Folk CW 6 String Acoustic
Pre-Martin Goya 12 String
Vestor Bass
And a bunch of other ends and odds!
http://www.tonyseomusic.com/
http://www.myspace.com/tonyseomusic
http://www.soundclick.com/tonyseo

steve
Site Admin
Posts: 81627
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Export Selection produces tracks out of sync./ wrong len

Post by steve » Sat Dec 27, 2008 3:42 pm

I've no idea how you are getting this to occur - if I mix and render each track, the synchronisation is bang on, always.
Could you give a step-by step method so that I can reproduce the problem.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

TSMusic
Posts: 48
Joined: Sun Nov 02, 2008 12:40 am
Operating System: Please select

Re: Export Selection produces tracks out of sync./ wrong len

Post by TSMusic » Sat Dec 27, 2008 4:27 pm

stevethefiddle wrote:I've no idea how you are getting this to occur - if I mix and render each track, the synchronisation is bang on, always.
Could you give a step-by step method so that I can reproduce the problem.
Very simply. I record the tracks. On the original recording, there was the lead guitar part, a rhythm guitar track (discarded before I did the export), 2 takes of the drum track which I discarded the first one one on, and the bass.

There was about 11 1/2 seconds of dead air (recorded silence at the beginning of each track) that was trimmed down to 2 1/2 seconds. I had to make a few minor deletes in the dead air to line everything up because of some latency (like .2 seconds or in that vicinity).

The guitar came in as a stereo track. That was split and each track made mono (instead of left and right). I select the track by clicking on the track control box (which I have always done with all previous versions), hit Export Selection, Other Compressed Files, with the options being set to 24 bit WAV. Do that for the other guitar track. The drum track was a stereo track (2 mics one drum), that also was split and each track made mono. Exported those. The bass was recorded as a stereo track, just cause that is my default but it only records to one channel. That was split, the quiet track deleted, and that was exported as well.

Then this AM, I did like you said with the mix and render on the individual tracks and got the results I mentioned. I just tried it again, this time on the drum track, I hit mix & render twice on the same track and this time it shortened the track by .024 seconds. (Which if you ask me is kinda weird behaviour on the part of the mix and render).

Tony
Art & Lutherie Cedar Folk CW 6 String Acoustic
Pre-Martin Goya 12 String
Vestor Bass
And a bunch of other ends and odds!
http://www.tonyseomusic.com/
http://www.myspace.com/tonyseomusic
http://www.soundclick.com/tonyseo

steve
Site Admin
Posts: 81627
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Export Selection produces tracks out of sync./ wrong len

Post by steve » Sun Dec 28, 2008 2:37 am

I appreciate you taking the time to type all of that up TSMusic, but it does not help me to reproduce the problem.
By the way, which version of Audacity are you using?

To fault find this problem I need you to give me an precise example of how to produce the problem.
For example;
1) Create mono tracks 16 bit 44100Hz, 3 mins 14 seconds, starting at 4.620 seconds.
2) Create stereo track .......
3) Switch "snap" off and "link" switched off.
4) Select track 2 by clicking below the track name
5) ....
....


I can't really help unless I can reproduce the problem, which at the moment I can't. The only thing that I can suggest is that you look in the selection toolbar at the start/end times (set to h:m:s:samples) each time you select some audio to ensure that you are selecting what you think you are selecting.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

TSMusic
Posts: 48
Joined: Sun Nov 02, 2008 12:40 am
Operating System: Please select

Re: Export Selection produces tracks out of sync./ wrong len

Post by TSMusic » Sun Dec 28, 2008 7:05 pm

I am using 1.3.6 although the problem was also in 1.3.5.

I'm now sure the BUG is in the recording section. That hitting record, isn't starting at 0:00:00 even though that is what is showing on screen.

I recorded 3 tracks of about 6 seconds of silence coming in. I just hit the record and then stop for each track. I trimmed them off on the right side so they were all showing to be equal in length (by selecting across all 3 tracks at the same time with the mouse). When I hit the snap and select on the first track this is what I get. (Note: The forum software seems to be trimming off the right side of the pictures so you will have to take my word that the tracks are all the same length)

Length is M06.003S

Image

Second track. The length is M06.120S

Image

Third track. The length is M06.120S

Image

I hit the mix and render on the third track. The length is NOW M06.004

Image

I hit the mix and render on the 2nd track (which moved it to the bottom of the screen. The length is now M06.003S

Image

The problem isn't with the WAV export per se. The problem is, the first track starts recording exactly at 0:00, each subsequent track is recording someplace off to the side. I just did the same recording test on this PC which I do my mixing on, and the track lengths are showing (without mixing and rendering), 6:00:00, 6:116, 6:116 and the start position for the 2nd and third tracks are showing as M00.-.100s. This time Mix and render corrected both tracks to the proper length.

Tony
Art & Lutherie Cedar Folk CW 6 String Acoustic
Pre-Martin Goya 12 String
Vestor Bass
And a bunch of other ends and odds!
http://www.tonyseomusic.com/
http://www.myspace.com/tonyseomusic
http://www.soundclick.com/tonyseo

steve
Site Admin
Posts: 81627
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Export Selection produces tracks out of sync./ wrong len

Post by steve » Sun Dec 28, 2008 8:41 pm

Excellent - that explains it nicely.

There are two things going on that are causing this issue. "Latency correction", and "snapping".

Latency correction
You see at the beginning of tracks 2 and 3 that there are little arrows pointing to the left (toward the "1.0" and "-1.0" on the vertical scale). These arrows indicate that the audio continues to the left of (before) time = 0.000
The reason that this happens is because of "latency correction".

When you record on a computer, there is always a short delay between the sound going into the microphone, and ending up as digital data on your hard drive. When you record just one single track, that delay does not matter, but if you are multi-tracking it becomes very important.

If you have a rhythm track (or a click track) recorded on track 1 and you are trying to play in time with it, you will play in time with what you hear, but because of the recording delay (latency), the recording on track 2 will be out of sync with track one - it will be a little bit late. Audacity (and all other multi-track recorders) has a mechanism to automatically correct this (latency correction). It makes the correction by shifting the recording a little to the left as soon as the recording stops, thus bringing track 2 into sync with track 1.

Different computers will have different amounts of latency, so Audacity has to try and "guess" how much correction to apply. Audacity will usually guess pretty accurately, but there is manual adjustment available (in Audacity 1.3.x) to allow he user to set it up exactly. The adjustment is in Preferences in the "Audio I/O" tab.

In the case that you have illustrated, you say that all tracks have been trimmed to exactly the same length. This is the length of track 1 which is 6.003 seconds.
Now tracks 2 and 3 are indicating that they are 6.120 seconds duration - 117 milliseconds longer than track 1. But where is that extra 117 milliseconds? That is what the little arrows indicate - the 117 milliseconds is hidden behind the start of the time line.

The automatic latency correction has shifted tracks 2 and 3 by 117 milliseconds to the left so as to bring the recordings on each track in sync.

Snapping
As discussed previously in this thread, the behaviour of snapping when it applies to audio that is before the start of the time line is somewhat erratic.

Solution
If you switch snapping off, and select track 2 (click just below the track name, just above the "solo" and "mute" buttons) and then apply "mix and render" (track menu), any audio before time = 0.000 is not rendered - in effect it is neatly trimmed off.
Repeat for track 3.

Extra note
The useful thing about using the "Mix and Render" trick, is that it works wherever your audio clips are placed on the time line. If you have another track with several clips spaced along the time line with gaps between the audio clips, then when you render he track, the spaces are rendered as silence (horizontal blue line), thus the spacing between the clips is maintained when you export the track.

Extra note about latency correction
If you want to check that the latency correction is set up correctly, create a click track on track 1, then record it (with a microphone is fine) onto track 2. The clicks on track 1 and track 2 should exactly line up.

If the clicks on track 2 are too far to the right, increase the latency correction in Audacity Preferences so that the correction will drag new tracks a little further to the left

If the clicks in track 2 are too far to the left (before the clicks in track 1) then reduce the latency correction.

Most domestic sound cards will drift slightly, but you should be able to get the tracks to line up within a couple of milliseconds.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

TSMusic
Posts: 48
Joined: Sun Nov 02, 2008 12:40 am
Operating System: Please select

Re: Export Selection produces tracks out of sync./ wrong len

Post by TSMusic » Sun Dec 28, 2008 8:57 pm

I appreciate that and understand well about latency. My Presonus Inspire 1384 has a setting on it for latency which I have set to the lowest (1.5) setting. That's all well and good.

BUT, the software should not be shifting the recorded track past the 0.00 mark to the negative side of things. (Why there is a negative side of things I do not understand). On the earlier beta's (1.3.4 and previous), everything started at 0:00, if it was off a little, no big deal to delete a little dead air to line things back up, I'm REAL good at that.

I can deal with these issues now. But what about the tens of thousands of folks that don't have the technical proficiency or the patience to figure all this out.

My contention is, that the software should start recording at 0:00 and any latency correction should not appear before the start of the track OR there should be some way of navigating over there to get to it.

If I record with Cubase, it starts recording where every I have the cursor line positioned. I can use Cubase (I have LE on the recording PC that came with the Inspire) but Audacity is a whole lot simpler to record with. Especially when I'm having one of those, Hit the Red Button, start playing, cuss, hit Stop, delete the track and hit the Red Button and start all over kinda days, and rarely does that happen one time!

Thanks for the help.

Tony
Art & Lutherie Cedar Folk CW 6 String Acoustic
Pre-Martin Goya 12 String
Vestor Bass
And a bunch of other ends and odds!
http://www.tonyseomusic.com/
http://www.myspace.com/tonyseomusic
http://www.soundclick.com/tonyseo

Locked