bojand / infer

Small crate to infer file and MIME type by checking the magic number signature
MIT License
299 stars 28 forks source link

feat: add support for OpenRaster (ora) format #81

Closed chrsmth closed 1 year ago

chrsmth commented 2 years ago

What is an OpenRaster File?

spec reference

OpenRaster is an exchange format between layered photo editing programs. It is supported by GIMP, Krita, imagemagick, Scribus, and others. A GIMP project can be exported as OpenRaster, and then opened in Krita for example.

testdata/sample.ora was generated in GIMP, and is the usual cat image, but with a reflection.

mergedimage

Expanding the OpenRaster as a zip reveals a transparent directory structure.

image

Detection

OpenRaster is zip wrapped with unencrypted mimetype file containing "image/openraster".

bojand commented 1 year ago

Hello, thanks for the PR. This should be available in v0.12.0.