Precomposing is often seen as a poorly thought-out solution to order problems. It is a imporant task in creating a 3D configurator. We disagree with this statement. Rather, it is an effective way to solve problems and optimize projects in After Effects.
Precomposing is an action to select a set of layers in a composition and assign them to a new subcomponent.
Typically, pre-composing is done by selecting the layers of a composition that can and should be grouped and selecting Pre-composing from the Layers menu (you can also use Ctrl+Shift+C/Cmd+Shift+C.) You have two options: Leave attributes where they are or move them to the new composition. One of the options is grayed out when multiple layers are selected for reasons explained in the small print of the dialog box. If you’re wondering what constitutes an attribute that should be precomposed, it’s pretty much everything you’ve edited on the layer: an effect, a mask, brush strokes or even layer entry and exit points.
Why pre-composing is important.
Depending on who you ask, pre-composing is either the solution to most problems in After Effects, or one of the tedious tasks you have to do in the program.
So why not just work in a big composition. The benefits seem to be many and varied. All the properties and keyframes you’d want stay right in front of them, you never have to dig into a sub-component to set a level, and there’s no difficulty tracking the order of the composition.
The following reasons speak for preparing for pre-composing:
- Keep two layers in sync. If you ever make the same settings on two different layers in the same composition, it may be a signal that the layers now contain one element and you need to precompose.
- As a solution for renderorder problems. Sometimes it is simply not possible to perform a render action without pre-composing before another. For example, if you want to mask a layer after applying effects to it, you need to apply the effects to a pre-composition and then mask it.
- To keep the master composition in order, it should be self-explanatory. A master composition with six well-organized elements is much more useful than one with dozens of different elements.
- Reusing an element. If you have used a set of layers to create an element that you think could be reused or that your customer wants to change globally in several places, it makes sense to nest those layers as a composition. In this way, you can reuse the element by simply dragging it into a new timeline.
- Because an element or set of layers is essentially executed. This, if you didn’t know, is a big goal. If you can stop part of your recording, especially if it’s a render-intensive part, pre-composing that part gives you the option to pre-render it.
If you are already familiar with the idea of pre-composing, the last point is probably the most important you should consider. As you’ll see later, as a designer you’ll benefit enormously from a change of mentality when you move from a designer who wants to leave everything open to a designer who understands the benefits of finishing an object, if only for the moment.
Comments.
Some other compositing applications, especially Discreet’s Inferno, seem to have overshadowed the importance in terms of perceived speed and performance. Inferno is powerful and runs on custom hardware, but sometimes people don’t realize that it’s not really real time, even Inferno has to render. Inferno designers will hide this fact by rendering in the background or requiring elements to be rendered in advance.
Options and Gotchas.
Precomposing a single layer with the option “leave all attributes initial” is relatively easy. Most of the time, however, you will precompose multiple layers using the “Move all attributes” option, a route that can be dangerous if you are not careful.
Typical errors that occur with this process include
- Changes the duration and offset of the layers as they appear in the Timeline.
- It is not intended that some attributes need to be pre-compiled, but not all.
- It is difficult to undo the pre-composing of multiple edits.
- The behavior of precomposten blend modes and 3D transformations changes depending on whether the compression transformations are on or off.
- Confusion about recursion: In what cases do motion blur, frame blending, and compressed transformation switches affect nested subcomponents?
Take a closer look at each of these situations, as well as some useful strategies for working with them.
Confusion in Layer Duration.
Below we demonstrate the Layer Duration problem. By pre-composing a set of layers that do not have the same duration as the source composition, they are brought into a new composition whose duration corresponds to that of the source composition, but not that of the layers. The result is that the pre-composing layer contains empty frames at the top or bottom of the shot.
If you precompose the offset of layers with the Move All Attributes option, you may not notice that the offset is applied to the pre-composition while the master composition shows a layer that seems to start at frame 0.
You can crop the layers to match the original edits, but there is a better option. This works best when you synchronize the “Time” option of all associated elements and have it enabled in the General Settings, since it is now enabled by default.
- In the precompiler, move the time needle to the first image that contains all the data.
- Select all layers and move them while holding down the Shift key so that the first frame appears as the first frame of the composition.
- If the time needle is still at the beginning of the layers, return to the main composition.
- Press the [ button to reposition the first image of the composition.
If you want, you can also trim the back by going to the subcomposition, placing the time needle on the last image that contains all the data, then returning to the master composition and Alt+]. (Option+]) to trim the layer.
Tip.
The disc of the book contains preCompToLayerDur.jsx. According to its complete description on the following website, “this script will precomposen one or more selected layers with the option “move all attributes” and the resulting new composition in point is the earliest in point of the selected layers and the composition out point of the selected layers”. Load it via File > Scripts > Run Script File.
The missing option.
Of course, there are situations where the two options in the Precompose dialog box do not cover everything you need. What if you want to move some, but not all, attributes to a new composition? Unfortunately, there is no automated solution for such a situation with all its variables.
The best way to handle this is probably to select the Move All Attributes option, select the Open New Composition check box, and then remove and paste all attributes that belong to the master composition. If you precompose only one layer, you can do it the other way round: Leave the attributes in the master composition and then paste the desired attributes out and back into the subcomposition.
Close-up: Undoing a pre-composition.
If you change a pre-composition and then immediately change your mind, you can of course undo the action. However, a problem arises when you continue with your project and decide that the pre-composition was a bad idea. In this case, the only way is to cut the layers from the pre-composition and carefully reinsert them into the master composition, making sure that the order of the layers is maintained and that the basic properties such as transforms remain correct.
Data transmission.
Finally, how do you know whether 3D position data or blend modes of a layer are preserved in the sub-composition and appear correctly in the master composition? Or, if you turn on Motion Blur or Frame Blending on the Subcomposition layer in the Master Composition, do you know that the elements you animated in the Subcomposition will apply these settings? To handle these situations correctly, you should be aware of a few settings.
For Motion Blur and Frame Blending, the key is the “Switches Affects Nested Comps” checkbox in the General Settings. If this check box is checked (as it is by default), turning on these functions in the Master Composition will also turn them on in all affected subcompencies. Unless you specify otherwise in the Render Settings, this situation will be treated the same way when rendering.
When running through 3D position data and blending modes, the Collapse Transformations toggle must be activated for each composition layer. If you activate this option, these properties behave as if the precompost layers were still in the master component. If you deactivate this option, you cannot interact with the master component.
The time component.
After Effects is less rigid than many other digital video applications when it comes to working with time. You are not forced to have all compositions in a given project use the same frame rate, and changing the frame rate of an existing composition is done very elegantly, with all keyframes maintaining their positions relative to the total time.
Close-up: Extending boundaries.
Sometimes it is not desirable to activate Collapse Transformations/Continously Rasterize, e.g. if you set up 3D layers in a subcomposition and do not want them to be influenced by a camera in the master composition. This can lead to an error where effects that extend the pixel area occupied by this layer (e.g. blur and distortion) are cut off at the edges of the nested composition. By adding the Grow Bounds effect before the effect that requires more pixel area, you can avoid this problem.
The semi-oval layer has been precomposed and a radial blur is cut off at the edges of the layers. The pre-composition would restore the other half of the oval, but Grow Bounds only increases the boundaries of the layer so that the blur is not cut off.
This doesn’t mean you can be messy, but have options. Designers who are familiar with other applications often forget to pay attention to the frame rate settings when they
- import an image sequence.
- Create a new composition from scratch.
- Embed a composition at one frame rate into another at a different frame rate.
In the third case, After Effects does its best by default to stretch or compress the frame rate of the embedded composition to match that of the master composition. Sometimes, however, it’s not what you want, i.e. when you need to check “Options” on the Advanced tab of the Composition Settings dialog box.
Close-up: Collapsing new mixes.
One limitation of turning on Collapse Transformations is that you are then prevented from adding a blend mode to the compressed layer. The blend mode menu shows only one icon.
The workaround is to apply an effect to the layer that does nothing or is even disabled. This forces After Effects to render the compressed layer (which makes it what Adobe developers call a bracketed composition), which also has the advantage of making blend modes available.
The disadvantage is that 3D layers are no longer run through. However, this workaround is helpful if you want to precompose for scaling.
The Advanced tab.
The Advanced tab of the Composition Settings dialog contains a variety of extras that can be useful. For example, Anchor Grid specifies how a composition is trimmed when you adjust its pixel dimensions down on the Base tab. Shutter angle and phase affect motion blur. As far as the rendering plugin is concerned, you will almost certainly leave it at the default Advanced 3D setting.
Rarely is there an opportunity if you weren’t using the default Advanced 3D rendering plug-in. The “plug-in” idea was developed to give third parties the opportunity to write their own 3D renderers for After Effects, but no developer outside of Adobe offered one for this writing.
There are also two Preserve checkboxes. Preserve Frame Rate retains the frame rate of the current composition, regardless of the frame rate settings, wherever you want to send it to another composition at a different frame rate or to the Render Queue with different frame rate settings. So if you have created a simple cycle animation with keyframes that displays 4 frames per second and then place that composition into a 24 FPS composition, After Effects will not attempt to stretch that composition over the higher frame rate, but will keep it at 4 fps.
Remarks.
New in 7.0 is a third rendering plugin option: OpenGL Hardware. This option is grayed out until you enable OpenGL in Settings > Preview. Like many other things, OpenGL is a question of taste. It will probably provide a stylized look for video games that may not render similarly on two different engines.
Just like the “Preserve Resolution when Nested” option: If an element in a pre-composition is reduced in size and the composition in the master composition is increased in size, After Effects should treat these two opposite scales as one operation and “chain” the transformation operations so that there is no data loss due to quantization. However, if you want the data in the subcomposition to look as if it were upscaled from a lower resolution element, switch to Preserve Resolution when Nested and live with the big pixel look.
Thank you for visiting.
Leave A Comment