I know that virtualdub records this somewhere in the avi stream. And when you open inside vdub, and you scan (manually) through the timeline, you can find them by looking at the the status line, for the [D] code. Unforunately, to my knowledge, none of the vdubs has such a short-cut feature (ie, Ctrl+D for instance) to locate and stop at it, like you can for [K] frames, etc.
I am guessing that vdub places the [D] only during manual scanning using the cursor left and right keys, would seem to explane lack of search feature.
So, I decided to search around for any clues how to detect frame drops in avi's, either by source signiture (if one actaully exist) or through alternate means, by frame comparison for dups through avisynth scripts.
(While I was at it, I decided to try some delphi coding, but the problem is, there doesn't seem to be any faster way of finding these dups in an instant other than going through the avi stream manually, frame by frame. Even using the scanline property is still too slow when you have 30k plus or more frames to scan through. But finding where the virtualdub places the framedrop signiture would more than likely be instant because i could write a routine to read the file raw)
Then, I remember seeing a discussion on finding duplicate frames (or, frame drops) through avisynth scripts. In fact, I recall seeing a dicussion not too long ago, I think. And it had a few script snipplets, by Gavino, if I call.
So I tried searching for anything related to that disucssion, (via google) on this board, but I can't seem to find it now, through keywords like duplicate and frame drops, unless my eyes are just heavy now after countless searches everything looks the same.
Does anybody have any good clues how to detect dropped frames, fastest possible, either through avisynth scripts or external utility via programming code.
Thank you,
-vhelp 5397
+ Reply to Thread
Results 1 to 5 of 5
-
-
Perhaps you're thinking of this post.
But that was for a different job, compare two clips and find the frames present in one but not in the other.
Duplicate frames in a single clip can be detected fairly easily in Avisynth using YDifferenceFromPrevious() and ScriptClip(). The details of the code depend on what you want to do once you've detected a dup. -
Thanks gavino. I was actually debuggin YdifferenceFromPrevious() from these resources at this link and also this link but couldn't get it work the way I thought it was suppose to work, and after a couple of hours of no success i lost interest and took a tv break. Anyway.
I was using a simplified test clip of 30 frames with 2 purposely made dup frames, and param setup writefileif("g:\dups.txt", "YdifferenceFromPrevious < 0.001", "current_frame") the .txt file would display the same results no matter what parameter I'd feed it, 0.001, 1.0, 25, 50, 75, 100, etc..
Reported txt file Results:
0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19, 20,21,22,23,24,25,26,27,28,29
but, where the dups to be reported should have been:
-,-,-,-,D,D,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,-,D,D,-,-,-,-,-,-,-
Not sure what I did wrong but frame 4 and 24 were dups of next frame. At least this is how vdub deals with drops, it copies the prev frame, I just simulated the same effect though manually for this test clip. I've never seen what an actual output looks like when conditions are met, so i'm not sure what I should be seeing though i'm gussing the above.
I'll try again laer, or tomorrow, thank you again.
-vhelp 5398 -
Maybe I don't know what I am talking about, but...
how about looking at the source-code of cfr2tc.exe and tc2cfr.exe (by tritical) ???Last edited by El Heggunte; 13th Jun 2010 at 23:01.
-
Yes, the thread you reference deals with exactly the problem you are interested in.
My memory is failing - I completely forgot I'd written that stuff, and it was only two months ago.
I was using a simplified test clip of 30 frames with 2 purposely made dup frames, and param setup writefileif("g:\dups.txt", "YdifferenceFromPrevious < 0.001", "current_frame") the .txt file would display the same results no matter what parameter I'd feed it, 0.001, 1.0, 25, 50, 75, 100, etc..
Reported txt file Results:
0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19, 20,21,22,23,24,25,26,27,28,29
Note that WriteFile by default appends to the file, so perhaps your file starts with data from a previous run.
Similar Threads
-
Virtualdub VCR capture no dropped frames but 5400 inserted frames in 1 hour
By suloku in forum Capturing and VCRReplies: 12Last Post: 17th Aug 2011, 22:33 -
Dropped Frames
By SudsMalone in forum Capturing and VCRReplies: 4Last Post: 21st Feb 2011, 05:31 -
Captured AVI frames broken/split/badly aligned
By cyclometric in forum Video ConversionReplies: 3Last Post: 25th Sep 2008, 07:50 -
Dropped Frames
By dano404 in forum Camcorders (DV/HDV/AVCHD/HD)Replies: 2Last Post: 8th Mar 2008, 13:57 -
inserted frames without dropped frames in VirtualDub capturing VHS
By whschlebaum in forum Capturing and VCRReplies: 0Last Post: 23rd Aug 2007, 20:59