Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
|
|
Thread Tools | Search this Thread | Display Modes |
1st March 2022, 14:30 | #1 | Link |
Registered User
Join Date: Feb 2022
Posts: 4
|
A script I improve simply may be better than Decimate?
There is the original script.https://forum.doom9.org/showthread.p...50#post1582950
Thank Sp00kyFox!It's based on his script. Code:
luma = tfm(pp=0, slow=2) chroma = vinverse().Srestore(omode="PP3", cache=4) # manual sync: figure out which frame (previous,current aka p,c) of 'chroma' clip is most similar to current frame of 'luma' clip # 46*log(|x-y|+1) uses the full [0,255]-range and scales little differences better than |x-y|*2 diffp = mt_lutxy(luma,chroma.selectevery(1,-1),"x y - abs 1 + log 46 *") diffc = mt_lutxy(luma,chroma, "x y - abs 1 + log 46 *") # average difference between compared frames mp = mt_lutf(diffp,diffp,"avg",expr="x") mc = mt_lutf(diffc,diffc,"avg",expr="x") # build conditional masks based on the caculated comparisons maskp = mt_lutxy(mp,mc,"x y < 255 0 ?") # finally merge the luma of the tfm with the chroma of the srestore clip accordingly to the binary mask p = MergeChroma(luma,chroma).mt_merge(chroma.selectevery(1,-1),maskp,luma=true,Y=2,U=3,V=3) #irlnic:the result is interlaced frames are replaced by previous frames #the following are what I write #replace interlaced frames with next frames in the clip n = p.selectevery(1,1) n = ConditionalFilter(src,n,p,"IscombedTIVTC","=","true") #delete surplus frames by pattern of telecine I find Interleave(p,n) SelectEvery(5 ,0,1,2,3) SelectEvery(2 ,0) Last edited by irlnic; 2nd March 2022 at 06:05. |
1st March 2022, 17:22 | #3 | Link | |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
Quote:
Code:
chroma = vinverse2().Srestore(omode="PP3", cache=4) diffp = mt_lutxy(luma,chroma.selectevery(1,-1),"x y - abs 1 + log 46 *") Maybe post the full script irlnic. EDIT: Also irlnic, wrap code in code tags, looks better, [retains indent formatting] ie, [CODE] some code stuff. [/CODE] looks like Code:
some code stuff. and welcome to the forum.
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? Last edited by StainlessS; 1st March 2022 at 17:36. |
|
1st March 2022, 17:39 | #4 | Link | |
Registered User
Join Date: Feb 2022
Posts: 4
|
Quote:
There is the original script.https://forum.doom9.org/showthread.php?t=165357 After I used Sp00kyFox's script(I don't know how it work),I found the result is interlaced frames are replaced by previous frames(because of selectevery(1,-1)). At the same time,I might find regularity of telecine as well. then I write Code:
n = p.selectevery(1,1) n = ConditionalFilter(b,n,p,"IscombedTIVTC","=","true") by using the regularity,I write Code:
Interleave(p,n) SelectEvery(5 ,0,1,2,3) SelectEvery(2 ,0) It's not very easy for me to explan what is the regularity in English,but I think you can get it after reading this part and apply it to a sample source on the paper. All in all, except 3:2 pull down,all interlaced frames are surplus.all I want to do is to delete them directly.Luckily,"3:2 pull down" can be solved by Sp00kyFox's script. Last edited by irlnic; 1st March 2022 at 18:52. |
|
1st March 2022, 18:12 | #5 | Link | |
Registered User
Join Date: Feb 2022
Posts: 4
|
Quote:
|
|
1st March 2022, 20:34 | #6 | Link | ||
Registered User
Join Date: Feb 2016
Location: Nonsense land
Posts: 339
|
Sorry irlnic, I didn't notice it was your first post/message. Well welcome!
Quote:
Anyway, irlnic, max tomorrow and I will give you my feedback. Quote:
EDIT: BTW do you have a small sample with field blending on chroma? I don't have any and the original script is meant for that and yours seems too. Last edited by Ceppo; 1st March 2022 at 21:05. |
||
2nd March 2022, 00:40 | #7 | Link |
Registered User
Join Date: Jan 2018
Posts: 2,156
|
Just copy/paste
https://github.com/realfinder/AVS-St.../Srestore.avsi |
2nd March 2022, 04:31 | #8 | Link | ||
Registered User
Join Date: Feb 2022
Posts: 4
|
Quote:
Quote:
But this isn't problem of source.It occurs after TFM.There are some similar threads you can find in the forum. Last edited by irlnic; 2nd March 2022 at 06:07. |
||
Tags |
ivtc |
|
|