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

Files: don't run thumb processing if image smaller than the create dimensions #6437

Open
distantnative opened this issue May 5, 2024 · 2 comments
Labels
type: performance ⚡️ Is about performance; improves performance

Comments

@distantnative
Copy link
Member

Original thread: https://forum.getkirby.com/t/uploaded-images-are-kept-the-same-dimensions-but-are-much-smaller-file-sizes/31488/6

I think this should be fixed inside the Darkroom libraries, e.g. somewhere here: https://github.com/getkirby/kirby/blob/main/src/Image/Darkroom/GdLib.php#L61

If no cropping and the current dimensions are already within the target dimensions, don't do anything.

@distantnative distantnative added the type: performance ⚡️ Is about performance; improves performance label May 5, 2024
@gbdesign2023
Copy link

@distantnative I could not detect any compression during the upload in a default blueprint.
With a file blueprint for images only, however, I did.

@distantnative
Copy link
Member Author

@gbdesign2023 I also get smaller file sizes with just any blueprint adding create options for width/height exceeding the original dimensions of the uploaded file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: performance ⚡️ Is about performance; improves performance
Projects
None yet
Development

No branches or pull requests

2 participants