Support reading WebP and HEIC image formats natively
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 17.9k
- Forks
- 7.3k
- Avg merge
- 1d 15h
- Merged PRs (30d)
- 13
Description
🚀 The feature
WebP is very popular for images from the web (11.7%). HEIC is gaining popularity for images captured by phones (thanks Apple. I know some Android phones can take HEIC images also). Able to read these images directly without conversion would be beneficial for the users, especially to avoid loss of image quality.
Writing WebP and HEIC, though good to have, is not really important. But if we are to link against existing WebP/HEIC libraries, I figure we would get both decode and encode capabilities.
Note: HEIC is just a container format. It can contain various formats. For example, photos taken by my iPhone 15 is HEIF/AVIF
Motivation, pitch
When collecting my own data, I often come across WebP (from the internet) and HEIC (from phones).
Alternatives
Pillow can read (and write) WebP. To read/write HEIC with Pillow, users have to install a 3rd-party extension, like this one: https://github.com/bigcat88/pillow_heif
Additional context
libwebp: https://developers.google.com/speed/webp/download
libheif: https://github.com/strukturag/libheif
It seems like there can potentially be licensing issue for HEIF. I'm not too familiar with it.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the existing image-reading path and its Pillow integration, then review the libwebp and libheif references in the issue. Clarify whether native decoding should cover WebP, HEIC/HEIF, and AVIF, and resolve the licensing question before defining implementation and tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- computer-vision
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100