Videoplane/Alphablend Q
Hi!
I was wondering if I could get help with a project I'm working on, a seemingly simple question but I'm stuck:
I'm trying to chromakey an image I created with a webcam feed (that I will distort with jit.pix), and then bring in a backdrop.
The problem I'm having is with the backdrop:
I attempted to use videoplanes and alphablend to get the backdrop to show but to no avail. It's just the chromakey.
Can anyone assist? Thanks in advance!
your patch has 3 video sources, two jit.movies and a jit.grab, so it's not clear what you're trying to achieve. to chromakey a live video feed (replacing a color in the live feed with a video), try this:
I wanted to replace a color in the image I made with a live stream, so the chromakey part I have working, thank you though! :) But what I was trying to achieve was add a second image source, a gif, in the alpha transparency of the movie that was being chromakeyed. So I have the output montage of the live feed and video from the chromakey, and I wanted to place a third gif behind that. Is that possible?
It's an effect like this alpha glue patch achieves, except I want to replace the output of one jit.movie with the output of the chromakey slab. I assume what is stopping me is the output of the slab, which I attempted converting to a matrix but still wouldn't work..
I'm sure the answer is glaringly obvious haha. Here is the alpha glue patch
ok i understand now. totally possible. don't readback to matrix, it's not necessary and will slow your patch down.
the easiest way to do this is with a simple jit.gl.pix patch, that takes the alpha value generated by the chromakey slab, and uses that to mix between two other input sources. you can flip what get's keyed and replaced with the chromakey's invert parameter.
you can also improve performance by setting @output_texture 1 on your jit.movie and jit.grab objects: