ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

After Effects Opacity Expression

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Allen Bian
After Effects Opacity Expression
on Nov 21, 2017 at 6:38:28 am

Hi guys, I wonder if someone here could help me with making an expression.
So my AE file is a double exposure template for users who are not familiar with after effects, users can drag sliders to control colors and opacity.
What I have in the comp are a completed double exposure and multiple images
I want to achieve when the user imports the first image the opacity will be 100% when import second image the opacity will be 50% and when impot three images into the comp will be 33.33, so on....
The template does everything automatically.

Return to posts index

DeMarc Johnson
Re: After Effects Opacity Expression
on Nov 22, 2017 at 2:08:27 am

You can do that by using arrays and index.
Just be mindful of order of layers when using index. If you have any other layers in the composition make sure that the those layers is underneath the image layers.

var list = [100, 50, 33]; //Change these numbers in this array to whatever you need the opacity to be and you can add or remove the amount of numbers too. Remember when adding or removing that each number is separated by commas.
list[index - 1];

For Expression Tutorials:

Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2018 All Rights Reserved