INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Image Rotation not working as expected  (Read 5383 times)

robydago

  • Citizen of the Universe
  • *****
  • Posts: 518
Image Rotation not working as expected
« on: June 29, 2008, 04:16:58 pm »

Hi,
I'm trying to use MC (12.0.518) to have all my pictures with the rotation tag set to 0 and physically rotated to the correct position.

Right now I have some images with rotation set (by the camera) to 90. I checked the same files with Vista and it sees Orientation (the equivalent of MC rotation I think) set to 90 as well. The big difference is that Vista displays the file correctly (using the orientation tag) orientated as portrait, MC not (it seems to ignore the rotation value and it shows the image as landscape)

Then I try to use MC on one of those images:
- I select the image and set the Rotation value to 0; MC rotates the image correctly
- I check in Vista and the Orientation value is still 90
- I force MC to write the changed Rotation to the file (using Update tags from library) and MC seems to do that (it tells "1 files updated (0 failures)")
- I check in Vista and the Orientation value is still 90 (??)
- I force MC to read tha tags from file (using Update library from tags) and MC reset rotation to 90 and the image is rotated to the wrong orientation again!! (back to where I started...)

Any ideas???

Ciao


Logged

robydago

  • Citizen of the Universe
  • *****
  • Posts: 518
Re: Image Rotation not working as expected
« Reply #1 on: June 30, 2008, 09:40:39 am »


Reading some posts, it seems that MC can read EXIF tags but not write them; judging by the "rotation" behavior I described, that seems to be the case.
Can anyone confirm?

But why is MC not using the rotation tag info to display the image correctly rotated? Is ignoring the rotation tag when displaying images by design?

Any chance to have one command added?
"Rotate according to Exif data (the actual image, with exif rotation reset to 0)"
It should be a command (like the current rotation commands) applied on demand to selected images.

Thanks a lot!
Ciao
Logged

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Image Rotation not working as expected
« Reply #2 on: June 30, 2008, 10:42:56 am »

I see similar bizarre rotation issues with MC.  If I have a picture in the library that should be "auto-rotated" to Portrait mode (because of the way I was holding the camera), MC will often incorrectly display these in landscape mode.

However, if I select them, and hit "Rotate Left" or "Rotate Right" (depending on which way I need to flip them), they'll jump 180 deg instead of only 90 deg (flipping the image to the other direction of Landscape view).  Then, I need to go one step back the opposite direction to get them to display properly.

Some pictures to illustrate my point:

First, an image that MC detected "wrong" and is incorrectly rotated.



I selected that image, clicked Rotate Left, and this is the result (a 180 deg change instead of the proper 90 deg change).



Finally, I clicked Rotate Right to get it fixed back the way it should have been.



It seems like MCs detection engine has improved, and it doesn't make the initial mistake as often anymore, but when it does (or when it already has with older pictures) this process is confusing.  Also, I should note, this has been true for a long, long time.  I've posted about it before but never got much traction.  Glad someone else noted it.

Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42344
  • Shoes gone again!
Re: Image Rotation not working as expected
« Reply #3 on: June 30, 2008, 10:47:59 am »

MC reads and writes EXIF rotation.  I've never seen a failure reading or using it, but if you have a file that fails in MC but works in other applications, please email it to matt at jriver dot com.

The double-rotate happens because if you do a lossless JPEG rotate, the image is physically rotated.  The rotation is also zeroed out in the database and EXIF tag.  This effectively causes a double-rotation.  This should probably be handled more elegantly.  For now, rotate again if you need to and everything will work in MC and any other program (since the EXIF rotation is zeroed out).
Logged
Matt Ashland, JRiver Media Center

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Image Rotation not working as expected
« Reply #4 on: June 30, 2008, 11:00:54 am »

All those shown in my above screenshots are all rotated properly automatically by Windows Explorer (and Adobe Lightroom and pretty much every other App).  Proof:



I can email them to you.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42344
  • Shoes gone again!
Re: Image Rotation not working as expected
« Reply #5 on: June 30, 2008, 11:14:20 am »

I can email them to you.

Please do.  Thanks.
Logged
Matt Ashland, JRiver Media Center

zirum

  • Galactic Citizen
  • ****
  • Posts: 403
  • still learning.
Re: Image Rotation not working as expected
« Reply #6 on: June 30, 2008, 11:49:42 pm »

I have had the same thing as Glynor. But it was mentioned as a "by-design" handle to double-rotate, so I did not bother to keep going about it. I would rather prefer to force rotate as desired, instead of what orientation it actually is in, and what is EXIF
Logged
Note to myself: Read, think, write - Read, think, write - think, read, write - think, write, read - think, write, read... Aahhw, i always mess that up...

jimn

  • World Citizen
  • ***
  • Posts: 131
  • You are getting sleepy...very sleepy...
Re: Image Rotation not working as expected
« Reply #7 on: July 01, 2008, 03:06:24 pm »

All those shown in my above screenshots are all rotated properly automatically by Windows Explorer (and Adobe Lightroom and pretty much every other App).

I can email them to you.

Hi Glynor,

The pictures you emailed showed up sideways (except for the one you marked "corrected") in MC, and also in Adobe Photoshop Elements 5, because both programs are using the EXIF rotation value (270) to correct the orientation. Windows Explorer Preview, both XP & Vista, show the pictures vertically, which LOOKS correct, because it appears to be ignoring the EXIF orientation.

By comparison, we looked at a picture that also had a EXIF orientation value (90 or 270), in that case MC and Adobe both showed the correct orientation, while Windows Explorer Preview (XP & Vista) showed it sideways, verifying that the two programs are adjusting to the EXIF orientation value while Windows is not.

I'm told that the problem that occurs during the first rotation adjustment in MC over adjusts--requiring a second adjustment--still exists. Perhaps this is the source of the discrepancy.

JimN
Logged

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Image Rotation not working as expected
« Reply #8 on: July 01, 2008, 03:15:16 pm »

The pictures you emailed showed up sideways (except for the one you marked "corrected") in MC, and also in Adobe Photoshop Elements 5, because both programs are using the EXIF rotation value (270) to correct the orientation. Windows Explorer Preview, both XP & Vista, show the pictures vertically, which LOOKS correct, because it appears to be ignoring the EXIF orientation.

By comparison, we looked at a picture that also had a EXIF orientation value (90 or 270), in that case MC and Adobe both showed the correct orientation, while Windows Explorer Preview (XP & Vista) showed it sideways, verifying that the two programs are adjusting to the EXIF orientation value while Windows is not.

I'm told that the problem that occurs during the first rotation adjustment in MC over adjusts--requiring a second adjustment--still exists. Perhaps this is the source of the discrepancy.

All I know is this:

1. Those pictures were taken with a Canon S50 camera.  Same thing happens with our higher-end Canon DSLR cameras (I'm not positive about the new ones, but the older 20D exhibited the problem).

2. Those pictures were not modified in any way by another application since being taken.  They were imported into MC as-is.

3. Windows Explorer shows the pictures correctly by default.   So does the Windows Picture and Fax viewer.

4. MC does not.

5. MC rotates them weirdly, forcing me to do two rotations EVERY TIME I want to fix one of them (as illustrated above).

6. Adobe Lightroom and Photoshop don't display them right by default, but at least they don't have trouble rotating them (one click solves it).  It seems like MC is stuck somewhere half-way in-between.

7. Other "portrait mode" pictures taken with the exact same camera (perhaps facing the "other way" still in portrait mode?) work just fine with MC -- they automatically show the correct orientation, and automatically rotate "properly" if I click the left or right button.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42344
  • Shoes gone again!
Re: Image Rotation not working as expected
« Reply #9 on: July 01, 2008, 03:43:22 pm »

I know from personal experience that a Canon 300D, 400D, and 450D rotate correctly with Media Center.  Windows XP (and Vista) gets it wrong.  Adobe gets it right, like you mentioned.

Quote
but at least they don't have trouble rotating them (one click solves it)

Double-rotation will be fixed in a future build.
Logged
Matt Ashland, JRiver Media Center

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Image Rotation not working as expected
« Reply #10 on: July 01, 2008, 04:10:27 pm »

I know from personal experience that a Canon 300D, 400D, and 450D rotate correctly with Media Center.  WindowsXP (and Vista) get it wrong.  Adobe gets it right, like you mentioned.

Double-rotation will be fixed in a future build.

Cool.  I'll have to check with our 5D later on.  Still weird that sometimes it "works" with my S50 and sometimes it doesn't.  Not sure what the difference is, but it'd be neat to try to figure it out.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

jimn

  • World Citizen
  • ***
  • Posts: 131
  • You are getting sleepy...very sleepy...
Re: Image Rotation not working as expected
« Reply #11 on: July 01, 2008, 04:27:56 pm »


7. Other "portrait mode" pictures taken with the exact same camera (perhaps facing the "other way" still in portrait mode?) work just fine with MC -- they automatically show the correct orientation, and automatically rotate "properly" if I click the left or right button.

Does your S50 have two "portrait modes"? From some quick research I found there are two methods of auto-rotation; actual rotation, and just marking the EXIF rotation value for display. I understand most cameras do the latter as doing on the fly conversion of x-y inside the camera is technically difficult. Maybe your camera can switch between actual and pseudo.

JimN
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42344
  • Shoes gone again!
Re: Image Rotation not working as expected
« Reply #12 on: July 01, 2008, 05:31:17 pm »

Does your S50 have two "portrait modes"? From some quick research I found there are two methods of auto-rotation; actual rotation, and just marking the EXIF rotation value for display. I understand most cameras do the latter as doing on the fly conversion of x-y inside the camera is technically difficult. Maybe your camera can switch between actual and pseudo.

JimN

But if it did actual rotation, I'd expect it to set the EXIF rotation to zero.  Otherwise it'd confuse programs like Adobe and us.

It almost seems like something rotated some of your images (i.e. lossless JPEG rotate) but didn't update the EXIF tags.

Anyway, please let us know more as you learn more.
Logged
Matt Ashland, JRiver Media Center

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Image Rotation not working as expected
« Reply #13 on: July 01, 2008, 06:54:32 pm »

Did perhaps some rogue version of MC once do this?  I'm pretty sure that I haven't used much other than MC to download or manage my pictures for QUITE some time.  Most of these pictures that I see "wrongly rotated" are old ones though, so I'm wondering if some old version of MC might have done things this "wrong" way for a time...

The only other app I even briefly used in the past to mess with my pictures (management wise) was Adobe Photoshop Express.  I do now occasionally Adobe Lightroom, but I usually still import all my pictures from the card using MC.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42344
  • Shoes gone again!
Re: Image Rotation not working as expected
« Reply #14 on: July 01, 2008, 07:10:47 pm »

Did perhaps some rogue version of MC once do this?  I'm pretty sure that I haven't used much other than MC to download or manage my pictures for QUITE some time.  Most of these pictures that I see "wrongly rotated" are old ones though, so I'm wondering if some old version of MC might have done things this "wrong" way for a time...

Yes, unfortunately.  Lossless JPEG rotation did not clear the EXIF rotation when it was first introduced.  I think this was because the player didn't use EXIF rotation back then.  This was changed for the better maybe two years ago, but it could create some legacy pains.  Sorry.

The good news is that if you rotate now until they're the right way up, you're set.  The rotate is lossless and the EXIF rotation is set to zero.
Logged
Matt Ashland, JRiver Media Center

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Image Rotation not working as expected
« Reply #15 on: July 01, 2008, 07:40:59 pm »

Yes, unfortunately.  Lossless JPEG rotation did not clear the EXIF rotation when it was first introduced.  I think this was because the player didn't use EXIF rotation back then.  This was changed for the better maybe two years ago, but it could create some legacy pains.  Sorry.

The good news is that if you rotate now until they're the right way up, you're set.  The rotate is lossless and the EXIF rotation is set to zero.

That's what it is then.  Those pics are, as you can see in the screenies, from Feb 2006.  I have lots, but I'll live.

UPDATE NOTE: I never really bothered to investigate exactly what was similar among all the ones that were messed up.  In many of my photo "views" (which aren't always date driven) they were spread all around.  Makes sense now that I look at them in a date-driven view, as they're all old ones from around that same era.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

robydago

  • Citizen of the Universe
  • *****
  • Posts: 518
Re: Image Rotation not working as expected
« Reply #16 on: July 04, 2008, 03:46:44 pm »

MC reads and writes EXIF rotation.  I've never seen a failure reading or using it, but if you have a file that fails in MC but works in other applications, please email it to matt at jriver dot com.

Matt,
I have some files that I can easily rotate with XnView (and it sets the orientation tag to 0), while in MC whatever value I set Rotation to doesn't seem to get saved to the file itself.
Can I send one file to you?

Ciao,
Roberto
Logged

robydago

  • Citizen of the Universe
  • *****
  • Posts: 518
Re: Image Rotation not working as expected
« Reply #17 on: October 28, 2008, 03:26:16 pm »

*bump*

using MC13.0.62 and I still have the same problem: the rotation field doesn't get saved to file


Logged

robydago

  • Citizen of the Universe
  • *****
  • Posts: 518
Re: Image Rotation not working as expected
« Reply #18 on: October 31, 2008, 06:10:35 pm »

*bump*

using MC13.0.62 and I still have the same problem: the rotation field doesn't get saved to file

it turned out there was no need to bump: problem solved
http://yabb.jriver.com/interact/index.php?topic=48905.0
Logged
Pages: [1]   Go Up