Log in

View Full Version : Using MotionPerfect for hybrid footage


Zarxrax
10th February 2005, 21:50
I am using the method of converting hybrid source to 23.976fps as described by neuron2 back in this thread: http://forum.doom9.org/showthread.php?s=&threadid=43362&highlight=star+trek+hybrid

Motionperfect is doing a great job converting the 30fps scenes to 24fps, but as it says in that thread, its a LOT of work. In a 30 minute episode of something I'm working on now, I have processed 19 clips like this, and thats not even all of them. I have been working on an avisynth function to help me splice the processed clips back into the decimated video stream relatively easy, but the most time-consuming part for me remains getting the frame numbers for the scenes that I need to process.

I'm sure there must be some sort of automated way that I can tell which scenes are 30fps? Just reading the frame numbers out of a file would be a heck of a lot easier than watching through every episode looking for choppy parts, then loading up virtualdub and figuring out what frames that scene begins and ends on. I've tried looking into some of the various VFR programs out there hoping something could put out a list of the frames for me, but I've not had any luck so far.

tritical
11th February 2005, 19:37
One semi-automatic option would be to use:

tfm()
tdecimate()

with tdecimate in vfr mode with v1 timecodes output and use that timecodes file to get the info you need. See the readme for setting up tfm/tdecimate in vfr mode... it can do vfr detection based off frame matches from tfm, metrics calculated by tdecimate, both, or either and can require a minimum number of consecutive cycles (all of that is user configurable). The reason I say this is semi-automatic is the ranges in the timecode output file will not be the frame ranges for 30fps video in the original, but that info can easily be obtained from the timecodes file by doing a few quick calculations. If the ep has many ranges making a small command line program to extract the original ranges may be useful.

Zarxrax
12th February 2005, 01:29
That helps well enough, thanks :)

tritical
13th February 2005, 00:53
Apparently I had a major memory lapse, cause I had made a small commandline program a while back that took a mkv v1 timecode file as input and output the ranges in the original video stream that matched each fps in the final stream. I dug it out and stuck a few comments at the top of the source code file as to how to use it. Get it here: retrieveranges.zip (http://bengal.missouri.edu/~kes25c/retrieveranges.zip). Use it like this: retrieveranges timecodefile.txt orig_fps end_frame [out_fps] >outfile.txt

orig_fps = fps of original video (29.970 in this case)
end_frame = just set this equal to the # of frames in the original undecimated stream
out_fps = optional, if set it will only output ranges that match this fps
>outfile.txt = dumps the output into outfile.txt

So for what you want you could use:

retrieveranges timecodefile.txt 29.970 end_frame 29.970 >vidRanges.txt

Guest
13th February 2005, 05:56
If it's a VOB using pulldown flags, just use DGParse to locate the film sections.