View Single Post
Old 18th May 2019, 20:10   #1  |  Link
LouieChuckyMerry
Registered User
 
LouieChuckyMerry's Avatar
 
Join Date: Feb 2014
Posts: 355
Help Inserting Resizing Between Denoising And Line Darkening

Happy Saturday! I'm wanting to insert a resize after the denoising but before the line darkening in an existing script, but I'm having trouble negotiating the transition from 16-bit to 8-bit back to 16-bit. The existing script is:

Code:
### Overall Temporal Denoise ###
SMDegrain(TR=2,ThSAD=200,ContraSharp=True,RefineMotion=True,Plane=0,Chroma=False,PreFilter=2,Lsb=True,Lsb_Out=True)
### Darken-Thin Lines ###
F=DitherPost(Mode=-1)
S=F.FastLineDarkenMod(Strength=24,Prot=6).aWarpSharp2(Blur=4,Type=1,Depth=8,Chroma=2)
D=MT_MakeDiff(S,F).Dither_Convert_8_To_16()
Dither_Add16(Last,D,Dif=True,U=2,V=2)
and the resize script is:

Code:
### Resize ###
NNEDI3_RPow2(4,CShift="Spline64Resize",FWidth=960,FHeight=720)
aWarpSharp2(Depth=5)
Sharpen(0.2)
I understand that SMDegrain is processing in 16-bits then outputting 16-bits, I understand what "DitherPost(Mode=-1)" means, I understand what the FastLineDarkenMod-aWarpSharp2 line is doing, and I understand the "Dither_Convert_8_16()" call, but I can't wrap my head around the red text. This:

Code:
### Overall Temporal Denoise ###
SMDegrain(TR=2,ThSAD=200,ContraSharp=True,RefineMotion=True,Plane=0,Chroma=False,PreFilter=2,LSB=True,LSB_Out=False)
### Resize ###
NNEDI3_RPow2(4,CShift="Spline64Resize",FWidth=960,FHeight=720) 
aWarpSharp2(Depth=5)
Sharpen(0.2)
### Darken-Thin Lines ###
Dither_Convert_8_To_16()
F=DitherPost(Mode=-1)
S=F.FastLineDarkenMod(Strength=24,Prot=6).aWarpSharp2(Blur=4,Type=1,Depth=8,Chroma=2)
D=MT_MakeDiff(S,F).Dither_Convert_8_To_16()
Dither_Add16(Last,D,Dif=True,U=2,V=2)
works, but I don't know if it's the most elegant solution (or if it's even correct). I guess what I'm really wondering: is there a "proper" way to incorporate the resizing with the red text? Thanks for any clarity .

Last edited by LouieChuckyMerry; 19th May 2019 at 23:35. Reason: DoubleComma!
LouieChuckyMerry is offline   Reply With Quote