Click to See Complete Forum and Search --> : Video Frame/Audio Sample Conversion


bytz
September 15th, 2006, 02:00 PM
I'm having problems mapping NTSC frames to a time/drawing location. Currently the sofware is using the integer approximation 30000/1001 in it's calculations, this however will often cause the rendered time of the video clip to be 1 frame off from the audio rendering i.e. as in a timeline using rectangle to show when and how long the clips are.

I tried converting the integer math to floating point and then used a ceiling funtion to convert the factional frame to a frame, which works ok for most situations except at some point the the approximation produces an extra frame.

I'd think that this is a fairly well documented occurance but I haven't found anything that would help.

kumaresh_ana
September 16th, 2006, 09:10 AM
You can insert the same video frame twice in places where the video lags audio. For every 299 frames you render insert a frame (299th frame twice) and make it 300.

bytz
September 16th, 2006, 09:51 AM
Thanks for the suggestion, but the problem is not the play back, but in the representation of the relative start and duration times on a time line.

kumaresh_ana
September 16th, 2006, 09:54 AM
What makes rendering differ from representing it by a timeline? You can insert an extra while displaying it in the timeline.