• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL

Chapter 4. Creating Web Images > Creating Fake Transparency

Creating Fake Transparency

Fake transparency means making the image's background the same color as the background of your page so that the image blends in as if the background were transparent.

To fake transparency by making the background a solid color:

Open the image in Photoshop, or another image editing program.

Use the lasso and other selection tools to select everything except the background (Figure 4.44).

Figure 4.44. Select the image itself, using the lasso or other selection tools.

Choose Select > Inverse to select only the background (Figure 4.45).

Figure 4.45. Choose Select > Inverse to select everything but the image, that is, to select the background.

Click the Background color control box to set it to the desired color.

Press Delete to change the color of the selected area (the background) to the current background color (Figure 4.46).

Figure 4.46. Once you've inverted the selection, click the Background color control, choose the desired background color, and then press the Delete key to change the background to one solid color, in this case, white.

Save the image.


It's probably a good idea to choose a browser safe color for the background. Otherwise, it will dither on 256 color monitors. For more details, consult Using (Mostly) Browser Safe Colors on page 66.


You can also use this method to simulate transparency in JPEG images.


This is also a good way to prepare images for programs that only allow you to make one color transparent.


Of course, if your visitors override the background color, the effect is lost.

  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint