2. Basic Editing

This chapter introduces you to the general tools and techniques you use in GIMP to create and edit a variety of graphics, including basic drawings, photographs, and specialized images used for the Web.

In a sense, almost everything you do with GIMP comes under the heading of editing; however, that can involve a variety of tools and methods that take time to learn and become proficient in using. Because you are just beginning to learn GIMP, you have to start somewhere. You’ve already learned some of the more commonly used tools, and in this chapter, you’ll learn a lot more.

By the time you reach the end of this chapter, you will have learned how to crop a photograph or other image, by using Guides, the Move tool and the Crop tool. You will also know how to reorient an image using the flip and rotate tools to change the direction and angle of the image. You’ll know how to remove red eye from a photo using the Red Eye Removal filter and how to change the color mode of an image to reduce its size. You’ll also know how to make the background of an image transparent so you can copy just the subject of the image into a new background. You learn how to make basic brightness and contrast adjustments in an image and how to soften images using both the basic blur and Gaussian blur filters.

To learn editing, you’ll need images to edit. You may have a store of drawings and photos already available to work with on your computer, but if you don’t they’re readily available on the Web. I don’t recommend that you randomly download graphics from the Internet, because much of that material belongs to someone and is protected by copyright.

Following are a couple of links where you can download free photographs:

www.freefoto.com/index.jsp

www.freedigitalphotos.net/

If these sites don’t suit you, open your favorite search engine and use a search string such as “free photos” to see what you come up with on your own.

Before you continue reading, take some time to download a number of photographs and other images. They can be on any topic, but locate and download at least one head-shot photo of a person, because one of the editing tasks you’ll be performing is removing the dreaded red eye.

Editing in GIMP

Some of the more common editing tasks are cropping, scaling (which you’ve already practiced), adjusting contrast and brightness, and rotating an image. This chapter offers you the opportunity to learn about these basic editing tasks and more.

Show Me: Media 2.1—Cropping a Photo

You can watch a free video about cropping a photo when you log on to my.safaribooksonline.com/9780132174602/media.

image LET ME TRY IT

Cropping a Photograph

You’ve probably taken digital photos at a wedding or on a scenic vacation and thought they were well composed in the viewfinder, but when you looked at them later, you found a few photos contained some extraneous scenery you’d just as soon do without. That’s what cropping is for. For the following task, navigate to your store of photos, and select one you would like to crop. If you don’t have GIMP open, take a moment and open it now.

  1. Right-click the image and select Edit with GIMP to open it.
  2. On the Image window toolbar, click Image, Guides, New Guide.
  3. When the New Guide dialog opens, make sure the Direction is set for Horizontal, set the Position to 10, click OK.
  4. In the Main Toolbox, select the Move tool as shown in Figure 2.1, and then use it to drag the new guide to the desired position.

    Figure 2.1. The Move tool is located on the Main Toolbox.

    image

  5. Repeat the process you performed to create a new guide, drag the guide to the desired position, and then click OK.
  6. Repeat the process twice more, but set the Direction to Vertical and the Position to 10 and then dragging the guides to where you want them, until you have the photo framed with the guides for the area you want to crop.
  7. Select the Crop tool in the Main Toolbox, as shown in Figure 2.2.

    Figure 2.2. The Crop tool is located on the Main Toolbox.

    image

  8. In the Image window, hover over the upper-left corner of the guides, and then click and drag to the lower-right corner.
  9. Release the mouse button and press Enter to crop the picture.
  10. In the Image window toolbar, click Image, Guides, and then Remove All Guides.
  11. Save the photo.

Strictly speaking, you didn’t need to use the guides to define the area you wanted to crop, but they are very helpful if you need to be precise in the cropping task. Otherwise, you could have just “eyeballed” the image and cropped it on-the-fly.

Reviewing the Crop Tool

Take a moment and return to the GIMP Toolbox and look at the Crop Tool tab in Toolbox Options. As you can see in Figure 2.3, just like the other tools you’ve previously examined in GIMP, the Crop Tool has a number of options you can modify to get the most out of this feature.

Figure 2.3. A variety of adjustments can be made to the Crop Tool on the Crop Tool tab in Toolbox Options.

image

Current Layer Only: Select this check box if you want the crop tool to affect only the Active Layer.

Allow Growing: Select this check box if you want to be able to crop or resize outside of the image and the canvas. A transparency is used fill in the portions you crop that are outside the image’s boundaries.

Expand from Center: Select this check box if you want where you click to begin the crop to be the center of the cropped image.

Fixed: Select this check box to control fixed dimensions during cropping using several options:

Aspect Ratio: Select this drop-down menu option to maintain the ratio between height and width during cropping. You can change the default values in the available field.

Width and Height: Select either of these separate options if you want the value to remain fixed, and then set the value in the available field.

Size: Select this option if you want both Width and Height to be fixed, and then set the values in the available field.

Portrait and Landscape: Select one of these buttons to the right of the Fixed values field to select the format for cropping.

Position: Once you made selections, when you drag the cursor across a graphic for cropping, these fields will show the position of the crop cursor in real-time. The values can also be altered manually. Use the drop-down menu to select the scale, such as px or in.

Size: These fields show the size of the crop area in real-time. The values can also be altered manually. Use the drop-down menu to select the scale such as px or in.

Highlight: Select this check box is you want the crop area to the highlighted and the area outside to be darkened (the default setting).

Guides: Use this drop-down menu to select specific guide options to appear within the crop area.

Autoshrink: If you are cropping a graphic containing a well defined object with identifiable borders in the active layer, clicking this button will cause the crop tool to try and find a border and use it to draw dimensions from in the crop.

Shrink Merged: Select this check box if you want to use the Autoshrink option on all visible layers, rather than just the active layer.

Show Me: Media 2.2—Reorienting an Image

You can watch a free video about reorienting an image when you log on to my.safaribooksonline.com/9780132174602/media.

image LET ME TRY IT

Reorienting an Image

Sometimes you’ll have an image that is correct in every way except that it’s oriented incorrectly. Perhaps you want to have a figure that is currently facing left to be facing right, or you want to orient an image 90 degrees to the left. This is easily accomplished using GIMP. In this task, you’ll both flip and rotate the selected image.

  1. With GIMP open, navigate to the image you want to reorient.
  2. Right-click the image and select Edit with GIMP to open it.
  3. On the Main Toolbar, select the Flip tool, as shown in Figure 2.4.

    Figure 2.4. The Flip tool is located on the Main Toolbox.

    image

  4. Click the image to flip it.
  5. To rotate the image, click the Rotate tool on the Main Toolbar, as shown in Figure 2.5.

    Figure 2.5. The Rotate tool is located in the Main Toolbox.

    image

  6. Click the image to open the Rotate dialog.
  7. Move the slider to the left or the right to rotate it in the desired direction and to the desired degree, as shown in Figure 2.6.

    Figure 2.6. The angle of rotation for the image is controlled by a slider bar in the Rotate dialog.

    image

  8. When the image is correctly oriented, click Rotate.
  9. Save the image.

Reviewing the Flip Tool

Go back to the Main Toolbox and select the Flip tool again. Review the options available in Toolbox Options for this feature, as shown in Figure 2.7.

Figure 2.7. The Flip tool can be modified in a number of ways on the Flip tool tab in Toolbox Options.

image

Affect—Clicking these buttons determines what portion of the drawing is affected by the flip action:

• Click the first button to affect the active layer.

• Click the second button to flip only the selection contour.

Flip Type—Select Horizontal to flip in a horizontal direction or Vertical to flip in a vertical direction.

Reviewing the Rotate Tool

Now click on the Rotate Tool in the Main Toolbox and have a look at the options available on the tab in Toolbox Options as shown in Figure 2.8.

Figure 2.8. The Rotate Tool can be modified in a number of ways on the Flip Tool tab in Toolbox Options.

image

Transform: Clicking these buttons causes the rotate action to affect the same areas that the Affect buttons did in the Flip Tool: Active Layer, Selection Contour, and Selected Path.

Direction: Select Normal (Forward) to rotate the layer in the expected manner. Select Corrective (Backward) to rotate an image layer that is askew and requires correction to make it straight.

Interpolation: Use this drop-down menu to select the method and quality of the transformation.

Clipping: After rotation, the image may be larger than the original and you can use this option to clip the modified image to the original size. Options are Adjust, Clip, Crop to result, and Crop with aspect.

Preview: Use the drop-down menu to select the method of previewing the rotated image with the options of Outline, Grid, Image, Image + Grid.

Opacity: The slider controls how opaque the paintbrush line will appear, from 100 or completely opaque to 0 or invisible.

Grid Lines: If one of the grid options is selected in Clipping, this menu lets you select either Number of grid lines or Grid line spacing. The slider below lets you adjust either the number of lines or the amount of spacing. Otherwise, the menu is inactive.

15 degrees (Ctrl): Selecting this check box will constrain the rotation to angles divisible by 15 degrees.

Show Me: Media 2.3—Drawing a Straight Line

You can watch a free video about drawing a straight line when you log on to my.safaribooksonline.com/9780132174602/media.

image LET ME TRY IT

Drawing a Straight Line

I know this sound ridiculous, but when I first started using GIMP, it took me forever to figure out how to draw an ordinary straight line. This is such a simple task in a lot of paint-like utilities, but it’s a bit more of a challenge in GIMP. I’m including this exercise because the capability to draw a straight line is almost a universal necessity when creating and modifying graphics.

  1. With GIMP open, in the Image window toolbar, click File, New.
  2. When the Create a New Image dialog appears, accept the defaults and click OK.
  3. On the Main Toolbox, click the Paintbrush tool.
  4. In the Paintbrush tab in Toolbox Options, click Brushes and select a brush size, such as Circle (05).
  5. Place the cursor anywhere in the upper-left area of the blank image, and then left-click the mouse to make a “dot” on canvas.
  6. Press and hold the Shift key and then move the mouse to the lower-right area of the canvas without clicking the mouse buttons.
  7. When you have positioned the cursor where you desire, left-click the mouse again to create the line. Then release the Shift key (see Figure 2.9).

    Figure 2.9. The finished line appears in on the white canvas.

    image

You have now created a perfectly straight line of the desired thickness. You accepted the default color of black, but you could have clicked the Color Editor tool to open it and selected a different color prior to creating the line. You also could have performed these actions using other utilities, such as the Pencil, Eraser, Airbrush, or Smudge tools.

Incidentally, you don’t have to save this drawing unless you really want to. Just close it and when given the option, click Don’t Save.

image LET ME TRY IT

Removing Red Eye from a Photo

This is a very common and very necessary task for photographers, and it doesn’t require any advanced GIMP tools. You’ll need to have access to a digital photo of a person, with red eye present in the photo.

  1. Navigate to the desired photo, right-click the image, and select Edit with GIMP to open it.
  2. On the Image window toolbar, click View, Zoom, and select a setting, such as 4:1 (400%).
  3. Use the scrollbars on the image to center the eyes of the figure in the photo.
  4. Select the Rectangle tool in the Main Toolbox.
  5. Create a rectangle closely outlining the eyes in the photo.
  6. On the Image Window toolbar, click Filters, Enhance, and then click Red Eye Removal, as shown in Figure 2.10.

    Figure 2.10. Click Red Eye Removal on the menu that appears.

    image

  7. When the Red Eye Removal dialog appears, use the Threshold slider to adjust the image until the red eye effect has been eliminated in the Preview. Then click OK.
  8. Back on the image, click anywhere outside the rectangle area to remove it.
  9. Click View and then Zoom to return the image to 100% or your desired viewing setting.

It is very important in step 5 to create a rectangle that outlines the eyes as closely as possible. The Red Eye Removal tool adjusts the threshold of all the color within the selected box. If you had not used the Rectangle tool before adjusting the Red Eye Removal tool threshold, the color values of the pixels in the entire image would have been adjusted.

Show Me: Media 2.4—Removing Red Eye from a Photo

You can watch a free video about removing red eye from a photo when you log on to my.safaribooksonline.com/9780132174602/media.

Show Me: Media 2.5—Making an Image Background Transparent

You can watch a free video about making an image background transparent when you log on to my.safaribooksonline.com/9780132174602/media.

Changing the Mode of an Image

Depending on how much you work with images, you might be asking, “What is a ‘mode’ and why would I have to change it?” You are probably aware that images can be saved in a variety of formats, including .bmp, .jpg, .gif, .png, .tiff and GIMP’s native. xcf format. Each image format has its uses, and you learned in Chapter 1 that by saving an xcf image as a jpg, you can lose information in the graphic. The mode of an image determines the color model used to display and print that image. Different color models determine the number of channels and the number and range of colors that can be in used an image, as well as the file size of an image.

Tell Me More: Media 2.6—What Is an Image Mode?

You can listen to a free audio recording describing the different image modes available in GIMP when you log on to my.safaribooksonline.com/9780132174602/media.

For documents, I often create images that must be small, either because they must load quickly for a web page, or to minimize the size of an image-laden PDF. Although RGB provides very rich, high-quality color, this mode also results in a larger-size image. Changing the mode of an image is easy and takes almost no time at all.

To change the mode of an image to Indexed, open any image you desire in GIMP. In the Image Window toolbar, click Image, Mode, and then select Indexed, as shown in Figure 2.11.

Figure 2.11. The Indexed selection appears on the menu when you click Image, Mode.

image

When the Indexed Color Conversion dialog opens, accept the default settings and click Convert. When you’re done, save your image.

The image mode has now been changed from RGB to Indexed. As you saw earlier, you can adjust a number of settings in the Indexed Color Conversion dialog. Rather than go into the details, as we have with other GIMP features, see Chapter 3, “Managing Colors,” for more information.

Tell Me More: Media 2.7—What Is a Channel

You can listen to a free audio recording about color channels when you log on to my.safaribooksonline.com/9780132174602/media.

Show Me: Media 2.8—Adjusting Brightness and Contrast

You can watch a free video about adjusting brightness and constrast when you log on my.safaribooksonline.com/9780132174602/media.

image LET ME TRY IT

Making an Image Background Transparent

At times, you may want to take the subject of one image and transfer it into the background of another image. This is a problem if the image you want to transfer is contained on a single layer. If you try to copy and paste, the background of the first image will be transferred along with the subject. It’s not too difficult though, to make an image background transparent, leaving only the subject visible.

For this exercise, you’ll need two images. The first image must contain a subject, such as a single person or object. Also, the background must be uniform, such as a single color. The second image can be any sort of image.

  1. Open both the subject image and the second image using GIMP.
  2. On the Image window toolbar of the first image, click Layer, Transparency, and then click Add Alpha Channel, as shown in Figure 2.12.

    Figure 2.12. The Add Alpha Channel selection appears in the menu when you click Layer, Transparency.

    image

  3. On the Main Toolbox, click the Fuzzy Select tool to select it, as shown in Figure 2.13.

    Figure 2.13. The Fuzzy Select tool is on the Main Toolbar.

    image

  4. Click over the background of the first image to select it.
  5. On the Image Window toolbar, click Edit and then click Clear.
  6. Click Select, None to remove the selection.
  7. Click Edit, Copy Visible.
  8. On the second image, click Edit, Paste Into.
  9. On the Main Toolbar, click the Move tool to select it.
  10. Put your cursor over the image you just pasted, and then left-click and hold.
  11. Drag the pasted image to the location where you want to place it in the background image, and then release the mouse button.
  12. Click outside the selected area of the pasted image to deselect it.
  13. Save the image.

Although the merging of the two images may not be perfect, this is a quick way to create a graphic, placing the subject from one drawing into the background of another.

Go back to the Main Toolbar and click the Fuzzy Select tool again. This tool, which is also called the Magic Wand, is primarily used to select a particular area of a layer based on the same or similar colors. This is probably the easiest of the GIMP selection tools to use.

Reviewing the Fuzzy Select Tool

Now take a look at Toolbox Options to examine the tab for this tool as displayed in Figure 2.14.

Figure 2.14. The Fuzzy Select Tool can be adjusted in a variety of ways on the tab in Toolbox Options.

image

Mode: Click on of the four boxes to control how this tool is used to make selections:

• Replace the current selection (default).

• Add to the current selection.

• Subtract from the current selection.

• Intersect with the current selection.

Antialiasing: Select this check box to cause the boundary of a selection to be rendered more smoothly.

Feather Edges: Select this check box to cause the boundary of a selection to be blurred, making it more successfully blend in to a different background.

Select Transparent Areas: Select this check box if you want the tool to select areas that are transparent.

Sample Merged: Select this check box if you want the tool to base its color selection on all visible layers rather than the active layer.

Threshold: Use the slider to set the maximum difference in colors that the tool will recognize when making selections. The default is 15.0.

Select by: Use this drop-down to choose which color component the tool will use to make the selection. Choices are Composite (default), Red, Green, Blue, Hue, Saturation and Value.

Now click on the Move Tool on the Main Toolbox and have a look at the options available on the Toolbox Options tab.

• Move: Click one of the three buttons to select what you want the tool to move: Layer, Selection, or Path.

• Tool Toggle: Choose either Pick a layer or guide or Move the active layer to determine what the Move Tool will affect.

image LET ME TRY IT

Adjusting Brightness and Contrast

One of the most common editing jobs, particularly with photographs, is adjusting brightness and contrast. You may have composed a wonderful landscape shot but the resulting image may seem too bright, dull, or shadowed. Although using this tool may seem rather simple, it can make a big difference in the presentation of the image.

For this exercise, choose a digital photograph that you believe could be improved by modifying the brightness and contrast.

  1. Open the photo you want to edit in GIMP.
  2. On the Image Window toolbar, click Colors and then click Brightness-Contrast.
  3. When the Brightness-Contrast dialog appears, use the two available sliders shown in Figure 2.15 to adjust the image, without making it seem too unrealistic or grainy.

    Figure 2.15. The Brightness-Contrast dialog contains slider bars that let you adjust the image.

    image

  4. When the preview appears satisfactory, click OK. The Preview check box in the Brightness-Contrast dialog is selected by default.
  5. Save the image.

The photo should be modified in the way you saw on the preview.

Show Me: Media 2.9—Softening a Photo with Blur Filters

You can watch a free video about softening a photo with blur filters when you log on to my.safaribooksonline.com/9780132174602/media.

image LET ME TRY IT

Softening a Photo with Blur Filters

While you probably want most of your photos to be crisp and sharp, sometimes certain photos benefit from a little selective blurring. This makes the subject of the photo seem softer or sometimes adds a bit of romance to the image. GIMP comes with a number of blur-related features to help out.

  1. Navigate to the desired photo and open it in GIMP.
  2. On the Image window toolbar, click Filters, Blur, and then click Blur in the menu, as shown in Figure 2.16.

    Figure 2.16. The Blur selection appears in the menu when you click Filters, Blur.

    image

  3. Click Edit and then click Undo Blur
  4. Click Filters, Blur, and then Selective Gaussian Blur.
  5. When the Selective Gaussian Blur dialog opens, verify that the Preview check box is selected, as shown in Figure 2.17, so you can see your changes (it should be selected by default).

    Figure 2.17. The Selective Gaussian Blur dialog lets you preview changes to an image.

    image

  6. If necessary, use the scrollbars to put the desired portion of the image in view.
  7. Use the Blur Radius arrows to set the degree of blur in pixels.
  8. Use the Max. Delta slider to select the maximum difference value between a pixel and the surrounding pixels.
  9. When the graininess of the image in the Preview is at the desired level, click OK.

The Selective Gaussian Blur plug-in doesn’t blur all the pixels in an image. Blur is applied only if the difference between the value of a pixel and its surrounding pixels is less than a defined Delta value. Generally the background of an image is blurred, resulting in foreground images appearing crisper. This also helps reduce minor graininess in a photo.

image LET ME TRY IT

Logo Fun

At times, you may need a logo or other text design fast and you don’t have the time to carefully select fonts, colors, and the like. The Logos feature may be of greater or lesser use to you, depending on your needs, but it is both fun and fast.

Tell Me More: Media 2.10—What Is Script-Fu?

You can listen to a free audio recording about Script-FU in GIMP when you log on to my.safaribooksonline.com/9780132174602/media.

  1. On the GIMP Main Toolbox toolbar, click File, Create, Logos, and then click Chrome.
  2. When the Script-Fu dialog appears as in Figure 2.18, accept the defaults and click OK.

    Figure 2.18. The Script-Fu dialog contains a number of different methods of adjusting the logo.

    image

  3. Repeat the actions from step 1, but this time select Basic I in the menu.
  4. In the Script Fu box, change the text in the Text field to a different word or words.
  5. For Font size (pixels) change the font size in the field to 150 or a similar value.
  6. Click the button next to font, and when the Font dialog appears, select a different font type than the default.
  7. Click the button next to Background color and when the Color selection box opens, use the color sliders or the numeric arrows to change the color values, and then click OK.
  8. Perform the same actions for Text color.
  9. When ready, click OK.
  10. Repeat the actions necessary to open the Logos menu and select Basic I again.
  11. On the Script Fu box for Basic I, click the Reset button to return the settings to their defaults.
  12. Click OK, then compare the default Basic I style to the modified Basic I style.

You now have a virtually instantaneous GIMP logo available for insertion into an image, document, or web page, and you have the ability to modify any of the standard GIMP logo styles in any way that suits you.

Show Me: Media 2.11—Creating Quick Logos

You can watch a free video about creating quick logos when you log on to my.safaribooksonline.com/9780132174602/media.

Reviewing the Script-Fu Dialog

Close the image without saving it and repeat step 1 in the previous exercise to examine the Script-Fu.

All the Script-Fu logo dialogs offer more or less similar options. We’ll use Chrome for our example:

Text—Use this field to enter the text for the logo.

Font Size (pixel)—Use the arrows to change the font size for the logo.

Font—Click the selector to open a dialog that lets you change the font type.

Background Color—Click the selector to choose a background color for the logo.

Depending on what GIMP features are required to produce the specific effects for the selected logo, the options available in the dialog can be slightly, to significantly, different.

Close the Script-Fu dialog and on the Main Toolbox toolbar, again click File, Create. Notice you also have options for Buttons, Patterns, and Web Page Themes. Although you don’t have the sheer number of list selections with these options as you do with Logos, they still let you quickly create other commonly used graphic objects. Buttons and the objects created in Web Page Themes are typically used in website design, and although you may prefer to create your own customized objects, this option can help out in a pinch.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset