element-hq / element-hq/synapse

"Squashed" thumbnails with EXIF rotation metadata

Open
#6,046 0 comments 0 reactions 0 assignees View on GitHub
A-Media-Repository O-Occasional S-Minor T-Defect
Dominant language
Python
Stars
4.6k
Forks
600
Avg merge
5d 22h
Merged PRs (30d)
51

Description

This issue has been migrated from [#6046](https://github.com/matrix-org/synapse/issues/6046).

---

### Description

(I originally submitted a bug for riot-web here: https://github.com/vector-im/riot-web/issues/10903)

Consider a picture with EXIF rotation metadata (eg. a photo taken with a phone that was not turned 90° on the side), such as:

![IMG_20190915_082630](https://user-images.githubusercontent.com/1388961/65116530-3289a680-d9e9-11e9-9327-05e61c983ae8.jpg)

When opened in an application that takes into account EXIF rotation metadata, we see this:

![Capture d’écran du 2019-09-18 07-53-18](https://user-images.githubusercontent.com/1388961/65116718-6cf34380-d9e9-11e9-80b6-2ffe149de3d2.png)

**However** when we upload this picture in Riot, the thumbnail shows this:

![Capture d’écran du 2019-09-18 07-54-38](https://user-images.githubusercontent.com/1388961/65116842-93b17a00-d9e9-11e9-8a07-fa6220147f47.png)

### Steps to reproduce

- Take a picture with your phone and without rotating your phone on the side.
- Upload the picture in a matrix room using Riot-web : the thumbnail appears, and while the photo was rotated by taking into account the EXIF metadata, it appears "squashed".

### Version information

- **Homeserver**: my own private homeserver

- **Version**: 1.3.1

- **Install method**: official docker image

- **Platform**: Debian 9

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.