Wallace wrote:
saulgoode wrote:
molly wrote:
That works but I don't understand why.
It works because the Rounded Selection script doesn't use the actual selection itself, it uses the boundaries of the selection. You could start with a star-shaped selection, for example, and the script would still produce a (rounded) rectangular result.
Why is that?
Whatever the shape of a selection, and no matter how it was created, there is what is known as a
bounding-box which is the smallest rectangle that wholly contains the entire selection.
For example, starting with an irregular selection as shown in blue, the bounding box is as shown in red:
(You can think of the bounding-box as the area that the image or layer would be cropped to if you did a Crop to Selection, because that's basically what it is!)
The Rounded Rectangle script simply creates a new selection which is a rounded-rectangle with the same dimensions as the bounding-box of the current selection, not the actual selection itself. By setting the radius to zero, what you get is simply the entire bounding-box, with no rounded corners!
In this case, you're using the Rounded Rectangle script to "mend" the selection. After growing from a square selection, you get rounded corners; by running the script with radius=0, you get the square corners back again.