19.07.2014 Views

RGB & CMY(K)-Space Conversion between CMY and CMYK

RGB & CMY(K)-Space Conversion between CMY and CMYK

RGB & CMY(K)-Space Conversion between CMY and CMYK

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>RGB</strong> & <strong>CMY</strong>(K)-<strong>Space</strong><br />

•<strong>RGB</strong> = Red-Green-Blue<br />

Part 5: Reproduction Principles <strong>and</strong><br />

Related Color <strong>Space</strong>s<br />

• <strong>CMY</strong> = Cyan-Magenta-Yellow<br />

• <strong>CMY</strong>K = Cyan-Magenta-Yellow-Black<br />

<strong>RGB</strong> for reproduction on additive devices like monitors<br />

also used for cameras<br />

<strong>CMY</strong>(K) for subtractive devices like printers<br />

Basic color reproduction principles/Additive<br />

Additive Color Reproduction:<br />

Colors are created by adding outputs of<br />

three primaries (TV, Laser displays, …)<br />

Typical primaries: Red, Green, Blue<br />

Simple relation <strong>between</strong> <strong>RGB</strong> <strong>and</strong> <strong>CMY</strong><br />

⎛ C ⎞ ⎛1−<br />

R⎞<br />

⎜ ⎟ ⎜ ⎟<br />

• <strong>RGB</strong> -> <strong>CMY</strong>: ⎜M<br />

⎟ = ⎜1−G⎟<br />

⎜ ⎟ ⎜ ⎟<br />

⎝ Y ⎠ ⎝1−<br />

B⎠<br />

•<strong>CMY</strong> -> <strong>RGB</strong>:<br />

⎛ R⎞<br />

⎛1−C<br />

⎞<br />

⎜ ⎟ ⎜ ⎟<br />

⎜G⎟<br />

= ⎜1−<br />

M ⎟<br />

⎜ ⎟ ⎜ ⎟<br />

⎝ B⎠<br />

⎝ 1−Y<br />

⎠<br />

Basic color reproduction principles/Subtractive<br />

<strong>Conversion</strong> <strong>between</strong> <strong>CMY</strong> <strong>and</strong> <strong>CMY</strong>K<br />

• <strong>CMY</strong> -> <strong>CMY</strong>K:<br />

⎛min(<br />

C3,<br />

M 3,<br />

Y<br />

⎜<br />

⎛ K ⎞ C3<br />

− K<br />

⎜ ⎟ ⎜<br />

⎜ C ⎟ ⎜ −<br />

⎜ ⎟<br />

= ⎜ M −<br />

K 4 1<br />

3 K<br />

M 4<br />

⎜ ⎟ ⎜ 1−<br />

⎝ Y ⎠ ⎜ Y −<br />

K 4<br />

3 K<br />

⎜<br />

⎝ 1−<br />

K<br />

3)<br />

⎞<br />

⎟<br />

⎟<br />

⎟<br />

⎟<br />

⎟<br />

⎟<br />

⎟<br />

⎠<br />

BUT:<br />

In reality this is<br />

much more<br />

complicated!<br />

Subtractive Color Reproduction:<br />

Colors are created by subtraction of<br />

colors from underlying white (printing,…)<br />

Typical primaries: Cyan, Magenta, Yellow<br />

• <strong>CMY</strong>K -> <strong>CMY</strong><br />

⎛ C3<br />

⎞ ⎛ C4⋅(1<br />

− K)<br />

+ K ⎞<br />

⎜ ⎟ ⎜<br />

⎟<br />

⎜M<br />

3⎟<br />

= ⎜M<br />

4⋅(1<br />

− K)<br />

+ K⎟<br />

⎜ ⎟ ⎜<br />

⎟<br />

⎝ Y 3<br />

⎠ ⎝ Y 4⋅(1−<br />

K)<br />

+ K ⎠<br />

1


Device dependency<br />

Color Detectors (Cameras)<br />

Today mainly CCD cameras with:<br />

• one sensor array <strong>and</strong> <strong>RGB</strong>-filters<br />

The color represented by<br />

R, G, B, C, M, Y, K<br />

depend on the devices used,<br />

i.e the characteristics of the<br />

monitor channels, the camera or the inks<br />

•three sensor arrays with beam-splitter<br />

B<br />

E<br />

A<br />

M<br />

S<br />

P<br />

L<br />

I<br />

T<br />

T<br />

E<br />

R<br />

R<br />

G<br />

B<br />

Traditional photographic<br />

film<br />

(3-12+light sensitive layers)<br />

<strong>Conversion</strong> <strong>between</strong> <strong>RGB</strong> <strong>and</strong><br />

XYZ<br />

Foveon<br />

ITU-<strong>RGB</strong> 709 is a st<strong>and</strong>ard describing studio cameras<br />

(ITU = International Telecommunications Union)<br />

⎛ X ⎞ ⎛41.24<br />

⎜ ⎟ ⎜<br />

⎜ Y ⎟ = ⎜21.26<br />

⎜ ⎟ ⎜<br />

⎝ Z ⎠ ⎝ 1.93<br />

35.76<br />

71.52<br />

11.92<br />

18.05⎞⎛<br />

R⎞<br />

⎟⎜<br />

⎟<br />

7.22 ⎟⎜G⎟<br />

95.05<br />

⎟⎜<br />

⎟<br />

⎠⎝<br />

B⎠<br />

X,Y,Z system assumes D65 daylight<br />

Sony Cybershot DSC-F828<br />

Part 6: Some Color Measurement Devices<br />

<strong>RGB</strong><br />

<strong>RGB</strong>E<br />

2


New Trends- Multispectral<br />

Cameras<br />

EU project Crisatel:<br />

ENST Paris, Louvre, National Gallery …<br />

Linear CCD 12000 pixels<br />

Moving frame with 30000 lines<br />

Multispectral filters: 13 b<strong>and</strong>s<br />

Resolution: 16 bits/pixel<br />

File size: 9.4 Gb<br />

Product: http://www.jumboscan.com/<br />

Spectroradiometers PhotoResearch<br />

The PR-705 SpectraScan ® SpectraRadiometer ®<br />

Color Detectors (Densitometers)<br />

Used in scanners to compare the actual (transparency,<br />

reflectance)<br />

to the ideal (transparency, reflectance)<br />

Often optimised to objects (inks etc.)<br />

Spectrolino<br />

Amplifier<br />

Detector<br />

Probe<br />

Filter<br />

Source<br />

Measure with probe<br />

Compare to measurement without<br />

probe<br />

Characteristic of Status A densitometer<br />

Digital Cameras as Measurement Device<br />

Cheaper<br />

8-12M Measurements<br />

Needs calibration<br />

Expansive<br />

Needs experience<br />

Single Point Measurements<br />

http://www.diva-portal.org/diva/getDocument?urn_nbn_se_liu_diva-2667-1__fulltext.pdf<br />

Exjobb: Martin Solli: Filter characterization in digital cameras<br />

3


Computational Photography<br />

Color vocabulary<br />

• Hue: red-green-blue-yellow-etc<br />

• Brightness: how bright an object appears<br />

• Colorfulness: how much white is included<br />

• Lightness = normed brightness =<br />

Brightness/Brightness(White)<br />

• Chroma = normed<br />

Colorfulness=Colorfulness/Brightness(White)<br />

• Saturation=Colorfulness/Brightness<br />

• (un-)Related colors: unrelated color of an object belongs to<br />

an area independent of other colors<br />

Lightstage...<br />

Perception phenomena not h<strong>and</strong>led by<br />

colorimetry<br />

Simultaneous contrast:<br />

The color of a point depends not only on its physical spectrum<br />

but also on the background on which it is seen<br />

More simultaneous contrast<br />

Color perception depends on the whole configuration<br />

Part 7: More Color Vision<br />

4


Crispening<br />

Magnitude of color difference is larger if the<br />

stimuli are shown on background with color similar to the stimuli<br />

More effects<br />

1. Spreading: Small stimuli are fused (half-toning). Just above the limit<br />

there is a region where only the colors blend but where the objects are<br />

perceived as different<br />

2. Bezold-Brücke effect: Hue depends on luminance! Viewing<br />

monochromatic stimuli under different luminance changes the hue<br />

:<br />

3. Abney effect: Constant hue curves are not lines! Mixing monochromatic<br />

light with different amounts of white light changes the hue.<br />

4. Helmholtz-Kohlrausch effect: Brightness increases with saturation!<br />

Brightness depends on luminance <strong>and</strong> chrominance.<br />

5. Hunt effect: Increasing luminance leads to increasing colorfulness!<br />

6. Stevens effect: Contrast increases with luminance! With increasing<br />

luminance dark becomes darker <strong>and</strong> light becomes lighter<br />

Depth perception of red-blue<br />

The human eye (again)<br />

Red/Blue Text<br />

Blue text on a red background is hard to read<br />

Post-detection processes<br />

A) Connection <strong>between</strong> retina <strong>and</strong> brain is a bottleneck<br />

(Many more sensors than nerves to brain)<br />

Therefore compression is needed!<br />

Red text on a blue background is easier to read<br />

B) All cells involved adapt to changing conditions<br />

Black text on a white background is best<br />

Continued high stimulation<br />

Continued low stimulation<br />

lower sensitivity<br />

increasing sensitivity<br />

5


Spectral processing (opponent color coding)<br />

L<br />

BW<br />

M<br />

RG<br />

S<br />

YB<br />

Adaptation<br />

Human vision system adapts, it has a tendency to go back to<br />

a stable state<br />

Examples:<br />

General brightness adaptation<br />

Lateral brightness adaptation<br />

Chromatic adaptation<br />

…<br />

BW = L+M+S RG = L-M YB = S-M-L<br />

Spatial signal processing on the retina<br />

Single sensor signals from a region are combined<br />

General brightness adaptation<br />

Adaptation to overall light intensity<br />

absolute intensity influences contrast <strong>and</strong> colorfulness<br />

-<br />

+<br />

G-<br />

R+<br />

Prints appear different in indoor <strong>and</strong> outdoor conditions even<br />

if the viewer is adapted to the light conditions<br />

Other “Detectors”<br />

• Oriented Edges<br />

• Oriented Bars<br />

• Input from one/two eye(s), stereo<br />

• Spatial frequencies<br />

• Temporal frequencies<br />

• Combination of all these features<br />

Lateral brightness adaptation<br />

Brightness at a point depends also on response from neighboring<br />

points<br />

Glowing axes, stairs, crispening ….<br />

Practical application: Slides on a screen in a dark room appear<br />

different from the same image on a screen in daylight<br />

6


Hermann Grid<br />

Mean Normalization<br />

Compensate such that mean is constant.<br />

“Rotating Snake”<br />

Max Normalization<br />

Compensate such that the point with maximum intensity is white<br />

by Akiyoshi Kitaoka<br />

Chromatic adaptation<br />

Mean Result<br />

Longer stimulation of a channels decreases its sensitivity<br />

Demonstrated by different versions of the afterimage<br />

Von Kries adaptation = different scaling for different<br />

channels<br />

7


Scaling<br />

Compensation Scene 6<br />

mean-Kries<br />

white-Kries<br />

Multispectral Simulation<br />

<strong>RGB</strong> Compensation<br />

Some recent results<br />

Simulation Scene 8<br />

Input: Multi-spectral image with 31 channels<br />

Illumination: Planck Spectra<br />

Camera: Canon Calibrated<br />

Experiment 1: Find <strong>RGB</strong> transforms that stabilize the image<br />

Application Industrial Inspection<br />

Experiment 2: Find <strong>RGB</strong> transform that predicts the image<br />

Application Movie industry-Relighting<br />

Multispectral Simulation<br />

<strong>RGB</strong> Simulation<br />

Other visual mechanism relevant for human<br />

vision<br />

• Memory color: We “KNOW” the color of many objects<br />

• Color constancy: We know that objects usually don’t<br />

change colors (involves memory color <strong>and</strong> chromatic<br />

adaptation)<br />

• Discounting the illuminant: May often know the<br />

characteristics of the illuminant<br />

• Object recognition: Filling-in, induction, memory,<br />

learning etc.<br />

Compensation<br />

Multispectral Simulation<br />

<strong>RGB</strong> Compensation<br />

8


Simulation<br />

Intelligent<br />

Color<br />

Correction (1)<br />

Multispectral Simulation<br />

<strong>RGB</strong> Simulation<br />

Segment image in<br />

Object <strong>and</strong><br />

background<br />

Application: Automatic Color Correction<br />

Intelligent<br />

Color<br />

Correction (2)<br />

Bad example<br />

Application: Automatic Color<br />

Correction<br />

Part 8: Color in Matlab<br />

Sorted<br />

9


Color <strong>Space</strong>s<br />

Part 9: Color Management Systems<br />

How it works<br />

I_rgb = imread('peppers.png');<br />

Create a color transformation structure. A color transformation structure defines the<br />

conversion <strong>between</strong> two color spaces. You use the makecform function to create the<br />

structure, specifying a transformation type string as an argument. This example creates<br />

a color transformation structure that defines a conversion from <strong>RGB</strong> color data to XYZ<br />

color data.<br />

C = makecform('srgb2xyz');<br />

Perform the conversion. You use the applycform function to perform the conversion,<br />

specifying as arguments the color data you want to convert <strong>and</strong> the color transformation<br />

structure that defines the conversion. The applycform function returns the converted<br />

data.<br />

I_xyz = applycform(I_rgb,C);<br />

C 1x1 7744 struct array<br />

I_xyz 384x512x3 1179648 uint16 array<br />

I_rgb 384x512x3 589824 uint8 array<br />

Typical color image h<strong>and</strong>ling:<br />

• Take slide with camera<br />

• Scan the slide store on<br />

file<br />

• Edit file on the monitor<br />

• Convert file <strong>and</strong> print<br />

Why Color Management?<br />

Some factors which influence the result:<br />

• Illumination conditions<br />

• Camera<br />

• Film-type<br />

• Chemical processing of film<br />

• Scanner characteristics<br />

• Monitor characteristics<br />

• Software implementations<br />

• Printer characteristics<br />

• Ink properties<br />

• Paper type<br />

Data Types<br />

Basic strategies/Practical problems<br />

• Try to produce an output which is colorimetric as similar to the input as<br />

possible<br />

• Try to convert all images involved to a common set of colors<br />

(for example printer colors)<br />

• Try to keep as much information about each module as possible<br />

Practical problems<br />

• Each device has a color set it can h<strong>and</strong>le (Color gamut)<br />

• File formats<br />

• Data compression<br />

• Color co-ordinates<br />

• ...<br />

10


ICC = International Color Consortium<br />

ICC was founded 1993 by companies from Computer, Printer <strong>and</strong> Software<br />

business<br />

Treatment of color is done by Operating System<br />

Devices are characterized by profiles<br />

Tables, programs etc. which describe the device<br />

Several color spaces are supported as st<strong>and</strong>ard (CIEXYZ,<br />

CIELAB)<br />

Profiles describe<br />

• Input devices<br />

• Output devices<br />

• Display devices<br />

• Color space conversions<br />

• Other profiles<br />

Characterization of input <strong>and</strong> output devices<br />

There are two main strategies to describe input/output devices<br />

• Look-up-tables (LUT) describing input-output relations by a<br />

table<br />

• Analytical descriptions:<br />

White point <strong>and</strong><br />

Gamma value <strong>and</strong><br />

Black point<br />

Example:<br />

output = a * exp(c*x) + b<br />

Basic Color Management Systems<br />

Generating Profiles<br />

Generation of a profile for a scanner is done by<br />

Scanning in a test image<br />

Mapping result into common color space (Profile Connection <strong>Space</strong>, PCS)<br />

<strong>and</strong><br />

Comparison of measured an reference values<br />

Generation of printer profiles is done by printing st<strong>and</strong>ard patches <strong>and</strong><br />

measuring the resulting images<br />

A basic color management system connects input <strong>and</strong> output profiles by<br />

converting color information from input to output device<br />

Several samples should be measured <strong>and</strong> averaged to get reliable results<br />

Advanced Color Management Module<br />

Gamut mapping<br />

Important problem in color management:<br />

Different devices have different gamuts, i.e sets of colors they<br />

can<br />

produce<br />

Moving color images <strong>between</strong> different devices needs decision<br />

what to<br />

do with non-existing colors.<br />

Take into account input/output viewing conditions …….<br />

11


Gamuts for different systems<br />

ITN: Color Related Research<br />

Scene=objects+illuminations<br />

Digital camera<br />

Estimation of<br />

camera sensitivity<br />

Illumination +<br />

Camera<br />

Modelling:<br />

Cameras<br />

Illuminations<br />

Interactions<br />

Image<br />

Temperature Parameter<br />

Example<br />

Planck<br />

Spectrum<br />

Small continuous changes<br />

are hardly visible<br />

Color Constancy<br />

12

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!