Thread: Chromashift
View Single Post
Old 17th December 2016, 23:10   #1  |  Link
juhok
Registered User
 
juhok's Avatar
 
Join Date: Dec 2005
Posts: 110
Chromashift

Q1: Is there an easier way to kick chroma around?

Code:
sl = 0
sr = 2

chroma_u = core.std.ShufflePlanes(video, planes=[1], colorfamily=vs.GRAY)
chroma_u = core.std.CropRel(chroma_u, left=sl)
chroma_u = core.std.AddBorders(chroma_u, right=sl)
chroma_u = core.std.CropRel(chroma_u, right=sr)
chroma_u = core.std.AddBorders(chroma_u, left=sr)

chroma_v = core.std.ShufflePlanes(video, planes=[2], colorfamily=vs.GRAY)
chroma_v = core.std.CropRel(chroma_v, left=sl)
chroma_v = core.std.AddBorders(chroma_v, right=sl)
chroma_v = core.std.CropRel(chroma_v, right=sr)
chroma_v = core.std.AddBorders(chroma_v, left=sr)

video = core.std.ShufflePlanes(clips=[video, chroma_u, chroma_v], planes=[0, 0, 0], colorfamily=vs.YUV)
Q2: Does Resize with 'matrix, transfer, primaries' do the work of Colormatrix() nowdays? Couldn't find much up to date discussion about this (maybe it's too obvious).
juhok is offline   Reply With Quote