[
https://issues.apache.org/jira/browse/IMAGING-221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16853760#comment-16853760
]
Joakim Knudsen commented on IMAGING-221:
----------------------------------------
I have set up a project with Commons Imaging (downloaded JAR from apache), and
set up the Sample Usage code (WriteExifMetadataExample.java). I have a JPEG
with comments and title/description meta data, which is not the output of my
code/app. Running this image through the sample code, adding GPS coordinates,
it seems the initial meta data is, fortunately, not affected. Looking through
the above discussions again, I guess I must have misunderstood; The input to
producing the file "mine-gps.jpg" is, perhaps, the file "mine-original.jpg"
which does not contain description and UserComment fields?
> updateExifMetadataLossless restructures meta data (and problems with Maker
> Notes)
> ---------------------------------------------------------------------------------
>
> Key: IMAGING-221
> URL: https://issues.apache.org/jira/browse/IMAGING-221
> Project: Commons Imaging
> Issue Type: Bug
> Reporter: Joakim Knudsen
> Assignee: Bruno P. Kinoshita
> Priority: Major
> Fix For: 1.0-alpha2
>
> Attachments: mine-gps.JPG, mine-metadata.JPG, mine-original.JPG,
> mine.JPG, mine.JPG.html, original.JPG, original.html, tagsmissing.png,
> test.JPG, test.html
>
>
> ExifRewriter's *updateExifMetadataLossless* method causes the meta data of
> the JPEG to be completely reordered after writing. This, in itself, might not
> be a big concern, but it's a bit unexpected when the method is named
> "lossless". More worryingly, I also find problems are introduced wrt. the
> Maker Notes tag (odd offset).
> I've produced an example of the problem in the attached JPEG file, using
> ExifTool to validate/analyze the images before and after. The image is taken
> by a Sony Xperia Z5 phone, and the "original.JPG" validates OK. After
> modifying the contents of the UserComments tag (value: "Test") the modified
> image produces a warning:
> Verifying the attached photo using ExifTool gives the following output:
> $ ./exiftool\(-k\).exe -validate -warning -a ../test.JPG
> -- press RETURN --
>
> Validate : 1 Warning (all minor)
> Warning : [minor] Possibly incorrect maker notes
> offsets (fix by -628?)
>
> Using ExifTool's -htmldump option, it is easy to see how the meta data has
> been affected.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)