multiple wav files out of sync

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.
maurigug
Posts: 5
Joined: Fri May 30, 2008 6:42 am
Operating System: Please select

multiple wav files out of sync

Post by maurigug » Fri May 30, 2008 7:06 am

Hi.
I have made several multitrack recordings from an external Keyboard, to prepare a proper base for further choir recordings.
I record drums at first, then I add right hand, left hand, and then some more layers and sound.
The result is pretty good in Audacity, everything play in sync and If I mix everything down into one WAV file I get no problem.
But, when I export multiple wav files, to import them again into Audacity itself or SONAR or Powertracks for further editing and mixing, the imported battery track results out of sync at the beginning, playing almost a beat in advance, as if Audacity, exporting that track , had cut something in the silence before the first attack.
This happens only for the battery, other tracks result in sync, as I can see.
Does anybody know the reason for this behaviour and knows how to avoid it?
:o

jan.kolar
Posts: 273
Joined: Sat May 24, 2008 7:01 pm
Operating System: Please select

Re: multiple wav files out of sync

Post by jan.kolar » Fri May 30, 2008 10:51 am

If you save an Audacity project, and reopen it, it stil plays in sync, does it?

Did your track records start right from time zero?

If you plan to export Waws and reimport again (what is the purpose of this?), make sure you always press |<< (Jump to start) Button before the Record button.
Or write down precisse time your track starts (up to sample).

If your original project does not exist anymore, you Move tool (key F5) to sync the track.

maurigug
Posts: 5
Joined: Fri May 30, 2008 6:42 am
Operating System: Please select

Re: multiple wav files out of sync

Post by maurigug » Fri May 30, 2008 11:27 am

jan.kolar wrote:If you save an Audacity project, and reopen it, it stil plays in sync, does it?.
Yes it does
jan.kolar wrote:Did your track records start right from time zero?.
Yes it did
jan.kolar wrote:If you plan to export Waws and reimport again (what is the purpose of this?), make sure you always press |<< (Jump to start) Button before the Record button..
I always do that.
I have not the problem with the first track (drums in my recording )opposed to all the other ones, that are delayed of the same quantity.
If export the whole project into a WAV file, everything's ok and there's no delay compared to the original track in the project (reimported to check this also).

jan.kolar wrote:If your original project does not exist anymore, you Move tool (key F5) to sync the track.
My original (master) project is still there, I did not erase it. I need exporting multiple tracks and reimporting those in another program for further editing and better mixing.
I also reimported those tracks in another (blank) Audacity project, just to check if the problem keep coming out in Audacity even, and it does, so the problem does not stay in the other software. The WAV files were produced with a difference in sync.
It happens with all my (6) recordings.

jan.kolar
Posts: 273
Joined: Sat May 24, 2008 7:01 pm
Operating System: Please select

Re: multiple wav files out of sync

Post by jan.kolar » Fri May 30, 2008 3:42 pm

So I understand battery=drums=the single imported file.

I gues your latency settings (Let us denote it Lat) is "almost a beat". Thats good.

Since the playback is late relative to recording, Audacity moves the recorded track left in time.
You can see little arrows on recorded track that inform you about about some material before time zero.
You can see that by Ctrl-A, F6, drag right.

So indeed, your tracks start at different times. Correct?

{{
update:

maurigug, we had a longer discussion with Steve on the topis,
you might want to scroll down to see if there is one ore more *** BOOKMARK ***
marking outcomes of the discussion.
}}






What remains is to find an elegant way how to cope with that.

Is it possible to make Audacity do ExportMultiple (Export selection) to export only what is right from zero?
Can we make Audacity discard start of the recording?
Is there any easy way how to correct that by edding?

Hope someone other helps you, I can not.
Last edited by jan.kolar on Sat May 31, 2008 12:19 am, edited 1 time in total.

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

Re: multiple wav files out of sync

Post by steve » Fri May 30, 2008 4:51 pm

Screenshot.png
Screenshot.png (131.77 KiB) Viewed 3425 times
Track 1 is a stereo track - it starts at time=0 - no problem here.
Track 2 is a mono track and starts at approximately time = 0.5 seconds - PROBLEM !

At the bottom of the picture you can see what happens when we Export track 2 then import it. To Export track 2, I selected the track and from the "File menu" chose "Export Selection". Track 2 was exported correctly, BUT the free space at the beginning of the track is not exported. When we import it again (track name "2 Import") it is automatically lined up with time=0, and so it is in the wrong place.

Track 3 is the same as Track 2, EXCEPT that it starts at time = 0. (No Problem)
To create Track 3, I selected a copy of Track 2, and from the "Tracks menu" I clicked on "Mix and Render". This "filled in" the gap at the beginning (with silence), so that it now starts at time=0.

Exporting and importing Track 3 - No Problem :)

For any tracks that do not start at time = 0, you must individually "Mix and Render" those tracks before Exporting.
(Hope that makes sense).
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

jan.kolar
Posts: 273
Joined: Sat May 24, 2008 7:01 pm
Operating System: Please select

Re: multiple wav files out of sync

Post by jan.kolar » Fri May 30, 2008 6:04 pm

I wrote:
1. Is it possible to make Audacity do ExportMultiple (Export selection) to export only what is right from zero?
2. Can we make Audacity discard start of the recording?
3. Is there any easy way how to correct that by edding?

Steve, you are explaining how to do 3. for once, and that is indeed easy.
[And with some Shift-select tricks it can be done with sample precision.
(I hope Audacity does not make it one sample wrong because I would selecting outside of sound)]

However If it happens we record a next track, we have to do it all over again.
Moreover we cannot edit anything in negative time (why? is not it time, too?)
and when we moved it right, it is not as easy to move it back with sample precision
(OK. I have a trick: Lets have one track more with a bit of silence starting from original zero.)
Therefore it would nice to have positive answer for some of the questions.

2. can we make Audacity discard start of the recording? (The part that comes before the playback.)
4. What about "Edit > Discard all before zero time (for selected tracks)" ?


maurigug, how much is needed to make your work easy?

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

Re: multiple wav files out of sync

Post by steve » Fri May 30, 2008 8:09 pm

I'm having a bit of trouble understanding precisely what you mean, but I shall attempt to answer your questions.
All examples below are using Audacity 1.3.4.

"Export Selection" and "Export Multiple" are different.

"Export Multiple" enables you to split a recording at a number of places in time and produce a separate audio file for each part. This is typically used if you record an LP or a tape and you want each "song" top be a separate audio file.

There is a brief explanation of this here: http://audacityteam.org/help/faq?s=files&i=split
There is a more detailed explanation here: http://audacityteam.org/wiki/index.php? ... ate_tracks


"Export Selection" enables you to export the selected region of one or more tracks as one single audio file.

Examples of "Export Selection":

Example 1.
You have a project with 4 tracks and you want to export each track individually.
Example: track 1 becomes file-one.wav, track 2 becomes file-two.wav, track 3 -> file-three.wav, track 4 -> file-four.wav

To do this, select track 1, then choose "Export Selection" from the file menu. Follow the on-screen dialogue, select the file format, destination folder etc.

Repeat the procedure for each of the tracks.

Note: (and this is where the problems can occur)
"Export Selection" will only export audio that exists.

Audacity 1.3.x allows you to place audio clips anywhere on the time line, but "Export Selection" will not export empty space at the beginning or end of an audio clip.

"Silence" is counted as valid audio data, but an empty space is not.

Example 2.
Let us say that you have an audio clip that starts at time=5 seconds and ends at time=10 seconds.
You then try to select and export that track from time=0 to time=30 seconds.
This will not create 5 seconds of silence at the beginning of the exported audio, or 20 seconds of silence at the end because there is no audio data there to export.
The exported audio will only include the region from the start of the audio clip to the end of the clip. In other words, a 5 second clip.

There is one exception to this, and that is if you have two or more clips with gaps between them, and your selection includes two or more of these clips.

Example 3.
In the image below you can see an example.
Track 1 is our original track and I selected from time=1 second to time=3 seconds, then exported the selection.
Track 2 is the exported file after it has been imported back into Audacity.
Note that the gaps between clips has been replaced with silence and our exported audio file is 2.0 seconds long.
The gap between the end of the third audio clip (at about time=2.8 seconds) and the end of our selection (time=3.0 seconds) has also been replaced with silence. This is because Audacity is aware that there is still more audio on track 1 yet to come (the 4th and final clip on track 1).
Screenshot-1.png
Screenshot-1.png (11.31 KiB) Viewed 3397 times
Example 4.
If in Example 3 we want to be able to import the clips back into Audacity (or some other program), and want the clips to line up correctly in the time line, then clearly we need our selection to start at time=0
BUT we have a gap at the beginning of our track, and this gap will NOT be included in out exported audio.

The solution to this is to turn our track (render) into a continuous audio track that starts at time=0.

To do this, we select the track, then from the "Tracks" menu click on "Mix and Render".
The result is as in this image:
Screenshot-2.png
Screenshot-2.png (8.08 KiB) Viewed 3397 times
If we compare this to the previous image we can see that the gaps have been "filled in" with silence, so now we can export this track, and it will start at time=0

Tips:
The following "hot keys" can make the above process quicker - particularly useful if you have lots of tracks:
[Enter] = select/deselect current track
[Home] = move to start
[End] = move to end
[Shift]+[Home] = select from cursor position to the start
[Shift]+[End] = select from cursor position to the end
Down cursor = next track down
Up cursor = next track up
[Alt]+T then M = Mix and render (selected tracks)
[Alt]+F then R = Export selection

Putting these together -
Up/Down cursor keys to the track that we want to export, then
[Enter] - (select track)
[Home]
[Shift]+[End] - (selected track is now highlighted)
[Alt]+T then M - (track is now rendered)
[Alt]+F then R - (Export selected)

Regarding Exporting audio that is before time=0
Using the normal "Export" command from the file menu will Export a mix of all tracks, starting at time=0 to the end.
Using "Export Selection" can export audio that exists before time=0 provided that it is selected.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

jan.kolar
Posts: 273
Joined: Sat May 24, 2008 7:01 pm
Operating System: Please select

Re: multiple wav files out of sync

Post by jan.kolar » Fri May 30, 2008 11:55 pm

Steve, do not give so detailed explanation when talking to me, unless others take benefit from it.
Treat me much like programmer than user.

Two ideas of your post are useless in our situation - we have problem with what is before zero, and we want it to be NOT-exported. I wrote more, but I got logged out and the text disappeard (BB offered original quote without my edditing :-( ).

One idea solves it. I will reput it in a way that I think is suitable for maurigug in the next post.

jan.kolar
Posts: 273
Joined: Sat May 24, 2008 7:01 pm
Operating System: Please select

Re: multiple wav files out of sync

Post by jan.kolar » Sat May 31, 2008 12:11 am

*** BOOKMARK ***

maurigug,
Far above I explain that I think you have the problem with sync after export because your tracks do not start at the
same time. They start at time zero and diferent times before zero. This is somehow connected to timings of playback and recording and cannot be avoided.

Now this is a solution, which I digged from Steve's post (Thank you, Steve):

For each track do the following:
Select the track (only one), then from the "Tracks" menu click on "Mix and Render".
Normally this serves different purpose, but for us it makes the track start exactly at 0 by discarding what is before 0, (and eventually adding silence if there is a gap after 0).

If you do this for all tracks, little arrows should disappear and your problem as well.







The following "keyshortcuts" can make the above process quicker - particularly useful if you have lots of tracks:

Ctrl-Shift-A = deselect all (dont know if aviable prior 1.3.5)
Up/Down cursor keys = moving to the track that we want to export
[Enter] = select/deselect current track
[Alt]+T then M = Mix and render (selected tracks)

maurigug
Posts: 5
Joined: Fri May 30, 2008 6:42 am
Operating System: Please select

Re: multiple wav files out of sync

Post by maurigug » Sun Jun 01, 2008 9:11 am

thanks a lot.
Meanwhile, I had reached the same explanation for wht's happening to me, and you have confirmed my thoughts.
Your is a very good idea, mix and render applied to every single track should solve my problem, and I'll try.
Another idea (from myself) is:
My tracks come form sinle recordings to get a multitrack one.
The latency device in Audacity draws all tracks subsequent to the first one a cetain amount of time back, and I understood the meaning of the small white arrows pointing that.
SO, my idea is:
before recording drums (my first insrumental track) I have to record a first, empty, ghost track, just for a few seconds, then I will have to record the drum one.
This one will be treated as all the other tracks, and I should have no problems exporting multiple tracks .
Of couse, I won't reimport the First track, containing nothing.
Now I have two methods.
One to use already done recordings (your method) and one to avoid the problem in future. :lol:

Thanks a lot
Maurizio

Locked