Using Help | Contents | Index Back - Adobe AFTER EFFECTS 5.5 Help Manual

Table of Contents

Advertisement

Adobe After Effects Help
Using Help
|
Contents
Color conversion methods
Array [4] rgb_to_hsl(rgba) {rgba is an array [4]} Converts a color in RGBA space to HSLA
space. The input is an array specifying red, green, blue, and alpha, all in the range of 0.0 to
1.0. The resulting value is an array specifying hue, saturation, lightness, and alpha, also in
the range of 0.0 to 1.0. For example, "rgb_to_hsl(effect("Change Color").param("Color To
Change"))" .
Array [4] hsl_to_rgb(hsla) {hsla is an array [4]}. This is the opposite of rgb_to_hsl.
Comp attributes and methods
Camera active_camera Use this to retrieve a value from the camera through which the
composition is rendered at the current frame. This is not necessarily the camera through
which you are looking in the Composition window.
Number width Returns the composition's width value in pixels.
Number height Returns the composition's height value in pixels.
Number duration Returns the composition's duration value in seconds.
Number frame_duration Returns the frame duration in seconds.
Array [4]
Returns the background color of the composition.
bg_color
Number shutter_angle Returns the shutter-angle value of the composition in degrees.
Number shutter_phase Returns the shutter-phase of the composition in degrees.
Number num_layers Returns the number of layers in the composition.
Number pixel_aspect Returns the pixel aspect ratio of the composition expressed as
width/height.
Layer, Light, or Camera layer(index) {index is a number} Retrieves the layer by number
(order in the Timeline window). For example, "this_comp.layer(3)" .
Layer, Light, or Camera layer("name") {name is a string} Retrieves the layer by name.
Names are matched by layer name, or source name if there is no layer name. If duplicate
names exist, After Effects uses the first one in the Timeline window. For example,
"this_comp.layer("Solid 1")" .
Layer, Light, or Camera layer(other_layer, rel_index) {other_layer is a layer object, and
rel_index is a number} Retrieves the layer that is the rel_index (number) of layers above or
below the other_layer (name). For example, "layer(this_layer, -2)" returns the layer that is
two layers higher in the Timeline window than the layer on which the expression is
written.
Footage attributes and methods
To use footage from the Project window as an object in an expression, use the global
footage() method, as in "footage("filename")" and then use any of the attributes below.
You can also access a footage object using the source attribute on a layer whose source is
a footage item.
Number width Returns the width of the footage in pixels.
Number height Returns the height of the footage in pixels.
Number duration Returns the duration of the footage in seconds.
Number frame_duration Returns the duration of a frame in seconds.
Using Help
|
Contents
|
Index
|
Index
Creating Expressions
Back
258
Back
258

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents