PDA

View Full Version : Help: change audio frame rate from 25 fps to 23,97


Calabuig
2nd June 2002, 12:01
Sorry!
I know it's (maybe) been discussed many times, but I can't find any specified answers to my question.
I would like to add an audio track from a PAL source (25 fps) to my NTSC avi (23,97 fps).
Is there any way to do that?
Is there any guide?
Thanks in advance!!!

PeterTheMaster
2nd June 2002, 16:07
is changing the length of an audio file what you are looking for? this has been answered a lot of times, but since i never did it myself i dont remember the answer.

diji1
2nd June 2002, 17:16
Hello, if ur encoding your sound in ogg format ( ... and if you aren't maybe it's time to jump on the proverbial bandwagon :) ) there is an option to change audio framerate from 25000 to 23976 in ogg-machine. i haven't tried what ur doing but i'm certain there's other ways of achieving the same thing with other formats and programs.

Tri
2nd June 2002, 18:14
I always do it that way:

I open the original video in VirtualDub, adjust the new framerate, start a frame server and open the served video again in a new Virtualdub. Then I check the new length of the video.
Next I open the Soundtrack in CoolEdit and apply the new length there (Transform -> Time/Pitch -> Constant Stretch; High Precision; Time Stretch).

I found this the best method. BeSweet seems to upper the pitch and SoundForge doesn't reach the final length as exactly as CoolEdit.

tenebrenz
3rd June 2002, 02:23
My method

1) Open the audio in Cool edit (or another program)

2) Work out the change in samplerate with this calculation:

Input Samplerate x Output Framerate / Input Framerate = Output Samplerate

48,000 x 23.976 / 25 = 46,034 in your case (PAL to NTSC)
48,000 x 25 / 23.976 = 50,050 for a NTSC to PAL conversion

3) Change the samplerate (not resample) in Cool edit to the figure you just calculated

4) Finally, resample the audio to your desired rate

Btw people that mention time-stretching audio make me want to scream, it is just about the worst thing you can do imho. I have one DVD where one of the languages has been timestretched from NTSC to PAL and if I meet the guy who did it...

PeterTheMaster
3rd June 2002, 07:40
maybe people dont know that any samplerate can be chosen. i always thought that only 44100 an 48000 are valid values.

i am just thinking: shouldnt we change the framerate of all pal movies to 24 and the samplerate to 46080?
because i read somewhere that the original film is recorded at this framerate, so shouldnt the voices of the actors sound faster in a pal version?

tenebrenz
3rd June 2002, 11:52
i am just thinking: shouldnt we change the framerate of all pal movies to 24 and the samplerate to 46080?
Do you mean leave the sample rate at 46080, i.e. not resample afterward? I never thought of this but wouldn't windows/your soundcard/drivers resample it on the fly to another rate anyway, this could cause synch or quality problems.
Shouldnt the voices of the actors sound faster in a pal version?
Yes they should sound faster and higher pitch, approx 1 semi-tone. But the good thing is that this process is reversible.

PeterTheMaster
3rd June 2002, 17:27
wait wait wait some misunderstandings seem to go on here.

i understood your previous post that you wanted to change the sample rate and then leave it that way. if not: what is the difference between your method and stretching?

"the good thing is this process is reversible" does this mean you always do it? i never did it in the dvds i converted so far.
i dont know if its worth the potential loss of quality.

tenebrenz
3rd June 2002, 21:39
To ease the confusion (hopefully)

When changing framrate you change the length of the video, you must therefore also change the length of the audio to match. There are 2 ways to change the length of the audio:
1) Speeding it up, like you would a record, here the pitch will change accordingly. You can do the same thing digitally by resampling.
2) Time-stretching, this will allow you to change the length of an audio file without changing the pitch. This works by chopping up the audio into small segments and overlapping them, as you can imagine this causes noticeable artifacts though it can be very useful in music production.

As you know all PAL video is made by speeding up 24fps up to 25fps and the audio is speeded up with the pitch increase. This is reversible because you can slow the whole thing down again and the pitch will go back to normal, there should be no noticeable artifacts if done correctly.
If time-stretching was used to change the length of the audio in the PAL speed-up, you get artifacts, if you then wanted to convert this PAL back to film you would have to use time-stretching again which would leave even more artifacts and would be very noticeable to anyone.

A test would be to take your favourite piece of music and use both methods to convert it from film speed to pal and back again.

PeterTheMaster
3rd June 2002, 22:42
so would you recommend to change the framerate of my pal movies to 24fps and resample the audio accordingly? should this become one step in my standard procedure?
the encoded files should have the exact same size so it would only be to get the voices correct, right?

and if an english movie has a german audio track, do they record the german audio for the 24fps movie and resample it or do they record it for the 25fps (pal) movie, so resampling would make the voices to slow?

tenebrenz
4th June 2002, 13:33
so would you recommend to change the framerate of my pal movies to 24fps and resample the audio accordingly?
It depends, if you are going to play it later with TV out it is best to leave it as PAL. If you are only going to play it on your PC, why not watch it at the proper speed?
the encoded files should have the exact same size so it would only be to get the voices correct, right?
As the audio will become longer the encoded file will be bigger, not sure what the difference would be with something like vorbis (musn't say ogg). This means you have a little less bitrate for the video.
and if an english movie has a german audio track, do they record the german audio for the 24fps movie and resample it or do they record it for the 25fps (pal) movie, so resampling would make the voices to slow?
There I have no idea. Are movies shown dubbed in the cinema, if yes then I expect it is done at film framerate, if dubbed for DVD / Video release it could be either method and probbably is. Here you could have the case where as PAL the voices are correct but the music is subject to the speed up. To be honest, it doesn't matter all that much, if you are happy with everything as PAL then leave it alone. The point of my post was if you are going to convert - do it properly!

PeterTheMaster
5th June 2002, 11:25
thanks tenebrenz.

PeterTheMaster
5th June 2002, 18:37
does anyone know if the built in framerate conversion of besweet does that evil audio stretching or does it resample the good way tenebrenz described?

PeterTheMaster
7th June 2002, 07:34
i have: the vobs of pal movie, the german ac3 for it and downloaded the english mp3 for ntsc.
now i want to make a 2 language movie. i made 2 language movies before, so this is not my problem, my question is:
what would quality-wise be the best way to do it.

i want both soundtracks to be ogg. this would almost half the size of the mp3 and since i (always) go for one cd its worth it.

so i could: decode the mp3 to wav, resample, encode to ogg.
or can this be done without an intermediate wav?

or:
resample and encode to ogg the ac3 with oggmachine, and also change the framerate of the movie.

PeterTheMaster
9th June 2002, 21:08
hmm, seems like noone is reading this any more but nevertheless:

i think instead of setting the sample rate to 46034 which is rounded up by 0.08 it is better to set the sample rate to 1150848, then resample to 1200000 and then set the samplerate back to 48000. takes about 2.5 hours in cool edit and is very unprecise!
the 1150848 gets increasingly unsync compared to the 1200000 one!

the better way in cool edit is effects/time/stretch/resample to % 104.27093760427093760427093760427

i dont know how much of this number it parsed but it works fast (17 min) and precise (2/48000s off after 2h)!

i hope this helps anybody it took me 4 days to figure this out.

prattboy
10th July 2002, 23:10
So, I'm sorry, I didn't really catch that last part. Are you saying the best way is to do set the sample rate to 46034 or 1150848, or to drop the sample rate setting completely and jumping to the resample at 104.27%? (sorry for not following well, I'm pretty new at this stuff).

Thanks,
prattboy

PS I appreciate the effort, at least!