Brugerhåndbog Annuller

Precomposing, nesting, and pre-rendering

  1. After Effects User Guide
  2. Beta releases
    1. Beta Program Overview
    2. After Effects Beta Home
  3. Getting started
    1. Get started with After Effects
    2. What's new in After Effects 
    3. Release Notes | After Effects
    4. After Effects system requirements
    5. Keyboard shortcuts in After Effects
    6. Supported File formats | After Effects
    7. Hardware recommendations
    8. After Effects for Apple silicon
    9. Planning and setup
  4. Workspaces
    1. General user interface items
    2. Get to know After Effects interface
    3. Workflows
    4. Workspaces, panels, and viewers
  5. Projects and compositions
    1. Projects
    2. Composition basics
    3. Precomposing, nesting, and pre-rendering
    4. View detailed performance information with the Composition Profiler
    5. CINEMA 4D Composition Renderer
  6. Importing footage
    1. Preparing and importing still images
    2. Importing from After Effects and Adobe Premiere Pro
    3. Importing and interpreting video and audio
    4. Preparing and importing 3D image files
    5. Importing and interpreting footage items
    6. Working with footage items
    7. Detect edit points using Scene Edit Detection
    8. XMP metadata
  7. Text and Graphics
    1. Text
      1. Formatting characters and the Character panel
      2. Text effects
      3. Creating and editing text layers
      4. Formatting paragraphs and the Paragraph panel
      5. Extruding text and shape layers
      6. Animating text
      7. Examples and resources for text animation
      8. Live Text Templates
    2. Motion Graphics
      1. Work with Motion Graphics templates in After Effects
      2. Use expressions to create drop-down lists in Motion Graphics templates
      3. Work with Essential Properties to create Motion Graphics templates
      4. Replace images and videos in Motion Graphics templates and Essential Properties
      5. Animate faster and easier using the Properties panel
  8. Drawing, Painting, and Paths
    1. Overview of shape layers, paths, and vector graphics
    2. Paint tools: Brush, Clone Stamp, and Eraser
    3. Taper shape strokes
    4. Shape attributes, paint operations, and path operations for shape layers
    5. Use Offset Paths shape effect to alter shapes
    6. Creating shapes
    7. Create masks
    8. Remove objects from your videos with the Content-Aware Fill panel
    9. Roto Brush and Refine Matte
  9. Layers, Markers, and Camera
    1. Selecting and arranging layers
    2. Blending modes and layer styles
    3. 3D layers
    4. Layer properties
    5. Creating layers
    6. Managing layers
    7. Layer markers and composition markers
    8. Cameras, lights, and points of interest
  10. Animation, Keyframes, Motion Tracking, and Keying
    1. Animation
      1. Animation basics
      2. Animating with Puppet tools
      3. Managing and animating shape paths and masks
      4. Animating Sketch and Capture shapes using After Effects
      5. Assorted animation tools
      6. Work with Data-driven animation
    2. Keyframe
      1. Keyframe interpolation
      2. Setting, selecting, and deleting keyframes
      3. Editing, moving, and copying keyframes
    3. Motion tracking
      1. Tracking and stabilizing motion
      2. Face Tracking
      3. Mask Tracking
      4. Mask Reference
      5. Speed
      6. Time-stretching and time-remapping
      7. Timecode and time display units
    4. Keying
      1. Keying
      2. Keying effects
  11. Transparency and Compositing
    1. Compositing and transparency overview and resources
    2. Alpha channels and masks
    3. Track Mattes and Traveling Mattes
  12. Adjusting color
    1. Color basics
    2. Color management
    3. Color Correction effects
    4. OpenColorIO and ACES color management
  13. Effects and Animation Presets
    1. Effects and animation presets overview
    2. Effect list
    3. Effect Manager
    4. Simulation effects
    5. Stylize effects
    6. Audio effects
    7. Distort effects
    8. Perspective effects
    9. Channel effects
    10. Generate effects
    11. Time effects
    12. Transition effects
    13. The Rolling Shutter Repair effect
    14. Blur and Sharpen effects
    15. 3D Channel effects
    16. Utility effects
    17. Matte effects
    18. Noise and Grain effects
    19. Detail-preserving Upscale effect
    20. Obsolete effects
  14. Expressions and Automation
    1. Expressions
      1. Expression basics
      2. Understanding the expression language
      3. Using expression controls
      4. Syntax differences between the JavaScript and Legacy ExtendScript expression engines
      5. Editing expressions
      6. Expression errors
      7. Using the Expressions editor
      8. Use expressions to edit and access text properties
      9. Expression language reference
      10. Expression examples
    2. Automation
      1. Automation
      2. Scripts
  15. Immersive video, VR, and 3D
    1. Construct VR environments in After Effects
    2. Apply immersive video effects
    3. Compositing tools for VR/360 videos
    4. Advanced 3D Renderer
    5. Import and add 3D models to your composition
    6. Import 3D models from Creative Cloud Libraries
    7. Image-Based Lighting
    8. Extract and animate lights and cameras from 3D models
    9. Tracking 3D camera movement
    10. Cast and accept shadows
    11. Embedded 3D model animations
    12. Shadow Catcher
    13. 3D depth data extraction
    14. Modify materials properties of a 3D layer
    15. Work in 3D Design Space
    16. 3D Transform Gizmos
    17. Do more with 3D animation
    18. Preview changes to 3D designs real time with the Mercury 3D engine
    19. Add responsive design to your graphics 
  16. Views and Previews
    1. Previewing
    2. Video preview with Mercury Transmit
    3. Modifying and using views
  17. Rendering and Exporting
    1. Basics of rendering and exporting
    2. H.264 Encoding in After Effects
    3. Export an After Effects project as an Adobe Premiere Pro project
    4. Converting movies
    5. Multi-frame rendering
    6. Automated rendering and network rendering
    7. Rendering and exporting still images and still-image sequences
    8. Using the GoPro CineForm codec in After Effects
  18. Working with other applications
    1. Dynamic Link and After Effects
    2. Working with After Effects and other applications
      1. Export After Effects project as Premiere Pro project
    3. Sync Settings in After Effects
    4. Creative Cloud Libraries in After Effects
    5. Plug-ins
    6. Cinema 4D and Cineware
  19. Collaboration: Frame.io, and Team Projects
    1. Collaboration in Premiere Pro and After Effects
    2. Frame.io
      1. Install and activate Frame.io
      2. Use Frame.io with Premiere Pro and After Effects
      3. Frequently asked questions
    3. Team Projects
      1. Get Started with Team Projects
      2. Create a Team Project
      3. Collaborate with Team Projects
  20. Memory, storage, performance
    1. Memory and storage
    2. How After Effects handles low memory issues while previewing    
    3. Improve performance
    4. Preferences
    5. GPU and GPU driver requirements for After Effects
  21. Knowledge Base
    1. Known issues
    2. Fixed issues
    3. Frequently asked questions
    4. After Effects and macOS Ventura
    5. How After Effects handles low memory issues while previewing

About precomposing and nesting

If you want to group some layers that are already in a composition, you can precompose those layers. Precomposing layers places them in a new composition, which replaces the layers in the original composition. The new nested composition becomes the source for a single layer in the original composition. The new composition appears in the Project panel and is available for rendering or use in any other composition. You can nest compositions by adding an existing composition to another composition, just as you would add any other footage item to a composition. Precomposing a single layer is useful for adding transform properties to a layer and influencing the order in which elements of a composition are rendered.

Nesting is the inclusion of one composition within another. The nested composition appears as a layer in the containing composition.

A nested composition is sometimes called a precomposition, which is occasionally abbreviated in casual use to precomp or pre-comp. When a precomposition is used as the source footage item for a layer, the layer is called a precomposition layer.

During rendering, the image data and other information can be said to flow from each nested composition into the composition that contains it. For this reason, nested compositions are sometimes referred to as being upstream of the compositions that contain them, and the containing compositions are said to be downstream of the nested compositions that they contain. A set of compositions connected through nesting is called a composition network. You can navigate within a composition network using the Composition Navigator and Mini-Flowchart. Learn more about opening and navigating nested compositions.

Tip:

Precompositions in After Effects are similar to Smart Objects in Adobe Photoshop.

Uses for precomposing and nesting

Precomposing and nesting help manage and organize complex compositions. By precomposing and nesting, you can do the following:

  • Apply complex changes to an entire composition: You can create a composition containing multiple layers, nest the composition within the overall composition, and animate and apply effects to the nested composition so that all the layers change in the same ways over the same period.
  • Reuse anything you build: You can build an animation in its own composition and then drag that composition into other compositions as many times as you want.
  • Update in one step: When you make changes to a nested composition, those changes affect every composition in which it's used, just like changes made to a source footage item affect every composition in which it's used.
  • Alter the default rendering order of a layer: You can specify that After Effects render a transformation (such as rotation) before rendering effects so that the effect applies to the rotated footage.
  • Add another set of transform properties to a layer: The layer representing the composition has its own properties in addition to the properties of the layers it contains. This allows you to apply an additional set of transformations to a layer or set of layers.

Preferences and composition settings that affect nested compositions

Because a precomposition is itself a layer, you can control its behavior using layer switches and composition switches in the Timeline panel. You can choose whether changes made to the switches in the containing composition are propagated to the nested composition. To prevent layer switches from affecting nested compositions, select Edit > Preferences > General (Windows) or After Effects > Settings > General (macOS), and then deselect Switches Affect Nested Comps.

In the Advanced tab of the Composition Settings dialog box (Composition > Composition Settings), select Preserve resolution when nested or Preserve frame rate when nested or in render queue for a composition to retain its own resolution or frame rate, and not inherit those settings from the containing composition. For example, if you deliberately used a low frame rate in a composition to create a jerky, hand-animated result, you should preserve the frame rate for that composition when it's nested. Similarly, the rotoscoping results may look wrong when converted to a different frame rate or resolution. Use this setting instead of the Posterize Time effect, which is less efficient.

Changing the current time in one panel updates the current time in other panels associated with that composition. By default, the current time is also updated for all compositions related to the current composition by nesting. To prevent compositions related by nesting from updating their current times when you change the current time in one composition, deselect the Synchronize Time Of All Related Items preference (Edit > Preferences > General (Windows) or After Effects > Settings > General (macOS)).

Precompose layers

Precomposing layers places them in a new composition, often referred to as a precomposition or precomp. This action replaces the selected layers in the original composition with a single layer that represents the new precomposition. Precomposing a single layer is useful for adding transform properties to a layer and influencing the order in which elements of a composition are rendered.

  1. Select the layers in the Timeline panel, and select Layer > Pre-compose or press Ctrl+Shift+C (Windows) or Command+Shift+C (macOS).

  2. Select one of the following:

    Leave all attributes in

    Leaves the properties and keyframes of the precomposed layer in the original composition, applied to the new layer that represents the precomposition. The frame size of the new composition is the same as the size of the selected layer. This option isn't available when you select more than one layer, a text layer, or a shape layer.

    Move all attributes into the new composition

    Moves the properties and keyframes of the precomposed layers one level further from the root composition in the composition hierarchy. When you use this option, changes you applied to the properties of the layers remain with the individual layers within the precomposition. The frame size of the new composition is the same as the frame size of the original composition.

Effects can include masks and effects of other layers

Effects that use layers as an input, such as - Set Matte and Displacement Map, target the masks and effects of the input layer. You can use these layers without pre-composing them for the purpose of being referenced by an effect. 

The control is similar to the function of the View menu at the bottom of the Layer viewer panel which allows you to render the layer from different positions in the rendering order– from its source, from its masks, or from its individual effects.

For effects with layer properties, open the Input Parameter menu to the right of the layer selection and choose the target input layer such as:

  • Source: Targets only the source of the layer. Masks and effects are ignored.
  • Masks: Targets the layer after its masks are applied. Effects are ignored.
  • Effects & Masks: Targets the layer after its masks and effects are applied.

Opening and navigating nested compositions

Nested compositions are sometimes referred to as being upstream of the compositions that contain them, and the containing compositions are said to be downstream of the nested compositions that they contain. The root composition is the most downstream– the most deeply nested composition is the most upstream. A composition flow path is a chain of compositions related to one another by containing or being nested within one another. A composition network is the entire set of compositions related to one another through nesting.

After Effects provides several ways to open a nested composition (precomposition):

  • Double-click the composition entry in the Project panel.
  • Double-click a precomposition layer in the Timeline panel. Alt-double-click (Windows) or Option-double-click (macOS) to open the precomposition layer as a layer in the Layer panel.
Bemærk:

Double-clicking a precomposition layer when a paint tool or the Roto Brush tool is active opens the layer in the Layer panel.

  • To open the most recently active composition in the same composition network as the currently active composition, use Shift+Esc.

  • Use the Composition Navigator.

  • Use the Composition Mini-Flowchart.

The Composition Navigator

The Composition Navigator is a bar along the top edge of the Composition panel that shows the composition active in that viewer in relation to other compositions in the same composition network. The compositions shown are the most recently active compositions in the flow path of the currently active composition.

Composition Navigator

A. Arrow for opening Composition Mini-Flowchart  B. Panel menu button C. Active (current) composition 

Arrows between the composition names indicate the direction in which pixel information flows for this flow path. The default is to show compositions in the Composition Navigator bar with downstream compositions on the left and upstream compositions on the right. This default is indicated by the Flow Right To Left option in the Composition panel menu. To show compositions in the other order, choose Flow Left To Right. This setting is a global preference– it applies to all compositions and to the Composition Mini-Flowchart view.

The names of downstream compositions are dim to indicate that their contents are not used or shown in the active composition.

  • To show or hide the Composition Navigator bar, select Show Composition Navigator from the Composition panel menu.

  • To activate any composition shown in the Composition Navigator bar, select the composition name.

  • If the flow path is too long to show in the Composition panel, an ellipsis button appears at the left or right edge of the Composition Navigator bar. To temporarily show the entire flow path, select the ellipsis button.

Bemærk:

To scroll through a long flow path, place the pointer over a composition button in the Composition Navigator and roll the mouse scroll wheel.

The Composition Mini-Flowchart

The Composition Mini-Flowchart is a transient control that you can use to quickly navigate within a composition network. When you open the Composition Mini-Flowchart, it shows the compositions immediately upstream and downstream of the selected composition.

Colors in the Composition Mini-Flowchart are based on the label colors assigned to compositions in the Project panel. If a composition is used multiple times within one composition, the multiple instances of the nested composition appear as one entry with a number in parentheses indicating the number of instances.

To open the Composition Mini-Flowchart, do one of the following:

Composition Mini-Flowchart is open and shows the compositions immediately upstream and downstream of the selected composition.

A. Indicator that composition does not flow into other compositions B. Direction of flow C. Active (current) composition 

  • Use the Tab key when a Composition, Layer, or Timeline panel is active.
  • Select the arrow to the right of a composition name in the Composition Navigator bar.

  • Select Composition Mini-Flowchart from the Composition menu, the Composition panel menu, or the Timeline panel menu.

  • Select the Composition Mini-Flowchart    button at the top of the Timeline panel.

As with the Composition Navigator, you can choose whether to show the flow direction from left to right or from right to left. Arrows indicate the direction of the flow. If a composition has a next to it instead of an arrow, then the composition either does not have any compositions flowing into it or does not flow into any compositions.

Upstream compositions in the Composition Mini-Flowchart are sorted from top to bottom either alphabetically or by layer order. To switch between these sorting orders, press the S key when the Composition Mini-Flowchart is open. When sorting by layer order, a composition used multiple times is sorted according to its topmost instance in the stacking order. Downstream compositions are always sorted alphabetically.

To navigate among and select compositions in the Composition Mini-Flowchart, use the arrow keys or select the arrow or buttons on either side of a composition. To activate the selected composition, use the spacebar or Enter (Windows) or Return (macOS). To close the Composition Mini-Flowchart without taking any action, use Esc, Shift, or select outside the Composition Mini-Flowchart.

Pre-render a nested composition

A complex nested composition can take a long time to render, either for previews or for final output. If you have a nested composition that you don't expect to work on further, you can save time during each rendering operation by pre-rendering the nested composition into a movie and replacing the composition with the rendered movie. You can still modify the original nested composition because it remains in the Project panel. If you make a significant change to the original nested composition, render it again.

Pre-rendering a nested composition is especially beneficial when you use it multiple times in a project.

Bemærk:

Apply your final output settings when you pre-render the nested composition.

  1. Select the composition in the Project or Composition panel.

  2. Select Composition > Pre-render.

    The Pre-render command adds the composition to the render queue and sets the Import & Replace Usage post-render action to replace the composition with the rendered movie.

    The Output Module option is open, and the Post-Render Action is currently set to Import & Replace Usage.
    Automatically import the rendered file back into your project and replace the original composition or footage.

  3. In the Render Queue panel, adjust settings as necessary, and select the Render button to render the composition.

Bemærk:

An alternative to replacing the composition with the movie is to use the rendered movie as a proxy for the nested composition.

Render order and collapsing transformations

A composition consists of layers stacked on top of one another in the Timeline panel. When the composition is rendered—either for previewing or for final output—the bottom layer is rendered first. Within each raster (non-vector) layer, elements are applied in the following order: masks, effects, transformations, and layer styles. For continuously rasterized vector layers, the default rendering order is masks, followed by transformations and effects.

Transformations are changes to those properties grouped under the Transform category in the Timeline panel, including Anchor Point, Position, Scale, Rotation, and Opacity. What you see in the Layer panel is the result of the rendering before transformations are performed.

Bemærk:

For additional control over when transformations are performed, you can apply the Transform effect and reorder it with respect to other effects.

In a group of effects or masks, items are processed from top to bottom. For example, if you apply the Circle effect and then apply the Magnify effect, the circle is magnified. However, if you drag the Magnify effect above (before) the Circle effect in the Effect Controls or Timeline panel, the circle is drawn after the magnification and isn’t magnified.

After a layer has been rendered, rendering begins for the next layer. The rendered layer below may be used as input to the rendering of the layer above—for example, for determining the result of a blending mode.

If a composition contains other compositions nested within it, the nested composition is rendered before other layers in the containing composition.

Bemærk:

Some effects ignore masks on the layer to which they’re applied. To have such an effect operate on a masked layer, pre-compose the layer with the mask applied, and then apply the effect to the pre-composed layer.

Collapsing transformations

If the Collapse Transformations switch   is selected for a nested composition, then the transformations for the nested composition are not performed until after the masks and effects for the containing composition are rendered. This render order allows the transformations for the nested composition and the containing composition to be combined—or collapsed—and performed together. The same is true for vector layers that are not continuously rasterized.

Bemærk:

Instead of a Collapse Transformations switch, vector layers have a Continuously Rasterize switch in the same location. Vector layers include shape layers, text layers, and layers with vector graphic files as the source footage. Text layers and shape layers are always continuously rasterized.

Collapsing transformations can, for example, preserve resolution when a layer is scaled down by half in a nested composition and the nested composition is scaled up by a factor of two in the containing composition. In this case, rather than performing both transformations and losing image data, one transformation can be performed—doing nothing because the individual transformations cancel each other.

If transformations are not collapsed, a nested composition containing 3D layers is rendered as a 2D image of the 3D arrangement using the default composition camera. This rendering prevents the nested composition from intersecting with 3D layers, casting shadows on 3D layers, and receiving shadows from 3D layers in the containing composition. The nested composition is also not controlled by the cameras and lights of the containing composition.

If transformations are collapsed, the 3D properties of the layers in the nested composition are exposed to the containing composition. Thus, the nested composition can intersect with 3D layers, cast shadows on 3D layers, and receive shadows from 3D layers in the containing composition. The camera and lights can also control the composition's nested composition.

Essentially, collapsing transformations for a nested composition tells After Effects not to flatten and crop the layers in the composition. Because an adjustment layer operates on the composite of all layers beneath it within the same composition, an adjustment layer within a nested composition with collapsed transformations will force the flattening and cropping that collapsing transformations would usually prevent.

When a closed mask (with mask mode other than None), a layer style, or an effect is applied to a nested composition with collapsed transformations, the layers in the nested composition are first rendered on their own, then masks and effects are applied, and then the result is composited into the main composition. This rendering order means that the blending modes of the nested layers are not applied to any underlying layers in the main composition and that 3D layers above and below the collapsed layer cannot intersect or cast shadows on each other.

 Adobe

Få hjælp hurtigere og nemmere

Ny bruger?