Bug 106060 - Add support for EXIF in jpegtran and rdjpgcom tools
Add support for EXIF in jpegtran and rdjpgcom tools
Status: CLOSED WONTFIX
Product: Red Hat Linux
Classification: Retired
Component: libjpeg (Show other bugs)
9
All Linux
medium Severity medium
: ---
: ---
Assigned To: Matthias Clasen
David Lawrence
: FutureFeature
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2003-10-02 09:04 EDT by diego.santacruz
Modified: 2007-04-18 12:58 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2005-03-06 23:09:49 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Patch for basic EXIF support in jpegtran (16.62 KB, patch)
2003-10-02 09:47 EDT, diego.santacruz
no flags Details | Diff
Patch to implement the requested rdjpeg features (5.27 KB, patch)
2003-10-02 09:51 EDT, diego.santacruz
no flags Details | Diff

  None (edit)
Description diego.santacruz 2003-10-02 09:04:27 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 Galeon/1.2.7 (X11; Linux i686; U;) Gecko/20030131

Description of problem:
Current versions of jpegtran and rdjpgcom tools of libjpeg are not aware  of the
EXIF kind of JPEG files.

In jpegtran, even using the '-copy all' does not treat EXIF files correctly. The
problems are

1. A JFIF marker is always added to the output file, which is incompatible with
EXIF (EXIF requires that EXIF marker be first extra marker, but JFIF has the
same requirement).

2. Upon a geometric transformation (e.g., 90 deg rotation) the image dimension
fields in the EXIF marker are not updated.

3. Upon a geometric transformation the EXIF orientation flag is not reset.

As EXIF files become increasingly popular as they are produced by nearly all
digital cameras, this issues create a bunch of problems with dealing with EXIF
images.

Also rdjpgcom should probably report the EXIF orientation when in verbose mode.

Version-Release number of selected component (if applicable):
libjpeg-6b-28
Comment 1 diego.santacruz 2003-10-02 09:47:34 EDT
Created attachment 94878 [details]
Patch for basic EXIF support in jpegtran

This patch adds the requested features to jpegtran. It basically does:

1. Recognizes EXIF files as such and does not add an incompatible JFIF marker.
2. Upon a geometric transformation it adjusts the dimensions in the EXIF marker
to match the JPEG image dimensions.
3. Upon a geometric transformation it resets the EXIF orientation flag so that
the resulting JPEG image is considered to be in the upright position already.
4. Add the option '-copy exif' that allows to recover an EXIF file to which a
JFIF marker was incorrectly added.

The patch does not affect the library code, only the jpegtran code and
therefore it should not pose any compatibility problems.
Comment 2 diego.santacruz 2003-10-02 09:51:50 EDT
Created attachment 94879 [details]
Patch to implement the requested rdjpeg features

This patch adds basic EXIF support to rdjpgcom: in -verbose mode it prints the
EXIF orientation, if any is found.

This, in conjunction to the patched jpegtran, allows to write scripts that
automatically orient images based on the EXIF orientation field (used by some
digital cameras for this very same purpose).

The patch does not modify any library code, so it should not present any
compatibility problems.
Comment 3 diego.santacruz 2003-10-02 10:03:42 EDT
I have also reported these patches to the IJG at jpeg-info@uunet.uu.net
Comment 4 Matthias Clasen 2005-03-06 23:09:49 EST
I believe that these features would best be done by packaging jhead for Fedora.

Note You need to log in before you can comment on or make changes to this bug.