6.2. Editing Bitmaps

Problem

You want to edit an imported bitmap, including erasing and painting over bitmaps or using bitmaps as fills.

Solution

Use Modify → Break Apart.

Discussion

When you drag an imported bitmap instance into a Flash movie, it is locked for editing. If you select it with the Selection tool, it has a gray bounding box around it, and all you can do is reposition or scale the bitmap.

You can edit a bitmap, however. To do so, you must break it apart using Modify → Break Apart. Breaking apart a bitmap makes the pixels accessible for editing. More specifically, once it is broken apart, you can erase portions of a bitmap, or paint over them using a tool, such as the Brush tool.

Broken-apart bitmap pixels behave like the pixels of a vector shape’s fill. If layered over another vector shape in the same layer, bitmap pixels remove any portion of a fill beneath them; before a bitmap is broken apart, it obscures, but does not remove, any vector shape fills beneath it in the same layer.

Breaking apart a bitmap graphic has no implications with regard to file size. That is, all the following movies using the same bitmap, image.jpg, would yield .swf files with the same file size:

  • One instance of image.jpg, not broken apart

  • Ten instances of image.jpg, not broken apart

  • Ten instances of image.jpg, broken apart

An imported bitmap is stored in the library, and if it is used once on the stage, in any way, it must be downloaded in its entirety once. This rule applies even to bitmaps that are ...

Get Flash 8 Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.