Anybody else having trouble with image rotation in 5.7.2?

Started by Panther, September 24, 2016, 11:10:25 PM

Previous topic - Next topic

Panther

Just updated from 5.6.22 to 5.7.2, and ran into a problem.

I have several images that were scanned up and down (too wide to fit the scanner if done horizontally).  When I try to rotate them using the iMatch command menu (Commands/Image/Orientation (EXIF)/Rotate 270 CW) it goes through the motions, changes the metadata tag, but the image in the QuickView window doesn't change - it still shows it vertical as it did before I did the command.

This seemed to work fine on similar images just a few days ago in version 5.6.22 - has something changed in how 5.7.2 handles rotation?  I tried it on several files with 5.7.2 and got the same unsuccessful result each time - I turned on the output window for my last test, and have attached a text file with the results pasted in.

Anybody else having issues with this?

Mario

No change in rotation handling in the 5.7.2 release.

Does the EXIF orientation metadata tag change to match your setting?
You can see it in the Metadata Panel using the Browser mode or by adding it to your Metadata Panel layout.

Which file format are you working with?

Does a forced rescan of the file (Shift+Ctrl+F5) cause any change?
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

Panther

Quote from: Mario on September 25, 2016, 07:50:35 AM
No change in rotation handling in the 5.7.2 release.

Does the EXIF orientation metadata tag change to match your setting?
You can see it in the Metadata Panel using the Browser mode or by adding it to your Metadata Panel layout.

Which file format are you working with?

Does a forced rescan of the file (Shift+Ctrl+F5) cause any change?

Yes, I can see the orientation tag change in the metadata panel (I've got it added to my panel), and it changes to my selection in the command (270 CW).  I'm working with .tif files.

I'll have to go back offline and try the forced rescan idea - will let you know.

[EDIT] - well, the forced rescan did make the image display properly in the Quick View window, but in most cases the thumbnail image in the main file window (not sure what that window is actually called) still shows the image un-rotated.  But I tried it on a few files and sometimes the thumbnail in the main file window did rotate appropriately (and IIRC it always rotated the thumbnails when I did this in 5.6.22).  I never had to do these rescans when I was doing this in 5.6.22 - it just worked.  Something is different, just not sure what.

Mario

My revision control systems shows no changes in this area and related functions for a long time.
Do you use a WIC codec to process TIFF files perhaps?
Maybe send me a TIFF file which exhibits the problem so I can test it there. https://www.photools.com/support

-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

Panther

Quote from: Mario on September 25, 2016, 09:22:39 PM
My revision control systems shows no changes in this area and related functions for a long time.
Do you use a WIC codec to process TIFF files perhaps?

I have no idea - I've seen some references to WIC codecs in some other posts around here, but I've never done anything purposeful to try to load or change anything like that.  Other than normal Win 10 stuff, the only image program I have on this PC is an old copy of PhotoShop - it's been installed for several years (since before I updated this PC to Win 10) and I haven't changed anything about it for years - certainly nothing changed since it was working in 5.6.22 a few days ago.


Quote from: Mario on September 25, 2016, 09:22:39 PM
Maybe send me a TIFF file which exhibits the problem so I can test it there. https://www.photools.com/support

OK - I'll have to go offline and get the file but will send it there later tonight.


Thanks for the help!

[EDIT] - I've sent one of the files via e-mail as you suggested.  It's 20 MB (zipped), but it said that it sent OK - if there was a problem please let me know and I can upload it to MediaFire and send you a link.

Mario

The image shows up correctly oriented in both the file window and the quick view panel / Viewer.
The Rotate by 270° orientation is both in the EXIF and the corresponding XMP tag.
Looks OK to me.

I assume this is the image _after_ you have already changed the orientation? You should have probably sent me the one _before_ you changed the orientation.

I tried to reproduce the effect by rotating the image back (Command > Image > Orientation (EXIF) > Neutral.
The image rotates back to the default (wrong orientation) and both the image in the Quick View and also thumbnail in the file window update.
OK.

Fix the orientation (270° clock-wise).
Thumbnail and QuickView image update correctly.
OK.

This must be something specific to your system. I have no idea where to look.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

Panther

OK - thanks for trying.

Yes, that is the file after I already tried rotating it and spotted the problem.  If I can find an old copy of the file from before that, I'll e-mail it to you.  But first I'm going to fire up 5.6.22 again and see what it does with that same file, just to check my recollection (also, I did it in that version with several files, but maybe not that specific one).


[EDIT] well, it turns out it's not as easy to run 5.6.22 after updating to 5.7.2 as I'd hoped.  I thought I could just run an old backup copy, but I guess I have to uninstall 5.7.2 first (I thought I'd maybe seen an old thread to that effect before but wasn't sure).  That seemed like overkill for the moment, so I just e-mailed you a copy of the file from before I tried to rotate it.

Probably not a big deal, and if it's just happening to me then I know there's not much you can or should try to do about it  - I just hate this sort of unpredictability because it always makes me wonder what else might be going wrong that I haven't discovered yet :(


Mario

I have tried to reproduce this here with your original file.

After adding the file to a database, I rotated it by 270° CW using Commands > Image > EXIF Orientation.
Metadata is updated correctly. Display rotates accordingly in both the file window (thumbnail) and Quick View Panel / Viewer.

I can see no problem, not with the original an not with the already modified file.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

Panther

Thanks for checking.  I'll keep trying to figure out what's going wrong on my machine.


Panther

OK - I'm out of ideas.  All kinds of weird stuff is happening with trying to rotate my .tif images and I can't figure out what is going wrong or what I need to do to try to fix it. 

As shown on the attached screenshots, I started with two images that were scanned vertically (because they were two long to fit sideways on the scanner bed), and both needed to be rotated 90 degrees CCW to display properly horizontally.

Since there is no choice for 90 CCW in the menu for Command > Image > Orientation (EXIF), I selected the one for 270 CW.  With the first image file (an envelope), it appeared to work - the thumbnail in the main file window and the image in the quickview window both rotated to the proper orientation (see first attached screenshot). 

With the second image file however, the thumbnail in the main file windows rotated properly but the image in the quickview window wound up upside down (see second attached screenshot).  I tried putting the rotation back to normal and a few other choices, hoping to somehow reset things, but I can't get the image in the quickview window to stop being upside down.

And then it gets weirder - when I open up the files in the Windows photo viewer, both of the files display in their original orientation (i.e., still incorrectly rotated 90 CW). (See 3rd and 4th attached screenshots)

Only thing I can think of is maybe there's some other set of metadata tags/info in these files that is conflicting somehow with the EXIF ones the orientation command in iMatch is trying to use, and that maybe I have to find and clear them out somehow, but I'm so confused about what's happening here that I don't even know where to start looking for potentially conflicting tags or how to keep this from happening again.

I know Mario was unable to replicate or find a problem here, so I don't want to ask him to spend any more time on it at this point.   Can anyone else provide any tips that might put me on the right track for setting this straight?

Mario

Does your scanner software maybe create multi-page TIFF files?
Storing the same image at different resolutions?

Did you try to open the file in your image editor and just save it once?
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

Panther

Quote from: Mario on October 02, 2016, 08:13:58 PM
Does your scanner software maybe create multi-page TIFF files?
Storing the same image at different resolutions?

Did you try to open the file in your image editor and just save it once?

As far as the scanner software goes, I scanned another couple of test images and didn't see anything in that process that looked like it was creating "multi-page TIFF files" or "Storing the same image at different resolutions" - it looked the same as it did with all the other couple of thousand .tif files I'd already scanned into the database, and I didn't see any settings or options that would tell it to do either of those things (I'm just using the scanner driver program (Canon MP Navigator EX 3.1) that came with the scanner - a CanoScan 9000F).

I did try opening the files with PhotoShop and just saving a copy down as a .tif file with no changes - had no effect.

The results are still spotty - not consistent.  I used new copies of the original files (before I changed anything in iMatch with my previous tests) and put them in my test database.  This time, the envelope file didn't display properly in the quickview window but the other one did.  (But after a couple of times closing and re-opening iMatch both files now displayed the right way in the quickview window).  But again, neither file displayed as having been rotated in Windows file manager or Photoviewer - they still displayed in their original (vertical) format.

Then it got weirder - I put the two new test images I just scanned into my test database, and neither one of them rotated in either the main file (thumbnail) window or in the quickview window after I gave them the command to rotate, even after closing and re-opening iMatch a couple of times.  The orientation tag in the metadata panel shows that it has been changed to 270 CW, but the displays in iMatch didn't change.

I tried taking another copy of the envelope image file and rotating it in PhotoShop and saving it back down as a copy - that one actually displays correctly in both iMatch (without needing to do any rotation command in iMatch) and in Windows file manager and Photoviewer.

I was really hoping to be able to use iMatch to do these rotations because it would be so much easier for a workflow, but if I can't get it to work reliably (for whatever reason) I guess I'll have to figure out a workflow to do this in PhotoShop.  (Guess I'll also have to do some research to make sure doing the rotation in PhotoShop isn't degrading the image somehow).

The rotation commands in iMatch seem to have worked more reliably (for me) with the .jpg files from some of our cameras than it has for these .tif files, and there are way more of those .jpg files that need rotating than there are .tif files that need it, so maybe I'll still be able to use iMatch for the bulk of these rotations - will have to do some more runs to test that theory.

[EDIT] - I ran some more tests, and it does seem that this erratic rotation behavior is likely to be related to the .tif files rather than the .jpg files.  I picked 4 random photos from one of our cameras (.jpg files that were vertical when they should have been horizontal) and added them to my test database.  When I told iMatch to rotate them (3 of them 90 CW, one 270 CW) the images displayed correctly rotated in both the main file/thumbnail window and the Quickview window, and also displayed properly in Windows file manager and Photoviewer (after closing iMatch). 

I also took new copies of the same 4 files and used PhotoShop to save them down as .tif files (making no changes to them), and added them to the database.  Two of them appeared to rotate correctly in iMatch's two windows, but the other two did not (although forcing a rescan seemed to solve the issues with those two in the iMatch quickview window), and all 4 of the .tif file versions displayed in their original, un-rotated orientation in Windows file manager and Photoviewer (after closing iMatch).

Is there maybe some issue with the WIC thing in Windows for .tif files or something else along that line that might be the culprit here?

Mario

All the files you did send me so far showed up correctly in IMatch. Rotation also worked.
Unless you can send me a file which really produces the behavior you are describing, I'm at a loss.

TIFF files may contain multiple pages. IMatch always uses page 0 (first page) in the file. When you look at one of your files in the ExifTool Command Processor, you may be able to find something out, e.g. multiple pages, different orientation settings etc.

Do you have a WIC codec installed which handles TIF files? If so, which? Do you use FastPictureViewer codecs? If so, note that these have an option to "auto-rotate" images based on the EXIF orientation. That's meant for dumb applications which don't handle EXIF-based rotation themselves. If the FPV codec auto rotates the image, IMatch receives the already rotated image, but the EXIF orientation data will still be the original data (not adjusted). This may cause double-rotation.

Adobe products don't use WIC codecs, so you will get different results in that case.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

Panther

Quote from: Mario on October 03, 2016, 09:16:23 AM
All the files you did send me so far showed up correctly in IMatch. Rotation also worked.
Unless you can send me a file which really produces the behavior you are describing, I'm at a loss.

When you look at the files I sent you (that work OK inside iMatch) in Windows Explorer/Photoviewer, do they appear rotated correctly or are they still in their original vertical orientation? 

Quote from: Mario on October 03, 2016, 09:16:23 AM
TIFF files may contain multiple pages. IMatch always uses page 0 (first page) in the file. When you look at one of your files in the ExifTool Command Processor, you may be able to find something out, e.g. multiple pages, different orientation settings etc.

I noted when looking at the output from the ExifTool Command Processor that there was one line that reads:

[IFD0]          Subfile Type                    : Single page of multi-page image

I don't know why it thinks this was ever a "multi-page image" or where the rest of the "multi-pages" might be, but I'll run some tests with my scanner again to see if I can figure anything out.

I also noted 2 different lines/tags relating to orientation, but they both appear to be set the way I would expect (i.e., "Horizontal (normal)" before I told iMatch to rotate them, and "Rotate 270 CW" afterwards.

Quote from: Mario on October 03, 2016, 09:16:23 AM
Do you have a WIC codec installed which handles TIF files? If so, which? Do you use FastPictureViewer codecs? If so, note that these have an option to "auto-rotate" images based on the EXIF orientation. That's meant for dumb applications which don't handle EXIF-based rotation themselves. If the FPV codec auto rotates the image, IMatch receives the already rotated image, but the EXIF orientation data will still be the original data (not adjusted). This may cause double-rotation.

Adobe products don't use WIC codecs, so you will get different results in that case.

How do I find out whether I have any particular WIC (or other) codecs installed?  As I indicated before, I've never knowingly installed anything like that and wouldn't know where to look, but I can't be sure something I might have experimented with over the last few years might have installed something without me realizing it.  I'll do some research and see if I can figure out what codecs might be on this machine, but any clues about where/how to look for them would be helpful.

Thanks for the time and attention - I know you've got a lot of more important stuff going on so I really appreciate it!

Mario

Both files show up rotated to the right in Windows Explorer. Windows Explorer is not really good at interpreting EXIF orientation.
Windows 10 photo viewer also does it wrong. Microsoft will never learn.

IMatch shows the original file rotated to the right (correct, because of neutral EXIF orientation).
IMatch shows the "modified in IMatch" file rotated to the left by 90° (correct, because of the change you did to the EXIF orientation).

Photoshop shows the file in the same orientation as IMatch.
It respects the EXIF orientation tag and so the results must be the same as in IMatch.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

Panther

OK - I am using Win 10, so if the Win 10 Photoviewer and Windows Explorer have problems then that probably explains why that isn't working like I would have expected.

Still not sure why iMatch itself seems to be having problems (sporadically) displaying the images properly rotated in one or both windows, and apparently (so far at least) only with the .tif files and not the .jpg files, but maybe it has something to do with how my scanner is saving the .tif files.   I still have to run some more experiments to see what that "multi-page tiff" thing that the ExifTool Command Processor found is all about and why that info is present when I haven't found any setting or indication (yet) that would indicate why the scanner would be trying to save the files as "multi page" anything.

I wonder if maybe there is a better scanning software I ought to be using instead of just using the scanner driver thing that came with the scanner - maybe I'll experiment with just scanning directly into PhotoShop (if that's possible), where I guess I could also go ahead and rotate the image before I even add it to the database.

[EDIT] - interesting - just used PhotoShop to scan something directly, rotated it and then saved it down as a .tif file - of course it worked just fine in iMatch (and in Windows Explorer and Photoviewer), and when I checked the output of the ExifTool Command Processor tool it did not show anything about being a multi-page tiff file, just a "full resolution image".  I guess that will be my new workflow for my scanning, unless it turns out that PhotoShop is somehow degrading the image when it rotates it after scanning and before saving as a .tif file - I don't think it is, but I'll have to do some research to see if I can find any confirmation of that one way or the other.

ubacher

Just curious about the multi layer tiff file.
(Wasn't there once an issue with Obama's birth certificate? I remember that there was
a multi-layer file involved which was then interpreted by some as evidence that the file was
doctored when it actually came this way from a scanner.)

I think Irfanview (popular, free viewer) lets you view the different layers.
Have not tried it with tif files, only with .MPO files.

In photoshop: I would think the different layers would show in the layers palette???
Did you try looking at this?

Panther

Just opened one of the files in PhotoShop that the ExifTool Command Processor reported as a "single page of multi-page tiff file", but there are no extra layers or anything odd showing up in PhotoShop. 

Still running tests with the scanner to see what it might be doing to make ExifTool Command Processor think there were multiple pages.

Erik

A multi-paged tiff is not the same thing as a multi-layered tiff. 

I'm pretty sure that a multi-paged tiff (not 100% sure) is more liked a PDF file, i.e. with multiple pages.  In fact, if you were to have any chance at seeing the pages, I would think you would need a PDF viewer (that can view Tiff files).  I know the full fledged Acrobat can (not something many here would buy).  I'm not sure if Acrobat Reader can (freeware). 

You might google around and ask the question how to open a multi-paged tiff.

A multi-layered tiff is one image with multiple layers (like a PSD file). 

As for your scanner, it very well may be that it is scanning your document as if it is a document rather than an image.  Actually, if your scanner comes with a viewer, you might be able to see what is happening.  I suspect that your scanner may actually be scanning with the expectation that there would be multiple pages and putting in the header/container for multiple pages, even if there is just one page.

Someone else with more knowledge on the different formats might know how it works. 

As for scanning software, if it works in Photoshop, it's probably fine.  There are specific scanning software, some that are open source, that are known to be quite good.  I don't scan often, so I don't remember what's out there, but again you might use Google to look around (if it's of interest to you).  Some of the software will automate some features of the whole process that Photoshop probably wouldn't (cleaning up dust marks, scratches, etc).

jch2103

Quote from: Panther on October 05, 2016, 02:19:30 AM
I wonder if maybe there is a better scanning software I ought to be using instead of just using the scanner driver thing that came with the scanner - maybe I'll experiment with just scanning directly into PhotoShop (if that's possible), where I guess I could also go ahead and rotate the image before I even add it to the database.

Look at VueScan https://www.hamrick.com/ for probably the best/most flexible scanning software available. It's constantly updated and supports hundreds of scanner models. It also runs on multiple OS versions.
John

Panther

Thanks for the tips about possible scanning software.  I'm just scanning old photos and documents and cataloging them in iMatch, and I'm not doing any editing/cleaning or anything to the scanned images (I figure I can always come back and fix things later if I feel like it), so scanning into PhotoShop just to avoid this weird multi-page tiff thing probably will work for me.  My wife though is doing a lot of scanning from slides and negatives, where she is doing some dust removal or other touch-up stuff as part of the process, so we may take a look at some of those scanning software alternatives for her workflow.

hro

I have been using VueScan for many years now, having scanned some 6,000 slides with it on an Epson Perfection V750 flatbed scanner. Before starting this project I tried the Epson scan software as well as SilverFast. I felt VueScan gave me the most control and the best results. The interface is a bit quirky and you have to get used to it, but nothing compared to SilverFast which I feel is just horrible.

VueScan can deal with image rotation, multi page tiff of PDF without problem. It can now even create 'raw' files that can be loaded again into VueScan at a later time and processed as if the image were just scanned.

Panther

Well, that didn't go well  :(

D/L'ed and installed the trial version of VueScan, it found and recognized my Canon 9000F scanner, and everything looked good until I pressed "Preview".  All it does every time I press either Preview or Scan is to go through an endless cycle of "Warmup lamp...0%" - it ticks on up to 100% after a couple of minutes, and then ... nothing happens.  If I press "Preview" or "scan" again, the same thing repeats itself over again.

Tried doing some Google searches but got tired of wading through the results that were trying to sell me scanners or talk about warming up lamps in scanners generally, without regard to this specific situation with VueScan.  I get the idea that warming up the lamp is probably a good idea, although using Canon's own scanner software it never seemed to bother with the concept - if I wanted to, I could start scanning as soon as I turned the thing on (I would usually wait a while to let things warm up if I was scanning some images I cared about, but when I was just making a copy of something or scanning a document I was just going to e-mail or something, I just launched right in).

After 15 minutes or so of seeing VueScan think it needed to warm up the lamp, I'm pretty sure it's just not working.  Too bad, too - it looked pretty interesting and I was planning to buy the thing since it allowed use on 4 computers and my wife doesn't seem all that impressed with the software that came with her new Epson scanner, but if I can't get the trial version working I'm sure not going to plunk down money for the paid version.  Bummer.

[EDIT] well, that was weird.  Shut down VueScan and fired it up again, just for grins, and this time it cranked right up and gave me a preview scan in short order.  Not sure what that was all about, but hopefully just some minor glitch in the way it launches right after the install process.

hro

Sorry to hear.
Did you contact VueScan directly, that is what I would do first?
Every scanner need to warm up first so that the light source will have the correct colour temperature. However, this should only take 1/2 minute or so when you first start it up.
I never had a problem with VueScan as you have described it. Perhaps read the essential manual stuff about how to connect VueScan with the scanner. I know there are various otptions, just can't remember them now (away from my home machine).

Good luck, certainly worthwhile a try.

jch2103

Quote from: Panther on October 06, 2016, 01:29:57 AM
[EDIT] well, that was weird.  Shut down VueScan and fired it up again, just for grins, and this time it cranked right up and gave me a preview scan in short order.  Not sure what that was all about, but hopefully just some minor glitch in the way it launches right after the install process.

Glad to hear it's working properly for you now. That behavior I haven't encountered from VueScan, but I have had occasional glitches from installs of other programs that go away after a restart/reboot.
John