Improving "Clipping" in transformation tools: clipping target + GUI rethinking
Operating System: all
Description of the feature
The "Clipping" settings is always a bit of a mystery to me. Each time I have to read the docs to understand/remember again what is what. I think this could be improved by reviewing a bit the GUI. Possibly even replacing this one scrolldown "Clipping" settings by breaking it into more understandable sub-options.
Typically there are currently a single option where you don't do any kind of clipping/cropping (Adjust) vs. options where you crop, either to the old layer size (Clip) or to as much as possible without having any transparent area (Crop to Result) or finally cropping to keep the same ratio as the original layer. I wonder if we could not reorganize differently the choices.
The second thing is relatively to what we clip. Right now, it's all relative to the layer. But we have use cases where it could be relatively to the canvas, or even relatively to specific pixel size and/or a given ratio. It is both a different topic but related because I think that any new GUI rework of these options should take both choices into consideration.
Use cases
Today @aryeom had a class with students where we would try to rectify a paint from a photography with the Perspective tool in corrective mode. Since the tool can't know the actual object ratio, it would adjust the handle contents to fit into the layer size, which means you need to first crop the layer to be the right ratio, but also it needs you need to crop bigger than the original needed contents since you must crop destructively (as the layer size matters). Here is the process:
- Load your image in GIMP
- Since I know that the paint is 63×76cm in real life, crop with "Delete crop pixels" (or possibly "Selected layers only" if you have more layers you don't want to crop) and "Fixed Aspect ratio" of 63:76.
- Now with Perspective tool, select "Corrective" direction and "Adjust" clipping. Move the handles to the paint corners, then transform.
- Finally since I want the frame into my image, I could crop again with "Allow growing".
So I go from left (first step) to right (last step):
The problem with this workflow is that the first crop is annoying and also necessarily destructive because the layer size is used as the clipping reference.
The second problem is that since we necessarily need to target a target size bigger than the original size, which might not be what we want, quality wise (we can rescale after, but then it's one more transformation step; if we can do the thing on one step, it means less quality loss).
These could be avoided if we had a way to choose the clipping target: it could be either the layer, or the canvas (so we could crop non-destructively and even to smaller size) or even to any size as set through pixel (then no crop needed at all). Optionnally setting a ratio and letting the tool choose the biggest possible size with this ratio within the handles for instance.
There is definitely something to improve here. I'm letting this report for myself as I may want to have a look at it, but not now and probably not by GIMP 3.0. So it's a self-reminder.