decorative banner

Shape transforms versus object transforms


    Shape transforms (also called pretransforms) affect the artwork itself, whereas object transforms (also called post-transforms) are applied just to particular instances of the artwork. This has implications for how LiveMotion optimizes SWF files by storing single objects and reusing them in the SWF, as well as for how it stores each object. For example, to minimize file size in an animation, avoid making additional shape transforms to an object, since this exports as an additional object rather than a change to the object.

    When you first import a piece of artwork and scale it, you're applying a shape transform; that is, you're changing the native size of that artwork and, therefore (if it exports as a bitmap), the number of pixels it contains. However, when you set a stopwatch for the scale attribute in an animation, you begin to apply object transforms; that is, you're just scaling that particular copy of the artwork. It's a good idea, therefore, to find the point at which your artwork appears the largest, and then use the Make Actual Size command (see Optimizing the resolution and file size of bitmap objects). This makes the native artwork only as big as it needs to be in that situation, and at other points it will be scaled down and the effects of the scaling won't be so visible. The actual size determines the size required in the SWF.

    As another example, suppose you used the 3D palette to apply a 5-pixel bevel to an object. If you shape transformed the object (such as by enlarging it), the bevel remains 5 pixels wide because you're changing the source artwork. But if you applied an object transform to the object (such as enlarging it over several seconds in an animation), the bevel increases in size proportionally with the rest of the object because you're transforming that copy of the object, not the source object. However, you could redefine its native size with the Make Actual Size command.

    Understanding shape and object transforms is essential when you want to duplicate animations without greatly increasing the size of your exported SWF file. You can reduce its size by wrapping animated elements in a movie clip group, then applying transformations at the group level. Be aware that if you apply shape transforms at the group level to a duplicate movie clip group, that group exports separately from the original (the artwork it contains is stored once, but the animations applied to it are exported twice). Instead, you can make an alias of the movie clip group, and then apply an object transform such as Scale to it later. This exports a singe movie clip group and a reference to it for the alias.

    For more information on shape transforms and object transforms, see Setting transform options.