MonoS
15th December 2014, 19:42
I wrote that LUT for having a 16bit hist.Luma until my change in the repo will be integrated upstream [maybe in r26 of VS]
def Luma16(x):
p = x << 4
if (p & (0xffff + 1)):
return (0xffff - (p&0xffff))
else:
return p&0xffff
USAGE
clipGray = core.std.ShufflePlanes(clip, planes=0, colorfamily=vs.GRAY)
luma = core.std.Lut(clipGray, function=Luma16)
More information can be found in my pull request here https://github.com/dubhater/vapoursynth-histogram/pull/1
def Luma16(x):
p = x << 4
if (p & (0xffff + 1)):
return (0xffff - (p&0xffff))
else:
return p&0xffff
USAGE
clipGray = core.std.ShufflePlanes(clip, planes=0, colorfamily=vs.GRAY)
luma = core.std.Lut(clipGray, function=Luma16)
More information can be found in my pull request here https://github.com/dubhater/vapoursynth-histogram/pull/1