luberda-molinet / FFImageLoading

Image loading, caching & transforming library for Xamarin and Windows
MIT License
1.42k stars 377 forks source link

fix:fix orientation of Android #1538

Closed maonaoda closed 1 year ago

maonaoda commented 3 years ago

:sparkles: What kind of change does this PR introduce? (Bug fix, feature, docs update...)

fix jpg/jepg image orientation of Android

:arrow_heading_down: What is the current behavior?

When the Exif information of a jpg/jepg image has both Exif IFD0 and Exif Thumbnail, and the image orientation of Exif IFD0 and Exif Thumbnail are inconsistent, the final picture orientation displayed on Android is not the actual orientation of the picture, but the orientation of the Thumbnail.

test result before change: image

:new: What is the new behavior (if this is a feature change)?

The final picture orientation displayed on Android is the actual orientation of the picture, not the orientation of the Thumbnail.

test result after change: image

:boom: Does this PR introduce a breaking change?

No.

:bug: Recommendations for testing

Use images with different exif information for testing .

:memo: Links to relevant issues/docs

https://github.com/luberda-molinet/FFImageLoading/issues/1537

:thinking: Checklist before submitting

maonaoda commented 3 years ago

test images :

origin : orientation of Exif IFD0 thumbnail : orientation of Exif Thumbnail

Landscape_origin_3_no_thumbnail.jpg Landscape_origin_3_no_thumbnail

Landscape_origin_3_thumbnail_3.jpg Landscape_origin_3_thumbnail_3

Landscape_origin_3_thumbnail_1.jpg Landscape_origin_3_thumbnail_1