Subject: bug#23070: 25.1.50; Wishlist: image mode should have a command to display (and edit?) exif data

From: Lars Ingebrigtsen <[email-masked]>
Date: Sat, 21 Sep 2019 15:37:00 +0200

Lars Magne Ingebrigtsen <[email-masked]> writes:

> I had a peek at the exif data format, and it's quite simple.  Parsing it
> in Lisp shouldn't be too much work.

And I've implemented this now, which means that ImageMagick-less Emacs
is now kinda back up to feature parity with ImageMagick: That is, we can
look at the rotation in the exif data and display accordingly.

(exif-parse "~/pics/redslur/P1410570.JPG")
=>
((:tag 271 :format 2 :format-type ascii :value "Panasonic")
 (:tag 272 :format 2 :format-type ascii :value "DMC-GH4")
 (:tag 274 :format 3 :format-type short :value 1)
 (:tag 282 :format 5 :format-type rational :value
       (180 . 1))
 (:tag 283 :format 5 :format-type rational :value
       (180 . 1))
 (:tag 296 :format 3 :format-type short :value 2)
 (:tag 305 :format 2 :format-type ascii :value "Ver.2.0  ")
 (:tag 306 :format 2 :format-type ascii :value "2019:09:18 01:18:40")
 (:tag 531 :format 3 :format-type short :value 2)
 ...)

But...  I'm not sure to what degree to support the various tags.  I
mean, it would be nice to display them and stuff, and editing them would
also be nice, but...  perhaps that should be left to an add-on package?
So have a basic exif.el in Emacs core (to allow images to be displayed
better), and if somebody wants to edit this stuff, it can be an ELPA
package?

Any opinions?

The other thing I'm wondering about is whether anybody knows of a source
for tag names that has a license that allows using the data in Emacs.

For instance, I don't see a license here, so I'm guessing copying the
table won't be ... good?

https://www.exiv2.org/tags.html

Having some version of such a table is necessary for transforming the
cryptic numbers up there from (for instance) 274 to `orientation' or
something.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no