[sane-devel] Re: gamma correction procedure

Frank Peters frank.peters at comcast.net
Thu Feb 26 18:00:48 GMT 2004


On Thu, 26 Feb 2004 17:39:33 +0100
Stefan Schlörholz <stefan at schloerholz.de> wrote:

> 
> sorry I forgot to mention that I collected some information about ICM on 
> the net allready. I am aware of the fact that the difference in Linux 
> scans and Windows scan is due to the fact that the Scanner manufacturer 
> provided a frontend to scan a reference slide, which also was packaged 
> with the scanner, and that the so obtained profile is automatically is 
> applied to the scan.
>  
> Do you think the slide provided by the scanner manufacturer will do 
> also?
> 

Every calibration target or slide must have with it a reference file
that contains accurate color data obtained when the target or slide was
created.  This reference information is compared to the data obtained
from a scanned image to produce the scanner profile.

If you also have the reference file, a text file in IT8 format, than you
can certainly use the target slide that is supplied by the manufacturer.


>
> Scanner Space ------------------------> Printing Space
> >                   scanner profile
> >                   printer profile
> 
> But if I understand correctly this printer profile is different to the 
> printer profile needed to convert from monitor to printer, right?
> 

No.  A printer profile is specific to a certain printer (and the paper
type on this printer) and can be used in all conversions to the printer
space from any other color space.  In other words, only a single printer
profile is needed to convert from scanner to printer or from monitor
to printer.

In more technical terms, all color space transformations involve an
intermediate universal color space:


Scanner space ----------------------------> Universal Color Space
                  scanner profile


Universal Color Space ----------------------------> Printer Space
                            printer profile


The key point is that because there are _different_ universal color spaces
(e.g. CIE XYZ, CIE LAB, etc.), it is only necessary that the two profiles
involved in any color transformation be related to the _same_ universal
color space.  As long as this is true, then the same printer profile
can be used for any kind of conversion.


> 
> This is a GUI to generate an ICM profile only? The conversion needs to 
> be done manually, e.g. using ImageMagick (IIRC) by passing the scan and 
> the profile to e.g. convert?
>

The Little CMS Profiler will generate an ICM profile.  It also includes
a command-line program called tifficc to apply (or embed) the profile
to (into) any image.

I don't use ImageMagick so I can't comment, but the man page indicates
that a profile can be embeded into an image using convert -profile.

> 
> Is there a chance to automatically have the ICM profile applied when 
> scanning automatically using xsane?
> 

I don't use xsane, so I can't comment on this.  But with bash scripting it
would certainly be possible to automate the process using scanimage.

scanimage is able to write to SDTOUT and can therefore be piped to other
programs from, for example, the NETPBM suite.

But I've never checked into the automation issue so I can't comment much.
Others on this list could probably address this more.

This page refers to some kind of automation: http://www.xach.com/photos/

Anyway, just to give some idea what the results can be, have a look at
http://www.kirchgessner.net/scarse.html.  The page is old but the examples
are still relevant.

Frank Peters




More information about the sane-devel mailing list