 # What does edit->selecction->scale do?

I am searching to find the mechanism that edit->selection>scale does but I did not find explanation here:
I am using it to scale down the image in other words to mask the image to a smaller image. But I dont know how does that work. Does it work base on the ratio of initial surface to the ratio of final surface? for example is the scale is 0.65 does that mean that the final image surface is 0.65 of the initial image surface? or does it scale down the image based on an other method?

It seems to change the size of the selection. It simply multiplies the input value with the selection.

Given a selection:

``````makeRectangle(124, 81, 230, 173);
``````

Then apply a scaling of 0.5 in x and 1.0 in y it will then do this operation to the selection:

``````makeRectangle(124 * 0.5, 81* 1, 230* 0.5, 173* 1);
``````

I don’t understand how this relates to image scaling. Downsampling of the image is a different thing. You need to resample the image entirely and thus not only reduce the number of pixels but also resample the image information (gaussian convolution). For this you use Plugins > Examples > Downsample

1 Like

@schmiedc Thanks for the response. I dont think that would fully answer the question. Because in some cases I see that this scaling down is not symmetric. E.g. I apply the same scale down to both x and y and then I see that in one part of the geometry the difference between the initial boundary with boundary of the new image is larger than other part of the geometry. If it was doing similar to what you explained, it would scale down concurrently in all parts of the image. This is more evident in irregular mages may be sth is related to the center of the mass. Sorry I could not share the image of the example I am talking about as I am not allowed. But this question is general that what is exactly run(“scale”,) doing as I did not find any explanation of it here or elsewhere.