hydra3333
31st July 2016, 12:50
A newbie to python and vapoursynth seeks assistance on how to re-interlaced a deinterlaced 576p50 (50 fps) clip into 576i25 (25 fps).
Example script;
import vapoursynth as vs
import havsfunc as haf
import mvsfunc as mvs
core = vs.get_core(accept_lowercase=True)
core.std.LoadPlugin(r'c:\software\dgdecodenv\dgdecodenv.DLL')
# todo: figure out what else to "LoadPlugin" so that QTGMC just works (google how to do that in VS)
video = core.dgdecodenv.DGSource(r'D:\Temp\Video\test.dgi') # interlaced TFF input, PAL 576i 25fps, or PAL 1080i 25fps
# todo: put an interlaced-aware deblocker in here before QTGMC since the broadcasts are very usually blocky as all heck (google how to do that in VS)
video = haf.QTGMC(Preset="Very Slow", TFF=True,EdiThreads=4,SLMode=2,EZKeepGrain=1.2,NoiseProcess=2) # result is double framerate progressive, so re-interlate it later
# todo: do other stuff including sharpen (google how to do that in VS)
# todo: if required, resize to 576p (google how to do that in VS)
Now I need to reinterlace the "double framerate" deinterlaced (50p progressive) clip (don't ask, it's to do with "motion fluidity" for fast-moving sports videos panning across a very large grassed arena).
Avisynth is like this for TFF:
Blur(0,0.25).SeparateFields().SelectEvery(4,0,3).Weave() #reinterlace - ASSUMED TFF HERE # BLUR(0,1) per http://forum.doom9.org/showthread.php?p=1488308#post1488308
However I appear have mis-read 3 possible VS methods after googling it.
(1) (not sure the syntax is correct)
video = core.std.SeparateFields(video, tff=True)
video = core.std.SelectEvery(video, cycle=4, offsets=[0, 3]) # looks like avisynth ?
video = haf.Weave(video, tff=True)
video = mvs.AssumeTFF(video)
(2) (definitely not sure the syntax is correct)
video = core.std.DoubleWeave(clip=video, tff=True)[::2]
video = mvs.AssumeTFF(video)
(3)
video = core.std.SelectEvery(video, 4, [0, 3])
video = haf.Weave(video, tff=True)
video = mvs.AssumeTFF(video)
Advice sought.
Example script;
import vapoursynth as vs
import havsfunc as haf
import mvsfunc as mvs
core = vs.get_core(accept_lowercase=True)
core.std.LoadPlugin(r'c:\software\dgdecodenv\dgdecodenv.DLL')
# todo: figure out what else to "LoadPlugin" so that QTGMC just works (google how to do that in VS)
video = core.dgdecodenv.DGSource(r'D:\Temp\Video\test.dgi') # interlaced TFF input, PAL 576i 25fps, or PAL 1080i 25fps
# todo: put an interlaced-aware deblocker in here before QTGMC since the broadcasts are very usually blocky as all heck (google how to do that in VS)
video = haf.QTGMC(Preset="Very Slow", TFF=True,EdiThreads=4,SLMode=2,EZKeepGrain=1.2,NoiseProcess=2) # result is double framerate progressive, so re-interlate it later
# todo: do other stuff including sharpen (google how to do that in VS)
# todo: if required, resize to 576p (google how to do that in VS)
Now I need to reinterlace the "double framerate" deinterlaced (50p progressive) clip (don't ask, it's to do with "motion fluidity" for fast-moving sports videos panning across a very large grassed arena).
Avisynth is like this for TFF:
Blur(0,0.25).SeparateFields().SelectEvery(4,0,3).Weave() #reinterlace - ASSUMED TFF HERE # BLUR(0,1) per http://forum.doom9.org/showthread.php?p=1488308#post1488308
However I appear have mis-read 3 possible VS methods after googling it.
(1) (not sure the syntax is correct)
video = core.std.SeparateFields(video, tff=True)
video = core.std.SelectEvery(video, cycle=4, offsets=[0, 3]) # looks like avisynth ?
video = haf.Weave(video, tff=True)
video = mvs.AssumeTFF(video)
(2) (definitely not sure the syntax is correct)
video = core.std.DoubleWeave(clip=video, tff=True)[::2]
video = mvs.AssumeTFF(video)
(3)
video = core.std.SelectEvery(video, 4, [0, 3])
video = haf.Weave(video, tff=True)
video = mvs.AssumeTFF(video)
Advice sought.