221 lines
11 KiB
Plaintext
221 lines
11 KiB
Plaintext
|
|
Episode: 3160
|
||
|
|
Title: HPR3160: GIMP: Transform Tools
|
||
|
|
Source: https://hub.hackerpublicradio.org/ccdn.php?filename=/eps/hpr3160/hpr3160.mp3
|
||
|
|
Transcribed: 2025-10-24 18:00:20
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
This is Hacker Public Radio Episode 3,160 for Friday 11 September 2020. Today's show is entitled,
|
||
|
|
Gimp, Transform Tools,
|
||
|
|
and is part of the series Gimp. It is hosted by Ahuka
|
||
|
|
and is about 17 minutes long, and carries a clean flag. The summer is
|
||
|
|
with Transform Tools, you can stretch, move, and crop the image.
|
||
|
|
This episode of HPR is brought to you by AnanasThost.com.
|
||
|
|
Get 15% discount on all shared hosting with the offer code
|
||
|
|
HPR15, that's HPR15.
|
||
|
|
Better web hosting that's honest and fair at AnanasThost.com.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
.
|
||
|
|
the shortcut is Q, the move tool shortcut is M, crop, shift plus C, rotate, shift plus
|
||
|
|
R, scale, shift plus T, shear, shift plus S, perspective, shift plus P, flip, shift plus
|
||
|
|
F, engage, transform, shift plus G. So those are the tools. Now let's get to each one
|
||
|
|
of them. The align tool moves one or more layers to align with a target. Well, what's the
|
||
|
|
target? Could be any of several things. The target could be the first item. So if you
|
||
|
|
had selected multiple layers using the shift key when clicking on the layers, the first
|
||
|
|
one you clicked on is the first item. So what you can do is you can click that one and
|
||
|
|
then click a few others and align those other layers to line up with that first one. You
|
||
|
|
can align with an image. You can align with a selection. You can align with the active
|
||
|
|
layer or the active channel or the active path. And you make this choice in the tool options
|
||
|
|
panel on the bottom left. Now once you have your target selected, you can align the layers
|
||
|
|
you chose using the alignment buttons below the target selection. You can align to the left
|
||
|
|
side horizontal middle right side top vertical middle and bottom. Now if you need to add an
|
||
|
|
offset, you do that with the distribute buttons, which are right under the align buttons and look
|
||
|
|
exactly the same. The only difference is you add an offset in the box at the bottom. And that's
|
||
|
|
how many pixels, I'm going to say pixels because I'm assuming we're going to be working with
|
||
|
|
computer screen images at this point. Remember we talked before about the differences between
|
||
|
|
pixels and points and print versus computer screens and all of that. So for the moment,
|
||
|
|
I'm just going to assume it's pixels and so you add how many pixels. So if you added a 10 pixel
|
||
|
|
offset, which is actually a very small distance by the way, and then align to the left, what would happen
|
||
|
|
would be you wouldn't align all the way to the left side, you'd align to 10 pixels away from the left
|
||
|
|
side. So that's how the distribute buttons work. Now move is pretty straightforward. You can move
|
||
|
|
a layer, a selection or a path. And again, you choose the mode in the tool option section on the
|
||
|
|
lower left. You can also make a choice between picking layer or guide or only being able to move
|
||
|
|
the active layer. Now personally, I don't see the point in restricting your options. So I leave mine
|
||
|
|
to pick the layer or guide. The crop tool, Shift plus C, the crop tool is pretty easy to use.
|
||
|
|
When you select the tool, your cursor will become a cross like target site with a knife icon under it.
|
||
|
|
Center the cross on one corner of the area you want and click and drag to create a rectangle.
|
||
|
|
You can adjust the selection using the handles, i.e. the little rectangles that show in the corners
|
||
|
|
of the selection. And when you have it where you want it, either click in the middle of the selection
|
||
|
|
or hit the Enter key, and what you have selected will be the only thing left. This tool is one I
|
||
|
|
use frequently on old photos to remove unwanted borders as an example. Rotate Shift plus R.
|
||
|
|
This lets you rotate a layer, a selection or a path. And like most tools, the mode selection
|
||
|
|
is in the tool options on the lower left. When you select this tool and then click on the image,
|
||
|
|
you'll get a window that pops up and lets you set an angle, which you can specify numerically
|
||
|
|
or use a slider right under it to create the angle. You can adjust the center of the rotation.
|
||
|
|
By default, it will be the mathematical center of the image, but you can change that.
|
||
|
|
It is set using units of pixels by default, so you can set everything there and then just click the
|
||
|
|
rotate button on the lower right of this window and it will do that. Now you can also free-hand
|
||
|
|
the rotation by just clicking on the image and dragging it around. If you want to constrain
|
||
|
|
this a little, you can use the trick we saw before with the paint tools and hold down the control key
|
||
|
|
while you're clicking and rotating, and that will restrict the rotation to multiples of 15 degrees.
|
||
|
|
This is useful if you want to turn a square into a diamond shape, for instance. Three steps
|
||
|
|
gets it to a perfect 45 degree rotation. Note that you can rotate something so that part of it
|
||
|
|
is off the canvas. When you do, you can, if you like, go to image menu and select fit canvas to
|
||
|
|
layers, and then the entire rotated image will fit inside a new larger canvas. But note the
|
||
|
|
canvas itself won't be rotated. Canvases are always rectangles that are aligned in perfect
|
||
|
|
vertical and horizontal directions. Scale tool, Shift plus T. This tool changes the size of the image.
|
||
|
|
When you select this tool and click on the image, again, you get a window that appears. Let's
|
||
|
|
you select the width and the height of the final image. Units again are going to be by default in
|
||
|
|
pixels, and then when you have it where you want it, you can just click the scale button and the
|
||
|
|
lower right of this pop-up window. Now, as with rotate, this pop-up window gives you a little finer
|
||
|
|
control by setting the precise definitions. But there will also be a grid overlaying the image
|
||
|
|
and eight handles, four of them at the corners, four of them on the sides, that you can use to
|
||
|
|
adjust this as well. Now, one thing to keep in mind in changing the scale is you can introduce
|
||
|
|
distortion if one dimension changes more than the other so that elements are stretched in either
|
||
|
|
the vertical or horizontal dimension. Now, if you want to prevent this, use the check box on the
|
||
|
|
bottom of the tool options that says keep aspect or hold down the control key while you click
|
||
|
|
and drag. Finally, if you increase the size beyond the canvas, go to the image menu, select fit
|
||
|
|
canvas to layers to correct this. Shared tool, Shift plus S. The shared tool distorts the image by
|
||
|
|
a kind of a twisting. In the horizontal direction, it can drag the top of the image one way and then
|
||
|
|
the bottom will automatically go the other way. Or in the vertical direction, it will drag one side
|
||
|
|
up and the other side down. This is not rotation. It is a stretching of the image that definitely
|
||
|
|
distorts it. Again, when you select the tool and click on the image or selection, you will get a pop-up
|
||
|
|
window and it will let you select the sheer magnitude for either the x-axis, the horizontal direction,
|
||
|
|
or the y-axis, which is the vertical direction. Now, using this gives you finer control, but note you
|
||
|
|
can only do either x or y at any one time to do both. You have to use the tool twice in a row.
|
||
|
|
Now, you can also freehand it using the mouse with a grid that appears, but again, only one direction
|
||
|
|
of the time, and as before, you can resize the canvas if needed. As perspective tool, Shift plus P.
|
||
|
|
This is really a tool for distorting the image. It is not a true perspective tool. It can, however,
|
||
|
|
be used to create the appearance of perspective. You can see what I mean. If you create a blank canvas
|
||
|
|
with a white background and you create a black rectangle and move that around, you will get a good
|
||
|
|
idea of what I am talking about. When you do this, you select the perspective tool. It will pop up a
|
||
|
|
window with various coordinate values based on the idea of a transformation matrix, which is a
|
||
|
|
very technical thing. You can read about it with Kapedia, and I will put the link in the show notes
|
||
|
|
for those of you who really want to subject yourself to that, but I say it is highly technical.
|
||
|
|
But what the tool does, basically, is let you stretch the image by pulling any corner,
|
||
|
|
and it will stretch that corner independently. None of the other tools do that thing exactly.
|
||
|
|
You can then pick a different corner to add more distortion, and it can definitely be used to
|
||
|
|
create perspective. But my advice is that unless you are highly technical about this kind of thing,
|
||
|
|
forget about the transformation matrix, and just use the grid to click and drag until it looks
|
||
|
|
right to you. Now, flip is the simplest of the transformation tools. It creates mirror images,
|
||
|
|
and it can either flip the image vertically or horizontally, and you choose which it will be
|
||
|
|
in the tool options area on the lower left. Easy peasy. And last of them is the cage transform,
|
||
|
|
and that is Shift plus G. And what this does is let you define an area on your image
|
||
|
|
by clicking to select anchor points or control points, and we've seen things like that before
|
||
|
|
with the selection tools. And what you need to do is make a free form kind of box. Every time you
|
||
|
|
click to set another control point or another anchor point, a line will connect those two points,
|
||
|
|
and you keep clicking around until you get back to the beginning and click on your initial point,
|
||
|
|
and then you've got the whole thing selected. And then when you do that, click on any one of those
|
||
|
|
anchor points and drag it to distort the image. So this is one of those ones that at first glance
|
||
|
|
looks really weird, but it gets some very interesting effects with it. Now, in summary,
|
||
|
|
as with the other tools we've covered, the best way to learn these is playing around with them.
|
||
|
|
Now, for most of these, I suggest using a photo to see what each of them does.
|
||
|
|
After all, if you had a black rectangle and you used the flip tool, you're not going to see anything.
|
||
|
|
If you want to dig deeper, also I always put a link in the show notes to the GIMP documentation site,
|
||
|
|
and there's a lot more information there about all of these if you really want to plumb the
|
||
|
|
depths. And bear in mind that these tutorials are not plumbing the depths. They're an introductory
|
||
|
|
look at this to get you familiar. So I would suggest playing around with these a little bit,
|
||
|
|
get to know them, and we've still got one more group of tools to look at. And after that,
|
||
|
|
I think we can probably get on to something else. Maybe the layers would be next. Let's see what
|
||
|
|
happens. So this is a hookah for Hacker Public Radio, signing off, and as always, asking you to support
|
||
|
|
free software. Bye-bye.
|
||
|
|
You've been listening to Hacker Public Radio at Hacker Public Radio. We are a community podcast
|
||
|
|
network that releases shows every weekday, Monday through Friday. Today's show, like all our shows,
|
||
|
|
was contributed by an HPR listener like yourself. If you ever thought of recording a podcast,
|
||
|
|
then click on our contributing to find out how easy it really is. Hacker Public Radio was founded
|
||
|
|
by the digital dog pound and the infonomican computer club, and it's part of the binary revolution
|
||
|
|
at binrev.com. If you have comments on today's show, please email the host directly, leave a comment
|
||
|
|
on the website or record a follow-up episode yourself. Unless otherwise status, today's show is
|
||
|
|
released on the creative comments, attribution, share a like, 3.0 license.
|