fix: apply crop bounds before EXIF rotation to match AI analysis

Gemini analyzes raw image and returns crop_bounds for that coordinate space.
Previous code applied EXIF rotation first, changing image dimensions, then
used crop_bounds on the rotated image (coordinate mismatch).

Now: crop on raw image (matches AI) → then apply EXIF + manual rotation.
This ensures cropped region contains the actual item, not background.
This commit is contained in:
2026-04-22 09:50:08 +03:00
parent 59565c9b8a
commit 197dcadfee
5 changed files with 149 additions and 9 deletions

View File

@@ -97,7 +97,8 @@
"Bash(sed -i 's/as jest\\\\.Mock/as any/g' tests/hooks/useAIExtraction.test.ts)",
"Bash(grep -E \"\\\\.tsx?$\")",
"Bash(sqlite3 *)",
"Skill(gsd-resume-work)"
"Skill(gsd-resume-work)",
"Bash(git revert *)"
]
}
}