Importing and Working with Bitmaps
Even though vector graphics are usually smaller in file size, oftentimes you will still need bitmap graphics. After these bitmaps are in Flash, they will become a symbol in the Library (more on the Library and Symbols in Chapter 5). This means that you can manipulate them much the same as a group or other symbol, such as sizing and rotating.
To import a bitmap into Flash, follow these steps:
Select File, Import, Import to Stage (Ctrl+R).
Select the bitmap you want to bring in and click Open.
After the bitmap is on the stage, you can take several courses of action.
Creating a Bitmap Fill
A bitmap fill is similar to a gradient. When one is selected, you can use the Paint Bucket tool to fill in shapes with it.
Here are the steps to create a bitmap fill after the bitmap has been imported:
With the bitmap selected, choose Modify, Break Apart (Ctrl+B).
With the Eyedropper tool, select the newly broken-apart bitmap.
Now select the Rectangle tool and draw a rectangle on the stage. You will see it is filled with the bitmap.
Modify, Bitmap, Trace Bitmap
Although we converted the bitmap to a fill, we really could not grab sections of it as pieces. This is because the entire bitmap is currently seen as a single fill. To fix this, you can trace bitmap by going to Modify, Bitmap, Trace Bitmap. This will produce a pop-up, such as Figure 3.25, with the following options:
Color Threshold—This option looks at the color of adjacent pixels. If the color value is less than this option, the pixels will be combined into one color. The value range is between 1 and 500.
Minimum Area—This option controls how many pixels to evaluate at a time. The value range is between 1 and 1,000.
Curve Fit—This option controls the smoothness of the vector edges being created.
Corner Threshold—This option controls the amount of corners that are preserved in the process.
By setting smaller threshold Minimum area settings, you will create a higher resolution image, but the file size will increase as well. Setting many corners will also help in creating a higher resolution image. For an example of what a bitmap next to a traced bitmap looks like, see Figure 3.26.
Figure 3.25 The Trace Bitmap pop-up window.
Figure 3.26 Before and after shot of a bitmap tracing. Notice the stylized look on the right.
Modify, Bitmap, Swap Bitmap
The Swap Bitmap feature allows you to swap out bitmaps on the stage with any other bitmap in the library. After importing another bitmap and deleting it from the stage, select the bitmap still on the stage and choose Modify, Bitmap, Swap Bitmap, which will allow you to grab another bitmap from the library and replace the selected one on the stage (see Figure 3.27).
Figure 3.27 The Swap Bitmap pop-up.