Last modified: 2011-10-12 14:14:06 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 31637 - MediaWiki uses XMP data in addition to IFD0:Orientation to determine orientation
MediaWiki uses XMP data in addition to IFD0:Orientation to determine orientation
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
File management (Other open bugs)
1.18.x
All All
: Unprioritized normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks: 31504
  Show dependency treegraph
 
Reported: 2011-10-12 02:35 UTC by Saibo
Modified: 2011-10-12 14:14 UTC (History)
3 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Saibo 2011-10-12 02:35:57 UTC
( Similar to Bug #31487 )


[[:commons:File:David_Andrew_Jenkins_and_XAPP.jpg]] had (according to ExifTool) XMP-tiff:Orientation set to 8.   XMP is IPTC Core (Adobe XMP)

Bug: Apparently Mediawiki uses not only IFD0:Orientation (contrary to  https://bugzilla.wikimedia.org/show_bug.cgi?id=31504#c8 )
 
Btw: The image viewer gThumb which also rotates images based on EXIF info didn't rotate the image (correct).


own testcase...  http://commons.wikimedia.org/wiki/File:AXMPtiffbeach.jpg with no EXIF data but the XMP-tiff:Orientation tag copyied over from [[:commons:File:David_Andrew_Jenkins_and_XAPP.jpg]] 
Expected: the image shows up in its physical orientation (that is 90° CW). 
Observed: 180°CW as MW applies apparently rotation based on the Orientation tag.

Reason: Either Mediawiki uses not only IFD0:Orientation (contrary to  https://bugzilla.wikimedia.org/show_bug.cgi?id=31504#c8 ) or Exiftool and https://addons.mozilla.org/de/firefox/addon/exif-viewer/ do something really wrong here since they say that the image has no EXIF.

Problem: As we now use exiftool to read the IFD0-Orientation tag to be able to rotate images according to user expectations this breaks Rotatebot in Commons.
Comment 1 Bawolff (Brian Wolff) 2011-10-12 12:58:16 UTC
MediaWiki will use Orientation information from XMP as well (Specifically, the orientation tag in the http://ns.adobe.com/tiff/1.0/ namespace. The http://ns.adobe.com/tiff/1.0/ namespace in XMP is for encoding exif information in XMP form). If there is a conflict between the XMP tiff:Orientation and the Exif Orientation tag in ifd0, the tag in IFD0 takes priority.

I'm unsure if the current behaviour is correct or should be changed.
Comment 2 Saibo 2011-10-12 13:22:34 UTC
Thanks. But: Hmpf! .. that gets really complicated... That EXIF-based rotation deployment is throughout a failure. Not even the devs know what really happens - apparently. :-(

Should we adjust Rotatebot now to also take XMP into account or will this be removed in MediaWiki?
Comment 3 Bawolff (Brian Wolff) 2011-10-12 13:45:23 UTC
> 
> Should we adjust Rotatebot now to also take XMP into account or will this be
> removed in MediaWiki?

Well in theory, if you're rotating something, you should adjust all the rotation tags for complete correctness. Adjusting the XMP will never hurt anything

As for if using XMP's tiff:Orientation should be removed from MediaWiki - Good question. I don't know what the correct thing to do here is?
Comment 4 Saibo 2011-10-12 14:12:55 UTC
half off topic - 
(In reply to comment #3)
Bawolf: "Well in theory, if you're rotating something, you should adjust all the rotation tags for complete correctness." 
(as written in IRC) There is just a minor problem: How should I know and understand any metadata format which could be used?  I guess there are many more. I could strip all except jpeg data. But this would make users very unhappy.
Comment 5 Bawolff (Brian Wolff) 2011-10-12 14:14:06 UTC
I've disabled extracting tiff:Orientation in r99632

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


Navigation
Links