Bug 569564

Summary: Unable to calibrate scanner: tiff not recognized
Product: [Fedora] Fedora Reporter: Michael Monreal <michael.monreal>
Component: gnome-color-managerAssignee: Richard Hughes <richard>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 13CC: rhughes, richard
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-03-02 10:20:04 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Screenshot
none
tiff none

Description Michael Monreal 2010-03-01 17:57:55 UTC
Created attachment 397144 [details]
Screenshot

I scanned in my IT8 reference card and saved it as a tiff file, however gcm does not like the file and insists that it has to be "an RGB tiff file".

The tiff itself can be opened by other apps just fine and I don't see a way to tweak any settings in Xsane. Re-saving the image in gimp does not help.

Comment 1 Richard Hughes 2010-03-01 18:04:46 UTC
Can you attach the tiff file please. Thanks.

Comment 2 Michael Monreal 2010-03-01 18:12:02 UTC
Created attachment 397149 [details]
tiff

There's the tiff as saved by xsane. The scanner seems to be a bit broken and dusty (which explains the very bad quality) but that should not affect the basics I guess...

Comment 3 Michael Monreal 2010-03-01 18:13:51 UTC
FWIW I tried to scan with the gnome scanning tool first but a) it crashed every time and b) it didn't seem to offer saving as tiff at all, so I used the old xsane...

Comment 4 Richard Hughes 2010-03-02 10:20:04 UTC
The problem is that your TIFF file contains an alpha channel (RGBA) and isn't RGB, and the argyll tools are very strict on what formats they accept. I've added the following code to GCM git master to fix things up:

commit a3324e55ad5041f91b772c3dd9d49e872c44e8fe
Author: Richard Hughes <richard>
Date:   Tue Mar 2 10:17:26 2010 +0000

    Check and correct TIFF image files with alpha channels before using them in argyllcms. Fixes rh#569564

Could you please check with git master, and verify the bug is fixed (I generated a profile using your target image just fine a few minutes ago).

Thanks.

Comment 5 Michael Monreal 2010-03-02 15:50:05 UTC
Ah... well xsane always seems to save as rgba. After manually removing the alpha channel in gimp the calibration works. [I will test with HEAD on my next build]

Off-topic: when using the generated profile from xsane, it didn't seem to work with the icc profile because it contained spaces:

---
lcms: Error #12288; File '/home/mimox/.color/icc/GCM' not found
---

Xsane bug or lcms bug?

Comment 6 Richard Hughes 2010-03-02 18:37:36 UTC
(In reply to comment #5)
> Ah... well xsane always seems to save as rgba. After manually removing the
> alpha channel in gimp the calibration works. [I will test with HEAD on my next
> build]

Cool, thanks.

> Off-topic: when using the generated profile from xsane, it didn't seem to work
> with the icc profile because it contained spaces:

XSane bug. If you file it / fix it can you please cc me. Thanks.

Richard.

Comment 7 Michael Monreal 2010-03-04 10:22:20 UTC
I just tested the automatic conversion using the latest g-c-m and it seems to work. I just wonder if it is really necessary to display the intermediate "conversion" dialog. Is there anything that could go wrong here?

Comment 8 Richard Hughes 2010-03-04 11:06:29 UTC
(In reply to comment #7)
> Is there anything that could go wrong here?    

Yes. If the scanning software set the alpha to 0.5 to "correct brightness" without touching the RGB values and we just ripped it out, and the profile wouldn't be accurate. To be honest, I'm just covering my own back here.

Comment 9 Michael Monreal 2010-03-04 11:30:37 UTC
Ah, that's bad then... would be nice to finally have a working gnome-scan and be able to use it from gnome-color-manager directly...

Comment 10 Richard Hughes 2010-03-04 12:33:41 UTC
AFAIK, it's on the gnome-scan/easy-scan TODO list.