Adobe After Effects Expression Controls
Adobe After Effects is a powerful tool for creating motion graphics and visual effects. One of the advanced features of After Effects is the use of expressions, which allow you to create sophisticated animations and effects using code. Expression Controls are special effect controls that let you create custom user interfaces for controlling these expressions.
In this tutorial, we will cover the main types of Expression Controls available in After Effects and show you how to integrate them with code to enhance your animations.
Types of Expression Controls

Here are the full list of expression controls:
Layer Control
The Layer Control is used to select a layer from the composition. This control is useful for linking properties between different layers.
How to Add a Layer Control:
- Right-click on the layer you want to add the control to.
- Select
Effect > Expression Controls > Layer Control
.
Example Usage:
// Link the position of a layer to the position of another layer selected via Layer Control
var selectedLayer = effect("Layer Control")("Layer");
selectedLayer.position;
Color Control
The Color Control lets you select a color. This control is useful for changing the color of a layer or effect dynamically.
How to Add a Color Control:
- Right-click on the layer you want to add the control to.
- Select
Effect > Expression Controls > Color Control
.
Example Usage:
// Link the color of a shape layer to a Color Control
var colorValue = effect("Color Control")("Color");
fillColor = colorValue;
Dropdown Menu Control
The Dropdown Menu Control allows you to create a dropdown menu with custom options. This control is useful for creating simple user interfaces with selectable options.
How to Add a Dropdown Menu Control:
- Right-click on the layer you want to add the control to.
- Select
Effect > Expression Controls > Dropdown Menu Control
. - Customize the options in the dropdown menu by clicking on the control and selecting
Edit
.
Example Usage:
// Use a Dropdown Menu Control to change the opacity of a layer based on the selected option
var dropdownValue = effect("Dropdown Menu Control")("Menu").value;
switch(dropdownValue) {
case 1:
opacity = 0;
break;
case 2:
opacity = 50;
break;
case 3:
opacity = 100;
break;
default:
opacity = 100;
}
3D Point Control
The 3D Point Control is used to specify a 3D point (x, y, z) in the composition. This control is useful for controlling positions or anchor points in 3D space.
How to Add a 3D Point Control:
- Right-click on the layer you want to add the control to.
- Select
Effect > Expression Controls > 3D Point Control
.
Example Usage:
// Link the position of a 3D layer to a 3D Point Control
var point3DValue = effect("3D Point Control")("3D Point");
position = point3DValue;
Slider Control
The Slider Control is one of the most versatile Expression Controls. It provides a simple slider that you can use to control numeric values in your expressions.
How to Add a Slider Control:
- Right-click on the layer you want to add the control to.
- Select
Effect > Expression Controls > Slider Control
.
Example Usage:
// Link the position of a layer to a Slider Control<br>var sliderValue = effect("Slider Control")("Slider");<br>position + [sliderValue, 0];
Angle Control
The Angle Control is used to control rotation angles. It provides a dial that you can use to adjust the angle value.
How to Add an Angle Control:
- Right-click on the layer you want to add the control to.
- Select
Effect > Expression Controls > Angle Control
.
Example Usage:
// Link the rotation of a layer to an Angle Control<br>var angleValue = effect("Angle Control")("Angle");<br>rotation + angleValue;
Checkbox Control
The Checkbox Control is a simple on/off switch. It is useful for toggling visibility or other binary states in your expressions.
How to Add a Checkbox Control:
- Right-click on the layer you want to add the control to.
- Select
Effect > Expression Controls > Checkbox Control
.
Example Usage:
// Use a Checkbox Control to toggle the opacity of a layer
var checkboxValue = effect("Checkbox Control")("Checkbox");
checkboxValue ? 100 : 0;
Color Control
The Color Control lets you select a color. This control is useful for changing the color of a layer or effect dynamically.
How to Add a Color Control:
- Right-click on the layer you want to add the control to.
- Select
Effect > Expression Controls > Color Control
.
Example Usage:
// Link the color of a shape layer to a Color Control
var colorValue = effect("Color Control")("Color");
fillColor = colorValue;
Point Control
The Point Control lets you specify a 2D point (x, y) in the composition. This is useful for controlling positions, anchor points, or other 2D properties.
How to Add a Point Control:
- Right-click on the layer you want to add the control to.
- Select
Effect > Expression Controls > Point Control
.
Example Usage:
// Link the position of a layer to a Point Control
var pointValue = effect("Point Control")("Point");
position = pointValue;
Integrating Expression Controls with Code
Expression Controls can be integrated with code to create dynamic and interactive animations. Here are some steps to help you get started:
Step 1: Add Expression Controls to Your Layer
First, add the desired Expression Controls to your layer using the steps outlined above.
Step 2: Write Expressions to Link Controls to Properties
Next, write expressions to link the properties of your layer to the values of the Expression Controls. You can access the value of an Expression Control using the effect
method, followed by the name of the control and the property you want to access.
Step 3: Test and Adjust
Finally, test your composition to see how the Expression Controls affect your animation. Adjust the values of the controls to fine-tune the effect.
Example Project
Let’s create an example project where we use multiple Expression Controls to animate a shape layer:
- Create a new composition and add a shape layer (e.g., a rectangle).
- Add the following Expression Controls to the shape layer:
- Slider Control (to control the x-position)
- Angle Control (to control the rotation)
- Color Control (to control the fill color)
- Link the properties of the shape layer to the Expression Controls using expressions.
Example Expressions:
// Link x-position to Slider Control
var xPos = effect("Slider Control")("Slider");
position = [xPos, position[1]];
// Link rotation to Angle Control
var rotationAngle = effect("Angle Control")("Angle");
rotation = rotationAngle;
// Link fill color to Color Control
var fillColor = effect("Color Control")("Color");
fillColor = fillColor;
With these expressions, you can now control the position, rotation, and fill color of the shape layer using the Expression Controls.
Conclusion
Expression Controls in Adobe After Effects are powerful tools that allow you to create customizable and dynamic animations using code. By linking properties to Expression Controls, you can create interactive user interfaces that make it easy to adjust and fine-tune your animations. Experiment with different types of controls and expressions to discover the full potential of this feature.
Happy animating!