Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scale Crop Frame by Percentage #6791

Open
foxox opened this issue Jul 11, 2023 · 5 comments
Open

Scale Crop Frame by Percentage #6791

foxox opened this issue Jul 11, 2023 · 5 comments
Labels
scope: GUI Changes to GUI, not core functionality type: enhancement Something could be better than it currently is

Comments

@foxox
Copy link

foxox commented Jul 11, 2023

Hi! I am a professional software engineer and I use RawTherapee extensively in an amateur capacity. I have wanted to first crop an image for digital display, but then also produce a slightly larger (~106%) crop for full-bleed printing. I have some code working for me now in a branch at: dev...foxox:RawTherapee:feature/jdrake-crop-scale
image
Before I made a PR, I wanted to discuss the concept with you all.

I think another way to accomplish what I want to do would be to add a new crop guide type like "Frame within frame", with a user-configurable scale for the inner frame. Or, a checkbox and spin button to add a second frame to any of the other existing guides - so you could have something like Centered Square within a rectangular frame, the centered square portion scaled down by a specified percentage. This way I could adjust the crop aesthetically for the inner frame guides, but the output image would include the full larger crop.

What do you all think?

@Lawrence37
Copy link
Collaborator

The last option makes the most sense to me because a safety margin is distinct from crop guides.

I've seen a similar concept in other contexts (like video production). The difference is there is only one crop used when exporting which is the bigger one. The smaller rectangle is the visual guide to show the safe region in case some of the edges get cut by whatever the display may be. You may want to design in such a way to allow this variant to be integrated seamlessly in the future, or actually implement it too if you're feeling adventurous.

@Lawrence37 Lawrence37 added type: enhancement Something could be better than it currently is scope: GUI Changes to GUI, not core functionality labels Jul 11, 2023
@foxox
Copy link
Author

foxox commented Jul 12, 2023

Thank you for your feedback, @Lawrence37.
I started working on crop guide changes in a new branch here dev...foxox:RawTherapee:jdrake-crop-safe-area
So far only gotten through some code cleanup and documentation while trying to make sense of the existing code. Where I left off, I was trying to figure out what coordinate frame each of the inputs to drawCrop is in: int imx, int imy, int imw, int imh, int startx, int starty. I wish there were more documentation explaining things like this. I intend to document everything I learn so the next guy has an easier time of this...

@digitalteg
Copy link

I read this with interest, @foxox . I'm not sure I understand the idea you suggest.

However, the option/variant that @Lawrence37 mentioned reminds me of #6664, a feature that I requested, where a crop guide could contain multiple nested aspect ratios. I implemented something for my own use, but it lacks a GUI.
It seems that your suggestion is something more general. So, I'm interested in what you come up with.

@adam4
Copy link

adam4 commented Aug 9, 2023

hello, I've been trying to think of an elegant solution for this, the bleed size is normally fixed, my printers use 3mm for every paper size, I guess it would make sense to have a "bleed" option in the resize section, then adjust the ratio being used in the crop section automatically, if the final image size is also chosen already in the resize section

@adam4
Copy link

adam4 commented Aug 9, 2023

scribus has options for bleed size on all 4 sides, I don't know how many people use this, if laying out a double page spread for instance they might not want bleed on the inner edge

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope: GUI Changes to GUI, not core functionality type: enhancement Something could be better than it currently is
Projects
None yet
Development

No branches or pull requests

4 participants