You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The dimensions in image_resize() function call should always be the dimensions of the resulting image.
If this is not possible, the function should prevent confusion, for example by warning the user, and provide a way to deal with that in templates, for example by providing an orientation field in get_image_metadata() output.
Current Behavior
The current function seem to apply before EXIF reorientation. For example here's my image not processed by Zola
Bug Report
Environment
Zola version: 0.18.0
Expected Behavior
The dimensions in
image_resize()
function call should always be the dimensions of the resulting image.If this is not possible, the function should prevent confusion, for example by warning the user, and provide a way to deal with that in templates, for example by providing an orientation field in
get_image_metadata()
output.Current Behavior
The current function seem to apply before EXIF reorientation. For example here's my image not processed by Zola
❯ identify static/photos/testExif.jpeg static/photos/testExif.jpeg JPEG 4032x3024 4032x3024+0+0 8-bit sRGB 2.4495MiB 0.000u 0:00.000 ❯ identify -format '%[orientation]' static/photos/testExif.jpeg RightTop%
and after
zola build
withresize_image(src=/photos/testExif.jpeg, width=2000, height=1000)
❯ identify static/processed_images/testExif.jpg static/processed_images/testExif.357e1078f1bc4b6c.jpg JPEG 1000x2000 1000x2000+0+0 8-bit sRGB 259274B 0.000u 0:00.000 ❯ identify -format '%[orientation]' static/processed_images/testExif.357e1078f1bc4b6c.jpg Undefined%
Which is very confusing because the resulting image doesn’t have the width and height I set in the resize function.
Step to reproduce
Try to
resize_image()
an image with EXIF orientation not null, the resize don’t apply where you expect.The text was updated successfully, but these errors were encountered: