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

Resizing crops before saving. #3470

Merged
merged 4 commits into from
Jan 31, 2024
Merged

Resizing crops before saving. #3470

merged 4 commits into from
Jan 31, 2024

Conversation

hoominchu
Copy link
Collaborator

@hoominchu hoominchu commented Jan 30, 2024

Resolves #3467

To avoid saving images of different resolutions based on the user's browser zoom level, we are resizing the images on the server side right before saving it. This way we will have uniform size for all the crops saved.

Testing instructions
  1. Change the browser zoom to more than 100%. Place a label. Make sure that the crop saved is of size 1440x960.
  2. Change the browser zoom to less than 100%. Place a label. Make sure that the crop saved is of size 1440x960.
Things to check before submitting the PR
  • I've written a descriptive PR title.
  • I've added/updated comments for large or confusing blocks of code.

Copy link
Member

@misaugstad misaugstad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I changed from SCALE_DEFAULT to SCALE_SMOOTH and fixed some indentation. Thanks @hoominchu !

@misaugstad misaugstad merged commit 18f5b8b into develop Jan 31, 2024
@misaugstad misaugstad deleted the save-crops branch January 31, 2024 01:37
@misaugstad misaugstad mentioned this pull request Jan 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Ensure that cropped images that we save are a consistent size
2 participants