镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

perf(preview): only autorotate with Imaginary when needed - #65148

Open
CarlSchwan wants to merge 1 commit into
masterfrom
carl/preview-imaginary-autorotate
Open

CarlSchwan wants to merge 1 commit into
masterfrom
carl/preview-imaginary-autorotate

Conversation

@CarlSchwan

Copy link
Copy Markdown
Member

Summary

Every operation of an Imaginary pipeline decodes and encodes the full image again, so the autorotate operation made each JPEG preview about three times slower: 780ms instead of 286ms for the max preview of a 12 MP photo, 258ms instead of 80ms for a 256px one. Read the EXIF orientation from the start of the file and only add the operation when the image needs to be rotated.

TODO

  • ...

Checklist

AI (if applicable)

  • The content of this PR was partly or fully generated using AI

@CarlSchwan CarlSchwan added this to the Nextcloud 36 milestone Oct 5, 2026
@CarlSchwan CarlSchwan self-assigned this Oct 5, 2026
@CarlSchwan
CarlSchwan requested a review from a team as a code owner October 5, 2026 15:03
@CarlSchwan
CarlSchwan requested review from Altahrim, icewind1991, leftybournes and salmart-dev and removed request for a team October 5, 2026 15:03
Every operation of an Imaginary pipeline decodes and encodes the full
image again, so the autorotate operation made each JPEG preview about
three times slower: 780ms instead of 286ms for the max preview of a
12 MP photo, 258ms instead of 80ms for a 256px one. Read the EXIF
orientation from the start of the file and only add the operation when
the image needs to be rotated.

Assisted-by: ClaudeCode:claude-opus-5-5
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
@CarlSchwan
CarlSchwan force-pushed the carl/preview-imaginary-autorotate branch from 1e9a2fc to 6b3aec3 Compare October 5, 2026 17:45

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants