Search in the documentation for the Layer() function.
with colorKeyMask()
Basically you need to create a green clip,
and overlay the red part with layer.
Now be warned that it might work well on artificially produced color but not very much on other type of colors.
(eg: something that 'looks' red...)
There might be other filters that can do what you want,
but depending of what are your exact needs.
esby
|