How to get alpha value of movie clip input in compositor?

Hi there, I’m trying to combine a couple of videos together and then use the compositor nodes to apply an effect to the result.

Initially I though I could somehow route the output of the VSE into an input node in the compositor, but a quick google seems to suggest that this is not possible.

So I tried to use video input nodes to add and combine the two clips directly in the compositor, which works, although I can’t seem to route the alpha value of the input video into other nodes in my setup, which I need to do in order for the finished result to have a transparent background…

Here’s the node setup from when I was taking the render layer directly into the compositor:


As you can see, as soon as I do the color ramp, the alpha background turns to black, but I was getting around this by routing the alpha value back into the final result. Unfortunately if I use video input nodes, I have no way of taking the alpha value out like this.

Apart from re-rendering the original at the same time, and compositing from that, (which after a day of rendering that part already, I’m reluctant to do) I feel like i’m a bit stuck…

Change the black colorstop on the ramp so that it’s alpha is set to 0.
As that colorstop is controlling the Alpha, and it’s alpha is set to 1.0, it is basically replacing the Alpha with a solid black colour. The cube will remain looking the same though as the black colour is still there, but the alpha isn’t. Change it to a hot pink colour but keep the alpha at 0 and see how the white fades into the pink and the alpha.

I hope this helps!

Changed that black colourstop to alpha 0, and then routed the alpha output to the alpha input of the composite node, but all that did was make all areas of the image that fell below that threshold transparent, which is to be expected.

The problem seems to stem from the Hue/Saturation node, which seems to discard alpha information…

In fact, it seems to be that passing an image through any node causes the alpha information to be lost…

There are separator nodes to split alpha from image, so you can process it separately.

Aha, found that node, and using it to get the alpha component from the original gives the expected result when routed into a viewer node, but connecting it to the alpha input of the composite node has no effect. In face, setting the alpha value to 0 in that final composite node makes no effect either… Weird…