A sprite sheet is a bitmap image file that contains several smaller graphics in a tiled grid arrangement. By compiling several graphics into a single file, you enable Animate and other applications to use the graphics while only needing to load a single file. This loading efficiency can be very helpful in situations such as game development where performance is especially important.
You can create a sprite sheet from a selection of any combination of movie clips, button symbols, graphic symbols, or bitmaps. You can select items in the Library panel or on the Stage, but not both. Each bitmap and each frame of the selected symbols will appear as a separate graphic in the sprite sheet. If you export from the Stage, any transforms (scaling, skewing, etc.) you have applied to the symbol instance are preserved in the image output.
To create a sprite sheet:
- Select one or more symbols in the Library or symbol instances on the Stage. The selection can also contain bitmaps.
- Right-click the selection and choose Generate Sprite Sheet.
- In the Generate Sprite Sheet dialog box, select options and then click Export.
The following export options are available:
The total size in pixels of the sprite sheet. The default setting is Autosize, which sizes the sheet to fit all the sprites you include.
The file format of the exported sprite sheet. PNG 8 bit and PNG 32-bit each support using a transparent background (alpha channel). PNG 24 bit and JPG do not support transparent backgrounds. Generally, the visual difference between PNG 8 bit and PNG 32 bit is small. PNG 32 bit files will be 4 times as large as 8-bit PNG bit files.
The technique used for packing the images into the sprite sheet. There are two options:
- Basic (default)
The internal format used for the image data. Choose the format that best suits your intended workflow for the sprite sheet after export. The default is the Starling format.
This option saves space on the sprite sheet by trimming unused pixels from each symbol frame added to the sheet.
Selecting this option prevents duplicate frames within the selected symbols from being duplicated in the resulting sprite sheet.