Avisynth script to fix offset interlacing?
Paging sanlyn. :cool:
I have an odd VHS video where the fields are wonky. It looks like the camera has double vision. If you run separatefields(), the problem is obvious. Every odd frame is fine. Every even frame is shifted down about 4 pixels. I need an Avisynth script to shift the fields back into correct position. But I'm just coming up blank of what syntax to use here. |
Quote:
First convert the video to 4:2:2, unless it's already RGB. Then SeparateFields() Set e = Select the even fields, crop (0,4,0,0) takes 4 pixels off the top, then AddBorders(0,0,0,4) adds 4 pixels to the bottom and shifts the image up... Code:
ConvertToYUY2(interlaced=true) |
1 Attachment(s)
Sample attached. :salute:
Although it appears to be 2 or 4 fields deep. it was actually only 1 pixel off. I did forget that separatefields() was already shifting it. This worked: Code:
SeparateFields() The timing on it is horrible. With a line TBC in a JVC, it vertically jitters nonstop. With a Panasonic AG-1980P field TBC, it has this interlace reversal issue. With no TBC, it does everything from tearing to wiggling to jittering. That is obviously the root cause of the error, but I'm not sure why Panasonic is grabbing the wrong line. I can only guess that the line is so damaged as to disappear from its detection? I've not yet tested for field dominance, and hope that won't be an issue. Worst case is I just run QTGMC on it. At least that's an upgrade from drop-field. BTW: For some dumb reason, I forgot e,o (in my case a,b) in interleave. Oops. That's why I was having a syntax issue. Thanks. :) |
Just wanted to give a very big thank you to lordsmurf for asking about this, and to sanlyn for posting this little bit of code! I tried it, and I think it's going to be the solution to what's been troubling me with JVC TBC/NR feature having moments of vertical jitter. It will be tedious to inspect every frame of video, but it's better than trying to splice together multiple captures with tracking and/or tape path adjustments. It's easier to work digital than analog! :)
Just as an aside for anyone who might also be in this situation. I had the same issue as LS described here using JVC Line TBC/NR feature. I found when I turned it off (and without the video stabilizer feature turned on), the jitter went away. But, of course, without that the chroma suffers. Most of the jitter is for one to a few frames every couple/few minutes. Some spots had pretty much continuous jitter for several minutes. But I found making a slight tweak to the tape path screw by the video drum can greatly reduce those spots that heavily jittered for several minutes. Although if I go too far, the HiFi audio can get some crackles. The JVC TBC/NR is a wonderful feature, but it seems a bit sensitive. |
The S-VHS tape I had refused to even play on a JVC deck, complete noise and instability. It was too much for the JVC line TBC to handle. The Panasonic multi-line/field TBC made the tape mostly behave, but this was the side effect.
Then you have a JVC that show momentary jitter every several minutes, it's again the tape. I know for a fact that (1) using JVC S-VHS as the recording deck (2) leaving calibration ON while recording (never do this!) (3) then playing back in a JVC, even the same JVC that recorded the tape, shows jitters (4) yet tape plays fine in AG-1980 ^ An offline friend, and a long-time member of this site (though rarely posts, just reads), made that mistake. I had to convert all of his VHS recordings for him. He made that exact mistake. The recording quality is the issue, not the player. Always remember that. |
Site design, images and content © 2002-2024 The Digital FAQ, www.digitalFAQ.com
Forum Software by vBulletin · Copyright © 2024 Jelsoft Enterprises Ltd.