View Full Version : TDecimate Override
bxyhxyh
9th March 2014, 14:11
I need to use TDecimate on two videos and combine them.
If I just decimate separately, combination of them can be lead to jerky video.
So I need to override second decimatation as first decimation.
How do I do this?
s=source
d1=s.decrawlfilter1()
d2=s.decrawlfilter2()
d1=d1.tfm().tdecimate()
d2=d2.tfm().tdecimate() # This decimation should be overrided by previous decimation.
ConditionalFilter(d1,d2,d1,"YDifferenceFromPrevious", ">", "0.6")
Guest
9th March 2014, 16:44
Combine the clips before applying IVTC?
d1=s.decrawlfilter1()
d2=s.decrawlfilter2()
combined = d1++d2
combined.tfm().tdecimate()
It's not clear why the clip would become jerky doing it the original way. I might possibly expect a glitch at the junction.
bxyhxyh
9th March 2014, 17:50
Oh, sorry my English is not good.
What I wanted is to replace frames that decrawfilter1() couldn't fix with decrawfilter2() could. But decimation can be different on two videos because of moving dots.
In my case, d1 and d2 has one frame difference for some parts.
For example d1's 1010th frame is equal to d2's 1011th frame, if i replace d1's 1010th frame with d2's 1010th frame, video becomes jerky.
poisondeathray
9th March 2014, 18:30
The calculations can be different for both tfm and tdecimate, because you are applying a different dotcrawl filter before TIVTC
One way to do this is decide which version you want, then generate an output log file for both TFM(output="TFMlog.txt") and TDecimate(output="TDecimatelog.txt") , then use that output log file as input file for the 2nd version
Also, are you using a frame accurate source filter ?
colours
10th March 2014, 03:33
s = source
d1 = s.decrawlfilter1()
d2 = s.decrawlfilter2()
d12 = stackvertical(d1,d2).tfm().tdecimate()
d1 = d12.crop(0,0,source.width(),source.height())
d2 = d12.crop(0,source.height(),source.width(),source.height())
ConditionalFilter(d1,d2,d1,"YDifferenceFromPrevious", ">", "0.6")
This may be considerably slower (both decrawl filters are always called for every frame), but doesn't require a separate pass for getting metrics. Alternatively, you could decimate after using ConditionalFilter, instead of before; assuming TFM doesn't match from the wrong field, this should work too.
s = source
d1 = s.decrawlfilter1().tfm()
d2 = s.decrawlfilter2().tfm()
ConditionalFilter(d1,d2,d1,"YDifferenceFromPrevious", ">", "0.6")
tdecimate()
bxyhxyh
10th March 2014, 10:53
One way to do this is decide which version you want, then generate an output log file for both TFM(output="TFMlog.txt") and TDecimate(output="TDecimatelog.txt") , then use that output log file as input file for the 2nd version
I've tried this method, but it said crc doesn't match.
This may be considerably slower (both decrawl filters are always called for every frame), but doesn't require a separate pass for getting metrics. Alternatively, you could decimate after using ConditionalFilter, instead of before; assuming TFM doesn't match from the wrong field, this should work too.
s = source
d1 = s.decrawlfilter1().tfm()
d2 = s.decrawlfilter2().tfm()
ConditionalFilter(d1,d2,d1,"YDifferenceFromPrevious", ">", "0.6")
tdecimate()
I've tried it too. It won't work because of duplicate of d1, some frames remain dot crawled.
My last resort is this
s = source
s.decrawlfilter1().decrawlfilter2()
TFM().TDecimate()
Since they don't delete so much details. It should be ok.
vBulletin® v3.8.11, Copyright ©2000-2025, vBulletin Solutions Inc.