Creating sprite sheets

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.

Sprite Sheet - CS6 - Flash Professional
A sprite sheet containing the sprites in a frame-by-frame animation.

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:

  1. Select one or more symbols in the Library or symbol instances on the Stage. The selection can also contain bitmaps.
  2. Right-click the selection and choose Generate Sprite Sheet.
  3. In the Generate Sprite Sheet dialog box, select options and then click Export.

The following export options are available:

Image Dimensions

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.

Image Format

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.

Border Padding

Padding around the edges of the sprite sheet, in pixels

Shape Padding

Padding between each image within the sprite sheet, in pixels.

Algorithm

The technique used for packing the images into the sprite sheet. There are two options:

  • Basic (default)
  • MaxRects

Data Format

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.

Rotate

Rotates the sprites 90 degrees. This option is only available for some data formats.

Trim

This option saves space on the sprite sheet by trimming unused pixels from each symbol frame added to the sheet.

Stack Frames

Selecting this option prevents duplicate frames within the selected symbols from being duplicated in the resulting sprite sheet.

Exporting animation for mobile apps

Exporting animation for mobile apps
Train Simple - Matthew Pizzi

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License  Twitter™ and Facebook posts are not covered under the terms of Creative Commons.

Legal Notices   |   Online Privacy Policy