View Single Post
Old 30th October 2010, 06:27   #39  |  Link
IanB
Avisynth Developer
 
Join Date: Jan 2003
Location: Melbourne, Australia
Posts: 3,167
Ouch! Yes this filter really only has a code path for YV12, although it should give correct results for RGB24 and near correct results for RGB32. It will be using the min(a, r, g, b) and the max(a, r, g, b) for its determinations, so the contents of the A channel can upset things. Unfortunately it will just make a mess of YUY2 chroma.

Given the filter just ploughs through RowSize bytes of data per line, you might get away with this :-
Code:
(orig is in YUY2 format)
tmp = orig.GreyScale().autolevels() # make all chroma bytes 128
orig = MergeLuma(orig, tmp) # Overlay new luma bytes
IanB is offline   Reply With Quote