View Single Post
Old 26th December 2019, 15:51   #6  |  Link
Overdrive80
Anime addict
 
Overdrive80's Avatar
 
Join Date: Feb 2009
Location: Spain
Posts: 673
http://avisynth.nl/index.php/VFR

Quote:
This is a 2-pass mode. Add this to your script:

TFM(mode=1,output="tfm.txt")
TDecimate(mode=4,output="stats.txt")
Open this and play through it in VirtualDub. Then close it, comment those lines out (or start a second script) and add:

TFM(mode=1)
TDecimate(mode=5,hybrid=2,dupthresh=1.0,input="stats.txt",tfmin="tfm.txt",mkvout="timecodes.txt")
Load and encode.
It is automate mode, if you want manual mode then:

1. Setting sections, you should noted parts.

Code:
YourLoader(".\VideoFile1.d2v", info=3)

ColorMatrix(hints=true, threads=0,interlaced=true)
2. With noted sections [f.e.: material FILM (0-38811), material NTSC (38812,0)], deinterlacing:

Code:
YourLoader(".\VideoFile1.d2v", info=3)

ColorMatrix(hints=true, threads=0,interlaced=true)

part1=trim(0,38811).tfm().tdecimate()
part2_in=trim(38812,41089) 


part2=part2_in.QTGMC( Preset="very Slow", EdiMode="EEDI2",fpsdivisor=2).assumefps(part1.framerate)

part1++part2
3. Generate timecodes:

Code:
YourLoader(".\VideoFile1.d2v", info=3)

ColorMatrix(hints=true, threads=0,interlaced=true)

part1=trim(0,38811).tfm().tdecimate()
part2_in=trim(38812,41089) 

part2=part2_in.QTGMC( Preset="very Slow", EdiMode="EEDI2",fpsdivisor=2).assumefps(part1.framerate)

part1++part2

WriteFile(last, "timecodesv1.txt" ,""" "# assume 29.970029" """, append=false)

WriteFile(last, "timecodesv1.txt" ,""" "0," """, "part1.framecount", """ "," """, "part1.framerate")

WriteFile(last, "timecodesv1.txt" , "part1.framecount+1", """ "," """ , "part1.framecount+part2.framecount-1",\
		 """ "," """, "part2_in.framerate")

return last
4. Muxing on mkv.

Manual mode is generic example, you must modify according to your needs.
__________________
Intel i7-6700K + Noctua NH-D15 + Z170A XPower G. Titanium + Kingston HyperX Savage DDR4 2x8GB + Radeon RX580 8GB DDR5 + ADATA SX8200 Pro 1 TB + Antec EDG750 80 Plus Gold Mod + Corsair 780T Graphite

Last edited by Overdrive80; 26th December 2019 at 15:55.
Overdrive80 is offline   Reply With Quote