hi, i am having limited success achieving color keying using 2 stream of video. Have tried using the [pix_alpha] method and can achieve color keying using to picture sources or using video as the background and an image as the keyed foreground, but replacing the foreground image with a movie does not work. tried converting the foreground movie using [pix_rgba] but no use, it just screws up the color. using [pix_hsv2rgb] results in some sort of keying but not through the pix_alpha method just as a result of shifting the color fields around. i was wondering if a) what i am trying to do is just wrong b) some crucial step is missing c) GEM implementation on OS X is lacking
cheers, tim
hi, i am having limited success achieving color keying using 2 stream of video. Have tried using the [pix_alpha] method and can achieve color keying using to picture sources or using video as the background and an image as the keyed foreground, but replacing the foreground image with a movie does not work. tried converting the foreground movie using [pix_rgba] but no use, it just screws up the color. using [pix_hsv2rgb] results in some sort of keying but not through the pix_alpha method just as a result of shifting the color fields around. i was wondering if a) what i am trying to do is just wrong b) some crucial step is missing c) GEM implementation on OS X is lacking
which version of GEM are you using? there's not a final release for OSX yet so you might be using a broken or outdated version. try the one here: http://taproot.dyndns.org/~cgc/downloads/index.html (make sure you grab the appropriate one for either G3 or G4 cpu).
it has an object called pix_chroma_key that i wrote and it does keying on both RGB and YUV sources. it's usage is quite simple it takes a message for the key 'value' with three arguments for each color channel, and a 'range' message which is the range of values +/- the center value.
example for RGB: value 150 100 50 range 20 10 10
would key using the red channel for a range of 130 to 170 the green from 90 to 110 and blue 40 to 50. if this was for YUV it would be the same ranges for Y (luma) Cb (chroma-blue) and Cr (chroma-red) in that order.
there's also a 'direction' message that flips the keyed areas.
cheers, tim
On Saturday, June 21, 2003, at 08:35 AM, tim cleminson wrote:
hi, i am having limited success achieving color keying using 2 stream of video. Have tried using the [pix_alpha] method and can achieve color keying using to picture sources or using video as the background and an image as the keyed foreground, but replacing the foreground image with a movie does not work. tried converting the foreground movie using [pix_rgba] but no use, it just screws up the color. using [pix_hsv2rgb] results in some sort of keying but not through the pix_alpha method just as a result of shifting the color fields around. i was wondering if a) what i am trying to do is just wrong b) some crucial step is missing c) GEM implementation on OS X is lacking
hi tim,
...luckily, you just seem to be going about it the wrong way ;-) There are quite a few objects with the latest 0.88cvs version of GEM that do this: pix_composite, pix_chromakey, pix_mix, yuv_luma_key(note to self: needs to be moved to pix_ group), pix_mask, pix_multiply, and I'm sure there are others...all of these can mix two inputs together, just in different ways...
...don't forget that if you have a rage128 or above, you should probably use pix_filmYUV...
l8r, jamie