Home > Articles

  • Print
  • + Share This
This chapter is from the book

This chapter is from the book

Importing Bitmap Graphics

Even though Flash is a vector-based application, you can still import and work with bitmap graphics. Once a graphic is inside Flash, it becomes an element that is editable. You can animate the bitmap, skew it, scale it, distort it, break it apart, and even convert it into vectors. It's very common in development to combine artwork created in Flash with other vector programs, such as Illustrator or FreeHand, but also with bitmap applications, such as Photoshop or Fireworks. The process of importing a bitmap on a Mac looks a bit different than it does on a Windows machine, so be sure to take a good look at the following figures so you can see the differences.

Importing a Bitmap Graphic

Here are the steps to follow to import a bitmap graphic:

  1. Choose File, Import to open the Import dialog box.

  2. Download the file from this book's companion Web site and in the Chapter 3 section find the file gato.jpg.

  3. On Mac OS 9, click the Add button and then the Import button. The advantage of this dialog box is that if you have more than one item to import, you choose the different files and import them all in under one command.

  4. On Windows and Mac OS X, highlight the file and click the Open button.

The bitmap will now show up on the stage. At this point, you can manipulate the graphic in any way. There are a few different things we can do with this graphic. In the next excise, we're going to take steps to use this bitmap as a fill color, and we're also going to select portions of the image and delete them. To select these different portions, we're going to use the Lasso tool.

The Lasso Tool

The Lasso tool is a selection tool, and it makes the most sense to use this tool with bitmaps. Use the Lasso tool just as you would any drawing tool. To make a clean, precise selection, try to close the path the lasso makes. Otherwise, the results can be less than predictable. The Lasso tool has some options at the bottom of the Tools panel. The first is the Magic Wand tool, shown in Figure 3.32. The Magic Wand tool selects an area or value of pixels based on its set tolerance. You can set the tolerance by clicking the button to the right of the Magic Wand tool. The higher the tolerance, the more values the selection will consider to be the same.

Figure 3.32 The Magic Wand settings.

The Smoothing option is for determining how smooth the selected edge should become. Here are the choices:

  • Smooth. Rounds the selection edges.

  • Pixels. The selection is wrapped around the rectangular edge of similar color pixels.

  • Rough. The selection becomes even more angular than with Pixels.

  • Normal. Creates a selection that is a bit softer than Pixels but not as soft as Smooth.

The last option is the Polygon Lasso tool. Use this tool for angular or geometric type shapes. See Figure 3.33 for the Lasso's options.

Figure 3.33 The Lasso tool's options.

  • + Share This
  • 🔖 Save To Your Account