Get the latest tech news

Resizing images in Rust, now with EXIF orientation support


A new version of Rust's image crate has support for EXIF orientation, which allows me to resize images without mangling their rotation.

This metadata is usually added by cameras and phones, which can detect how you’re holding them, and tell viewing software how to display the picture later. The thumbnail still doesn’t have any EXIF orientation data, but the pixels have been rearranged so the resized image looks similar to the original. I’ve written this fix, but images with an EXIF orientation are rare enough that I always forget them when I start a new project – and I used to solve the same problem again and again.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of Rust

Rust

Photo of resizing images

resizing images

Photo of Exif

Exif

Related news:

News photo

Dotter: Dotfile manager and templater written in Rust

News photo

Show HN: Downloading a folder from a repo using rust

News photo

Show HN: Ion, a Rust/Tokio powered JavaScript runtime for embedders