Using the Flood Fill Tool


You can use the Flood Fill tool (the fifth icon from the bottom of the Tool palette; it looks like a tilted paint can) to fill areas of an image with either a color , gradient, pattern, or texture.

Filling an Area with a Solid Color

To fill an area with a solid color, simply set the foreground or background color to the color you want to use and click within the area you want to fill. Clicking with the left mouse button fills the area with the foreground color, and clicking with the right mouse button fills the area with the background color.

Several factors determine how the Flood Fill tool fills an area. If you've made a selection and you click within the selected area, the Flood Fill tool fills that area. If you've made a selection and you click outside the selection, even if you've chosen to hide the selection marquee, the Flood Fill tool has no effect.

You can also click in an area that already contains a certain color. The Flood Fill tool will then fill the area that contains that color. It may also fill surrounding areas, depending on the settings that you've chosen. Changing the Tolerance option, for example, determines how much of an area is filled. Higher Tolerance allows more of an area to be filled, whereas a lower Tolerance setting constrains the fill to areas that are similar in color or exactly the same color as where you initially click. You can change the Tolerance setting in the Tool Options window under the Flood Fill Options (first) tab.

Match Mode also affects how an area is filled. Selecting RGB compares neighboring pixels' RGB values, selecting Hue compares neighboring pixels' hues, selecting Brightness compares neighboring pixels' brightness values, and selecting None fills the entire area, regardless of any settings. You can change the Match Mode setting in the Tool Options window under the Flood Fill Options (first) tab. Once a comparison has been made according to Match Mode, a pixel will be filled according to the Tolerance setting.

You can also choose the Flood Fill tool's Opacity. A higher value makes the fill more opaque , and a lower value makes the fill more transparent.

Finally, you can set the patterns and textures options for each Fill style by clicking the Style or Texture icons in the Color palette. Each Fill style has different options associated with it. For example, you can set the direction of a Linear Gradient fill.

Filling with a Gradient

In addition to filling an area with a solid color, you can fill it with a gradient. A gradient is a blend from one color to another or several colors blended together, as in a multicolored gradient, which I will discuss in the next section.

Figure 38.10 shows the gradient styles that are available in Paint Shop Pro.

Figure 38.10. Paint Shop Pro has several gradient fill styles.

graphics/38fig10.gif

You can set the angle for the Linear gradient, and you can set the horizontal and vertical starting points for the Rectangular, Sunburst, and Radial gradients. To access these options, click and hold the mouse over the Style icon in the Color palette. When the flyout menu appears, choose the gradient icon. Release the mouse button and click the icon again to open the Gradient dialog box. The next section will explain how to use the settings in the Gradient dialog box and how to create your own multicolored gradients.

Creating and Editing Multicolored Gradients

Starting with version 6, and continuing with version 7, Paint Shop Pro enables you to edit, create, save, and load multicolored gradients. This is a very powerful tool that can give you amazing effects with a couple of mouse clicks.

The button bar in Figure 38.11 was created using the built-in Metallic 2 gradient, which is a grayscale gradient that uses various shades of gray and white to achieve a metallic effect.

Figure 38.11. A metallic button bar created using a multicolored Gradient fill.

graphics/38fig11.gif

To create the button bar, I filled a rectangular selection with the gradient set to Linear at an angle of 0 degrees. I then filled three more selections with the same gradient at an angle of 180 degrees. Finally, I added some shadows, highlights (done using black and white lines drawn with the Draw tool), and the text. All of these techniques will be explored throughout the remainder of the book. The following steps illustrate how to create an image like the one shown in Figure 38.11:

  1. Select the Flood Fill tool.

  2. Set Fill Style to gradient by clicking and holding the mouse over the Foreground Style icon in the Color palette.

  3. Click the Foreground Style icon to bring up the Gradient window (see Figure 38.12).

    Figure 38.12. The Gradient window in the Tool Options window.

    graphics/38fig12.gif

  4. Choose one of the gradients that shipped with Paint Shop Pro 6 by clicking the downward- facing arrow to the right of the Gradient space to activate the drop-down menu.

If you'd like to create your own gradient, follow these steps:

  1. From the Gradient Editor dialog box, you can create new gradients, rename or copy existing ones, and import/export gradients that you create (see Figure 38.13). You can access the Gradient Editor dialog box by clicking the Edit button on the Gradient dialog box (refer to Figure 38.12).

    Figure 38.13. The Gradient dialog box.

    graphics/38fig13.gif

    In the Types window, you'll notice a list of existing gradients. These are the gradient styles that shipped with Paint Shop Pro. Any gradients that you create or import will also be in this list.

    Near the middle of the dialog box you'll see a representation of the current gradient. This area is where you'll edit existing gradients or create your own.

  2. Click the New button.

  3. In the New Gradient window, enter a name for your gradient. I entered "MyGradient". The editing area will fill with one color, and there will be only two sliders, one at each end.

  4. Click the leftmost slider and click the color swatch to the left of the filled area to bring up the Color dialog box (see Figure 38.14its small arrow will turn black).

    Figure 38.14. Select the leftmost slider to change one of the colors in your new gradient.

    graphics/38fig14.gif

  5. Select a light blue color.

  6. Click the rightmost slider and then click the small color swatch again to bring up the Color dialog box.

  7. Select a medium brown.

  8. Click between the two sliders at the bottom of the filled area (see the marked area in Figure 38.15) and a new slider will appear.

    Figure 38.15. Click to add a new slider and another color in your gradient.

    graphics/38fig15.gif

  9. Click the color swatch and, this time, choose white for the color.

    You've just created a multicolored gradient in the pattern that many artists use for chrome.

    Here are some tips you can use to manipulate the appearance of your custom gradients:

    • You can move the sliders around and add more, changing the color of each as you go. Also, you can move the small diamond slider at the top of the fill area to change the way that colors interact with each other in your gradient.

    • To remove any of the sliders you added, simply click and drag them off the dialog box. Doing so will cause them to disappear.

    • You can change the transparency of your gradient, as well. This is accomplished using the fill area at the bottom of the Gradient dialog box.

      The principles are the same as when you add sliders and colors to a gradient, except that you don't choose a color. Instead, you can set the amount of transparency at any point in the gradient.

      The sliders will change shades from white to gray and finally to black as you make an area more transparent.

    • Take a look at some of the included gradients to see how they were created.

    I encourage you to play with the various settings to see what cool gradients you can create.

  10. When you're done creating your new gradient, click OK. The new gradient will be added to the list and ready for you to use.

    To share your gradient with others, click Export. Doing so will bring up the Export dialog box, which will enable you to name and save the file. This file can then be sent to others for them to use in their own artwork.

    If someone sends you a gradient file, you can add it to your collection by opening the Gradient dialog box and clicking the Import button.

As you'll soon discover, multicolored gradients are a very powerful addition to Paint Shop Pro's collection of tools.

Filling with a Pattern

Along with solid colors and gradients, you can also use the Flood Fill tool to fill an area with a pattern. To set the pattern, select the Flood Fill tool. In the Color palette, click and hold the mouse over the Foreground Style icon, release the mouse button, and then click the Foreground Style icon again to open the Pattern dialog box. Click the pattern swatch to bring up the menu of patterns (see Figure 38.16).

Figure 38.16. The Pattern dialog box.

graphics/38fig16.jpg

You can select any open image from the Pattern Source pull-down menu, as well as any built-in patterns. If some part of the current image is selected when you choose the pull-down menu, the selected area will be chosen as the pattern.

This option enables you to quickly fill an area or an entire image with a predefined pattern. If the area you're filling is larger than the pattern you've selected, the pattern will tile over the selected area.

graphics/lightbulb_icon.gif

Because the pattern fill repeats in the same manner as a Web page background, you can get a good idea of how your tiles will look. Simply create a new image that's larger than the pattern and use the Flood Fill tool to fill the image with the pattern.



Sams Teach Yourself Internet and Web Basics All in One
Sams Teach Yourself Internet and Web Basics All in One
ISBN: 0672325330
EAN: 2147483647
Year: 2003
Pages: 350
Authors: Ned Snell

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net