Replacing a Single frame with adjacent frame. . .

WayneM wrote on 1/8/2015, 7:01 PM
. . . in other words Duplicating a single frame.

I have an HD transfer of a 16mm silent film I cut together around 1972. The transfer and the Project template are HD 1080-24p (1920x1080, 23.976 fps). Right now this main video track is a single 15 minute clip.

There is a music only (loose sync only) sound track that was on 16mm mag film, but that's not a problem. Yup, this was cut on a Movieola.

In a couple places in the transfer one or two frames shift up or down out of register. (Sprocket issues from a film shown a number of times.) It is quite noticeable and I'd like to minimize it. And it is frames where there is little movement.

So when I was working on this two years ago in Vegas Pro 10 I came up with a workflow where I could zoom in and select a single frame. It would be the last fully registered frame before the jump. Then I would select the bad frame and do a paste. Back then it worked fine and a single duped frame was virtually invisible and the distraction was gone.

So I was just trying this the past couple days in final work on the project and I'll be darned if I can get it to work. When I do the paste I seem to end up with two copies of the bad frame. I'm doing all this directly on the timeline.

I've used Vegas since the Vegas Video 1.0 days, but may have gotten along without using some of the newer features.

First, does what I want to do make sense?

Might this be something where I should be leveraging the "Trimmer Window"? I don't think I have ever used that and came across the term while reading in the manual about using the current stabilization plug-in. Again this is a single video clip right now. When I opened it up in the Trimmer window I wasn't able to zoom in to the level where I was looking at single frames. Is this something where I might use a subclip? I have no experience with those either.

I even used to have a script to help me automate this fix so I'm sure it is possible at least in VP 10.

Any help greatly appreciated.

Wayne

PS. Is there a way to change forum settings so I get an email notification when there is Forum activity?

Comments

john_dennis wrote on 1/8/2015, 7:37 PM
Find and place the cursor on the good frame.
Set the preview properties to Best/Full.
Press the little diskette icon in the Preview panel.
An image file will appear in the Media Pool.
Drag the image from the Media Pool to the time line over the defective frame.

"Is there a way to change forum settings so I get an email notification when there is Forum activity?"

No
rs170a wrote on 1/8/2015, 8:06 PM
Here's a script written by John Meyer that does exactly what you want.

*Fix a bad video frame by deleting bad frame and replacing with previous frame.
SingleFrameFix

Mike
johnmeyer wrote on 1/8/2015, 8:56 PM
My old script will do what you want, in one push of a button.

If you really want to get into it, and you understand AVISynth, you can synthesize an almost perfect replacement for the bad frame. Here's an example of film that had bad sprockets in the camera so there was no way to fix it during the transfer (i.e., it was aligned correctly during the transfer). I manually duplicated each jump frame, and then built a script that detects perfect duplicates and replaces the second one with a synthesized frame by using motion estimation from the two good adjacent frames.





WayneM wrote on 1/8/2015, 10:50 PM
Thanks much for sharing this. My needs are simple in this case so it should be perfect. I also saw John's note about AVISynth and the sample. It brings to mind another bit of problem film that I mention in a reply to him.

Again, thanks to both of you!

Wayne
WayneM wrote on 1/8/2015, 10:53 PM
Thanks much John. I'll have to check that out!

Is the cursor placed on the good frame before or after the bad one?

Wayne
john_dennis wrote on 1/8/2015, 11:04 PM

"... before or after the bad one?"

Yes, or you could try johnmeyer's method and create a new frame from the one before and after.

WayneM wrote on 1/8/2015, 11:08 PM
Wow, that's downright amazing. Thanks for bringing it up, although I don't know if I'd even have the ability to get up to speed with AVISynth. I looked at an earlier release and even then it had some amazing core capabilities.

This would likely be helpful with some scenes I shot on 16mm in the early 1970s. I had a Pathe 16mm and with some emulsions it would go on jags where registration would jitter up and down. Truly annoying.

So if I understand what you were doing you did one pass to overwrite the bad frame with a duplicate then in the second pass your script would detect the duplicates and perform the motion estimation magic and replacement. Right?

That's amazing!

I was looking at the Wiki (http://avisynth.nl/index.php/Main_Page) and wondered if that is the best place to look thru the documentation or if there is a better place to start.

Thanks much!

Wayne
WayneM wrote on 1/9/2015, 11:54 AM
I'd love to do that, but I think it is out of my league at this time :-(

I looked at the AVISynth wiki and it seems very intriguing. I never knew about frameserver technology. Very cool.

I found at least one place where there were two bad frames in a row. So, I am going to attempt to make another one based on John's script so it will replace a bad frame with the FOLLOWING frame. (That would mean executing both scripts.)

Or if I find time maybe see if I can figure out how to modify the script to do replace both frames with adjacent good frames in a single go. Not as good as the interpolation but an OK quick fix for now.

Thanks for all the help on this!

Wayne
WayneM wrote on 2/8/2015, 5:31 PM
@johnmeyer

I now have the script set up in VP13. It executes without error, but there is an anomoly that I haven't found a work around for.

First, it does exactly as expected, replacing a single bad 'jump' frame with an adjacent frame.

However, the single inserted frame is getting a fade-in curve applied to it and that shows up as being black. I'm not sure where that is coming from or if there is something I could add to the script to keep it from happening. Or a Default someplace that I need to change.

There is another thing happening, with Sony Curves applied to film segments, but I'm still seeing if I can work around that.

Any ideas?

Wayne