Can I mask an effect?

BatvinkBatvink Website User Posts: 56 Just Starting Out

I am using the auto light flares effect, but would like to limit the lights in the screen that contribute the effect.

I tried duplicating the layer and masking the top layer with the effect, to just the lights I want to be affected. But this only applied the effect to the top layer and I got a very visible mask edge.

Is there a way to do this, or should I revert to manual light flares?

 

 

Comments

  • Triem23Triem23 Moderator Moderator, Website User, Ambassador, Imerge Beta Tester, HitFilm Beta Tester Posts: 18,228 Ambassador

    You need to preprocess your footage a bit to make the auto light flares work. Take your duplicate layer and convert it to a comp shot. Delete the Auto flares. Instead, Add a black plane under the footage. On the footage layer add a Threshold and a Blur. Use the Threshold so just the lights you want to flare are white  everything else black. Use the blur to soften a couple of pixels. Pure white (blurred) on black.

    In your main comp put this embedded comp over your main footage. Change blend mode to ADD. Apply Auto Lens Flares. From there, find the Blend mode and set to NONE. 

    Now adjust your flares. 

    The threshold/blur knocks out everything but the highlights you want to keep (You could also try the "Hotspots" effect for this step). Your mask gets rid of the lights you don't want, and the black background keeps it clean. By setting the Blend Mode in the Auto Flares to None, the layer becomes the actual "flare" over black. The Layer's Blend Mode determines Compositing. If you don't like ADD, try SCREEN. Also remember you can control intensity of the flare with the Layer's Opacity controls. 

  • BatvinkBatvink Website User Posts: 56 Just Starting Out

    That's a very useful technique for this and I guess many other masking requirements. Thanks for the detailed description...time to try it out :)

     

  • Triem23Triem23 Moderator Moderator, Website User, Ambassador, Imerge Beta Tester, HitFilm Beta Tester Posts: 18,228 Ambassador

    Glad to help.

    Yes, as you noted, this type of pre-processing can be useful for other effects. Especially flare and light ray type things.

    To expand a bit, Hitfilm processes a layer's masks first, then effects. By embedding the comp shot and running the effects there Hitfilm has to process and render the embedded comp to a layer before reading that layer in the main comp. So, we've "baked in" all the effects in the embed, allowing you to mask in the main comp.

    This is an order of operations thing and the concept can affect a lot of Hitfilm's workflow. 

    To expand this a little more - any effect in Hitfilm that reads a "source layer" is reading a "raw" layer without masks or FX. A classic example is creating a plane, adding Fractal Noise then putting Set Matte on a video layer and using the Fractal plane as the source - it won't work, because the Set Matte reads the source plane before the Fractal is applied. Converting the Fractal to an embedded Comp bakes in the Fractal - the "raw state" of an embedded comp is the render of the the comp! 

  • BatvinkBatvink Website User Posts: 56 Just Starting Out

    That explains a lot of challenges I have been dealing with. I need to read it back slowly and experiment to fully understand this. 

    Thanks again!

Sign In or Register to comment.