Quantcast
Channel: Adobe Community : Popular Discussions - After Effects Expressions
Viewing all articles
Browse latest Browse all 47983

Inverse Opacity

$
0
0

I have two layers. I want one to be on while the other is off. Neither one can be visible at the same time. But one of them always has to be visible.

 

I came up with a pretty simple expression to make one layer fade off while another fades on.

b = thisComp.layer("White Solid").transform.opacity;

Math.abs(b-100)

 

But it doesn't work if either layer's maximum opacity is an artibrarty value (like Layer A's max opacity should be 70% and Layer B's is 30%). Yes, I could precomp to get opacities back to 100%, but I'd rather not.


Viewing all articles
Browse latest Browse all 47983

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>