Summary of the invention
The object of the invention is for color digital image provides the method for carrying out the conversion of high-fidelity visually-perceptible.According to technical scheme of the present invention, the visually-perceptible space of visible light colors and the method for correlated components equivalent is calculated by providing, realize being optimized expansion and mapping calculation to color digital image visually-perceptible component comparison visible light colors visually-perceptible spatial character, complete the high-fidelity visually-perceptible conversion of image.
Another object of the present invention is to provide the system of color digital image being carried out to the conversion of high-fidelity visually-perceptible.
" epic color one that method of the present invention and system belong to
tM", (FirstEposColor
tM), be called for short " poem look one
tM", (FECr
tM), mainly adjust the visually-perceptible intensity value of its each pixel color for significantly strengthening image high-fidelity perception, adjustment amount depends on intensity value and color self intensity value of brightness sequence in the visible light colors visually-perceptible space form and aspect plane equivalent color boundaries that this Color pair is answered.As a result, each pixel color of image while adding visually-perceptible saturation, maintain visually-perceptible form and aspect and brightness constant, and the saturation amplitude increased, is more conducive to high-fidelity and strengthens image vision perceived effect.
Representative color digital picture is the two-dimensional projection of the true scenery in visible light colors space at imaging plane, and therefore, image reproduction and the ideal effect copied should be as far as possible close to the perception to true scenery, and the high-fidelity of meaning reappears and copies.So, comprise according to algorithm of the present invention (FECr) and quantification statement is carried out to the visually-perceptible in visible light colors space.According to method of the present invention, the visible ray spatial character of the relatively above statement of the visually-perceptible saturation of image inherent colour is calculated expansion and mapped, obtains overall relatively maximum visible ray spatial characters for target with image and calculate the intensity value that each pixel increases.
Typical electronic device and color image color visually-perceptible space are much smaller than visible light colors visually-perceptible space, therefore, if directly with visible light colors space boundary for target adjustment color of image saturation, in some form and aspect planes, the increment most diverse of pixel color saturation will be caused, cause image deterioration.So, FECr algorithm according to the present invention is on the basis in complete description visible light colors visually-perceptible space, take into account the practical capacity of equipment and color of image visually-perceptible space saturation nonlinear extensions, calculate the form and aspect plane color equivalent border, visible light colors visually-perceptible space of optimization, and correct with the statistics of psychophysical method acquisition effect.Therefore, method according to the present invention is the effective ways obtaining the reproduction of color digital image high-fidelity and copy.
Method and system of the present invention can be used for the natural scene imagings such as photography, shooting, film, TV, video-game or any image and the dependent imaging equipment that are synthesized color by red, green and blue three primary colors by Practical computer teaching.
According to method of the present invention, the conversion of visually-perceptible high-fidelity is carried out to color digital image and comprises the following steps:
(1) obtain color digital image pixel color R, L, C and h numerical value of G and B numerical value in CIELAB space, wherein, h is hue angle, and L is brightness, C is saturation;
(2) pixel color merger enters form and aspect plane and brightness sequence,
Enter corresponding reference colours phase face with the merger of hue angle h value, enter corresponding bright sequence with lightness l value merger;
(3) expansion of pixel color saturation C is completed,
(3-1) determine that pixel color saturation maps flex point C
gL:
C
gL=C
maxL1×X
S1
Wherein, C
maxL1for pixel color merger in equipment colour vision aware space enters the brightness sequence maximum saturation angle value of form and aspect plane, X
s1for the proportionality coefficient arranged, exemplary value scope 0.65-0.95;
(3-2) the saturation expansion ratio BI of this brightness sequence is calculated
l:
BI
L=C
maxLd/C
maxL1
Wherein, C
maxLdfor the intensity value of same brightness sequence on pixel color identical form and aspect plane color equivalent border in visible light colors visually-perceptible space;
(3-3) saturation expansion ratio BI
lcharacterization regulation and control calculate, and comprising:
(3-3-1) saturation expansion ratio regulation and control coefficient B I is set
kx, number range 0.00-1,
BI
LY=BI
L×BI
Kx
Wherein, BI
kxallow to arrange and be multiplely respectively used to specified requirements, BI
lYfor regulating and controlling rear saturation expansion ratio,
(3-3-2) the interval border H in pairs of form and aspect plane is set
dxand H
gx, number range 0 °-359 °, H
dxand H
gxallow to arrange and be multipairly respectively used to specified requirements,
Color h>=H
dxwith h≤H
gx, BI
lY=BI
l× BI
k2
All the other colors, BI
lY=BI
l× BI
k1
Inside border, form and aspect plane transition region arranges number range 0-20,
(3-3-3) saturation proportion threshold value C is set
gx, number range 0.00-1, C
gxallow to arrange and be multiplely respectively used to specified requirements,
C
gxbe worth following color, BI
lY=BI
l× BI
k2
C
gxbe worth above color, BI
lY=BI
l× BI
k1
C
gxbe worth high-end side transition region and number range 0.00-0.2 be set,
(3-4) calculating pixel color saturation C
lc after expansion
lN:
C
LN=C
L×BI
LY,
As C
lNbe greater than C
gLthen calculate it to map:
C
LN=C
gL+(C
LN-C
gL)/(C
maxLd-C
gL)×(C
maxL1-C
gL);
(4) by Color image pixel brightness L, hue angle h and after step (3) expansion the saturation C that obtains
lNnumerical computations is specification R, G and B value.
According to method of the present invention, step (1) is for obtaining color digital image pixel color R, L, C and h numerical value of G and B numerical value in CIELAB space, wherein, h is hue angle, and L is brightness, C is saturation, can be realized by the existing known method in this area, preferably, according to specific embodiment of the invention scheme, first perform the step of invocation facility visually-perceptible color space form and aspect plane color boundaries computing module, obtain 3 × 3 necessary matrix coefficients.
According to of the present invention, the system that color digital image carries out the conversion of visually-perceptible high-fidelity is comprised:
(1) the colour vision aware space form and aspect plane color boundaries computing module of the equipment of display color digital picture, comprising:
(1-1) the red, green and blue tristimulus values of device color spaces is transformed to CIELAB space L, C and h value computing unit,
(1-2) equipment colour vision aware space form and aspect plane color edge extraction unit,
Enter corresponding reference colours phase face with the form and aspect h value merger equipment color that rounds up, enter corresponding bright sequence with the merger that rounds up of L value, extract the color maximum saturation angle value C of each brightness sequence of form and aspect plane
maxL1, calculate baseline values as the color boundaries of this form and aspect plane,
(1-3) form and aspect plane color boundaries C
maxL1smooth unit,
Select maximum saturation angle value C in form and aspect plane
maxh1the brightness L had
cmaxh1to minimum brightness L=0 brightness sequence interval corresponding to color boundaries C
maxL1, calculate smooth boundary with standard linear interpolation algorithm, make up C
maxL1non-ly smoothly successively decrease or fill up disappearance.The color boundaries calculated and by brightness L
cmaxh1the interval corresponding color boundaries of brightness sequence to L=100, represents the application color boundaries C of this form and aspect plane
maxL1;
(2) visible light colors visually-perceptible space form and aspect plane color equivalent border C
maxLdcomputing module;
(3) color digital image pixel color pattern forward conversion and merger form and aspect plane and brightness sequence module, comprising:
(3-1) color digital image pixel color rgb value is converted to the computing unit of L, C and h value in CIELAB space, wherein, h is hue angle, and L is brightness, C is saturation,
(3-2) pixel color form and aspect plane and brightness sequence Merging unit,
Be 360 reference colours phase face by color of image spatial division, corresponding reference colours phase face is entered with the merger that rounds up of form and aspect h value, brightness L scope in form and aspect plane is divided into 101 consensus sequences, enters corresponding bright sequence with the lightness l value merger that rounds up;
(4) Color image pixel intensity value expansion module, comprising:
(4-1) pixel color saturation expansion ratio BI
lcomputing unit:
BI
L=C
maxLd/C
maxL1
Wherein, C
maxLdfor pixel place brightness sequence is in the borderline intensity value of visible ray form and aspect plane color equivalent, C
maxL1for the intensity value of pixel place brightness sequence in equipment form and aspect plane color boundaries,
(4-2) saturation expansion ratio BI
lcharacterization regulation and control computing unit, comprising:
(4-2-1) saturation expansion ratio regulation and control coefficient B I is set
kx, number range 0.00-1,
BI
LY=BI
L×BI
Kx
Wherein, BI
kxallow to arrange multiple, be respectively used to specified requirements, BI
lYfor regulating and controlling rear saturation expansion ratio,
(4-2-2) the interval border H in pairs of form and aspect plane is set
dxand H
gx, number range 0 °-359 °, H
dxand H
gxallow to arrange and be multipairly respectively used to specified requirements:
Color h>=H
dxwith h≤H
gx, BI
lY=BI
l× BI
k2
All the other colors, BI
lY=BI
l× BI
k1
Inside border, form and aspect plane transition region arranges number range 0-20,
(4-2-3) saturation proportion threshold value C is set
gx, number range 0.00-1, C
gxallow to arrange and be multiplely respectively used to specified requirements:
C
gxbe worth following color, BI
lY=BI
l× BI
k2
C
gxbe worth above color, BI
lY=BI
l× BI
k1
C
gxbe worth high-end side transition region and number range 0.00-0.2 be set,
(4-3) saturation maps flex point C
gLcomputing unit:
C
gL=C
maxL1×X
S1
Set scale coefficient X
s1number range 0.65-0.95,
(4-4) pixel color saturation C
lexpand to C
lNcomputing unit:
C
LN=C
L×BI
LY,
Judge, if C
lNbe greater than C
gLthen calculate mapping:
C
LN=C
gL+(C
LN-C
gL)/(C
maxLd-C
gL)×(C
maxL1-C
gL);
(5) Color image pixel pattern transformation by reciprocal direction and normalizing block:
Described calculating comprises L, h of Color image pixel and expands the saturation C obtained through module (4)
lNnumerical computations is specification R, G and B value.
According to the preferred embodiments of the invention, described system also comprises visible light colors visually-perceptible space form and aspect plane color maximum saturation computing module.
As the preferred technical solution of the present invention, equipment visually-perceptible color space form and aspect plane color boundaries database first completes via the equipment visually-perceptible color space form and aspect plane color boundaries computing module computing in system of the present invention, and calculating comprises:
(1-1) the red, green and blue tristimulus values of device color spaces is transformed to the calculating of CIELAB space L, C and h value, is transformed to CIELAB space L, C and h value computing unit performs by the red, green and blue tristimulus values of device color spaces:
The white field of use equipment nominal and red, green and blue three primary colors relevant parameter, the canonical algorithm that application CIE recommends, by whole colors that the red, green and blue three primary colors of equipment synthesize, is converted to CIEXYZ tristimulus values and CIELAB space L, C and h value, comprising:
Application nominal sRGB space RGB three primary colors chromaticity parameter and the white field parameters of D65 calculate the brightness value of RGB three primary colors maximum saturation:
Y
r,max=0.2126 Y
g,max=0.7152 Y
b,max=0.0722
Application is above calculates 3 × 3 matrix coefficients:
Non-standard equipment need calculate CIEXYZ tristimulus values when white field and red, green and blue three primary colors maximum saturation:
Use standard spectral photometric instrument, the conveniently white field tristimulus values X of criterion equipment
w', Y
w' and Z
w', calculate white field normalization coefficient K
1:
K
1=100/Y
w’
The CIEXYZ tristimulus values of the white field of computing equipment:
X
w=X
w’×K
1 Y
w=Y
w’×K
1 Z
w=Z
w’×K
1
Use standard spectral photometric instrument, the tristimulus values conveniently under specification difference measuring equipment red, green and blue three primary colors maximum saturation condition, X
r', Y
r' and Z
r', X
g', Y
g' and Z
g', X
b', Y
b' and Z
b'.Calculate trichromatic CIEXYZ tristimulus values respectively:
X
r,max=X
r’×K
1,Y
r,max=Y
r’×K
1,Z
r,max=Z
r’×K
1
X
g,max=X
g’×K
1,Y
g,max=Y
g’×K
1,Z
g,max=Z
g’×K
1
X
b,max=X
b’×K
1,Y
b,max=Y
b’×K
1,Z
b,max=Z
b’×K
1
By the three primary colors CIEXYZ tristimulus values calculated above, substitute 3 × 3 matrix coefficients in the above standard method, substitute the above equipment nominal white field CIEXYZ tristimulus values with the white field CIEXYZ tristimulus values calculated, calculate CIELAB space L, C and h numerical value.
(1-2) equipment visually-perceptible color space form and aspect plane color boundaries calculates, and is performed by equipment colour vision aware space form and aspect plane color edge extraction unit:
With 0-359 integer representation reference colours phase face, corresponding reference colours phase face is entered with the form and aspect h value merger equipment color that rounds up, and with 0-100 integer representation Benchmark brightness sequence, enter corresponding bright sequence with the merger that rounds up of L value, extract color maximum saturation angle value C in each brightness sequence of form and aspect plane
maxL1, calculate basis as the color boundaries of this form and aspect plane;
(1-3) form and aspect plane color boundaries smoothing computation, by form and aspect plane color boundaries C
maxL1smooth unit performs:
Extract maximum saturation angle value C in form and aspect plane
maxh1the brightness L had
cmaxh1to minimum brightness L=0 brightness sequence interval corresponding to color boundaries, with standard linear interpolation algorithm calculate smooth boundary, make up the maximum saturation C of former brightness sequence
maxL1non-ly smoothly successively decrease or fill up disappearance.The color boundaries C calculated
maxL1and by brightness L
cmaxh1the interval corresponding color boundaries C of brightness sequence to L=100
maxL1, represent the application color boundaries of this form and aspect plane.
Above result of calculation is stored as database, and data sort with first sequence form and aspect plane order brightness sequence, totally 36360 row.
According to specific embodiment of the invention scheme, perform step (2) afterwards with step (1): the visually-perceptible color space form and aspect plane color equivalent data boundary storehouse of calling visible ray.
As another optimal technical scheme of the present invention, form and aspect plane color equivalent data boundary storehouse, visible light colors visually-perceptible space first completes via the visible light colors visually-perceptible space form and aspect plane color maximum saturation computing module in system of the present invention and visible light colors visually-perceptible space form and aspect plane color equivalent feature modeling module arithmetic, and calculating comprises:
(2-1) visible light colors visually-perceptible space form and aspect plane color maximum saturation calculates, and is performed by visible light colors visually-perceptible space form and aspect plane color maximum saturation computing module:
(2-1-1) form and aspect plane 38 °-317 ° calculating, are performed by form and aspect plane 38 ° of-317 ° of computing units:
With x, y and z numerical value of CIE 1931XYZ standard colorimetric observer spectral tristimulus value medium wavelength 380nm to 780nm interval 5nm, and the white field CIEXYZ tristimulus values of computing equipment color space application, the method of recommending with CIE calculates L, C and h numerical value, and to round up merger form and aspect plane with h value, take L and the C numerical value of form and aspect plane in 38 ° to 317 ° form and aspect intervals, linear interpolation calculates L and the C value of blank form and aspect plane wherein, the maximum saturation C using L and C value as the corresponding form and aspect plane in visible light colors visually-perceptible space
maxh2and brightness L
cmach2.
(2-1-2) form and aspect plane 0 °-37 ° and 318 °-359 ° calculating, are performed by form and aspect plane 0 °-37 ° and 318 ° of-359 ° of computing units:
With the white field CIEXYZ tristimulus values that CIERGB color space red, green and blue three primary colors canonical parameter and computing equipment color space are applied, calculate L, C and h parameter of whole red, green and blue three primary colors synthesis color, comprising:
3 × 3 matrix coefficients are calculated with same procedure in nominal CIERGB space RGB three primary colors chromaticity parameter and D65 white field parameters application above-mentioned steps (1):
X
r,max=0.4108 Y
r,max=0.1481 Z
r,max=0
X
g,max=0.3210 Y
g,max=0.8401 Z
g,max=0.0105
X
b,max=0.2185 Y
b,max=0.0118 Z
b,max=1.0783
In the form and aspect plane of merger, select 0 ° to 37 ° and 318 ° to 359 ° form and aspect planes, and extract wherein maximum saturation C
maxh2and brightness L
cmach2numerical value.
(2-2) visible light colors visually-perceptible space form and aspect plane color equivalent feature modeling, by visible light colors visually-perceptible space form and aspect plane color equivalent border C
maxLdcomputing module performs:
(2-2-1) visible light colors visually-perceptible space and equipment colour vision aware space form and aspect plane maximum saturation ratio and optimizing calculates, and is performed by visible light colors visually-perceptible space and equipment colour vision aware space form and aspect plane maximum saturation ratio and optimization calculation unit:
Select 0 ° to 359 ° form and aspect plane respectively, calculate visible light colors space C
maxh2with device color spaces C
maxh1ratio value B
maxh:
B
maxh=C
maxh2/C
maxh1
Set scale coefficient F
x1with equivalent coefficient F
x2, wherein, F
x1number range 2.50-6.00, F
x2number range 1.50-2.50, calculates B
maxhstandardization equivalents ratio B
maxd:
B
maxhvalue is greater than F
x1form and aspect plane standardization calculate:
B
maxd=(B
maxh-F
x1interval maximum scale value-the F of)/(ratio
x1) × 0.1+F
x2
B
maxhvalue is less than or equal to F
x1be greater than (F
x1-1) standardization of form and aspect plane calculates:
B
maxd=(B
maxh-(F
x1-1))/(interval maximum scale value-(F of ratio
x1-1)) × 0.05+ (F
x2-0.05)
B
maxhvalue is less than or equal to (F
x1-1) (F is greater than
x1-1.5) standardization of form and aspect plane calculates:
B
maxd=(B
maxh-(F
x1-1.5))/(interval maximum scale value-(F of ratio
x1-1.5)) × 0.05+ (F
x2-0.1)
B
maxhvalue is less than or equal to (F
x1-1.5) (F is greater than
x1-2) standardization of form and aspect plane calculates:
B
maxd=(B
maxh-(F
x1-2))/(interval maximum scale value-(F of ratio
x1-2)) × 0.1+ (F
x2-0.2)
B
maxhvalue is less than or equal to (F
x1-2) (F is greater than
x1-2.5) standardization of form and aspect plane calculates:
B
maxd=(B
maxh-(F
x1-2.5))/(interval maximum scale value-(F of ratio
x1-2.5)) × 0.05+ (F
x2-0.25)
B
maxhvalue equals (F
x1-2.5) and following form and aspect plane standardization calculate:
B
maxd=B
maxhinterval maximum scale value × 0.05+ (the F of/ratio
x2-0.3)
(2-2-2) visible light colors space form and aspect plane maximum saturation equivalent and color boundaries calculate, by visible light colors space form and aspect plane maximum saturation equivalent C
maxhdand color equivalent border C
maxLdcomputing unit performs:
Form and aspect plane maximum saturation equivalent C
maxhdcalculate:
C
maxhd=C
maxh1×B
maxd
Form and aspect plane color equivalent feature modeling:
Abscissa be saturation C, ordinate is the cartesian coordinate plane of brightness L, with C
maxh2and L
cmaxh2value, punctuate D
maxh2, at D
maxh2c is indicated to L=100 point line
maxhd, the brightness sequence value that its ordinate value rounds up is designated as L
cmaxhd, its coordinate points is designated as D
maxhd;
Indicate the equipment color boundaries of identical form and aspect plane at coordinate plane, then indicate D
maxhdto L=0 point line, under the prerequisite that the maximum saturation angle value calculating corresponding bright sequence in its brightness section is smoothly successively decreased, contain the intensity value C needed for equipment color boundaries
maxhd, this partial value and D
maxhdintensity value C to L=100 point line
maxhd, form the equivalent border of visible ray form and aspect plane color.Above result of calculation is stored as database, and data sort with first sequence form and aspect plane order brightness sequence, totally 36360 row.
According to the specific embodiment of the present invention, the red, green and blue tristimulus values that step (3) is color digital image is converted to CIELAB space L, C and h value and merger enters corresponding form and aspect plane and brightness sequence.Call color digital image pixel color pattern forward conversion in system of the present invention and merger form and aspect plane and brightness sequence module to calculate:
(3-1) color digital image pixel color rgb value is converted to the calculating of L, C and h value in CIELAB space, the computing unit being converted to L, C and h value in CIELAB space by color digital image pixel color rgb value performs:
The white field using the equipment nominal of display image or image itself to embed and red, green and blue three primary colors relevant parameter, the canonical algorithm that application CIE recommends, by the color that the red, green and blue three primary colors of image pixel synthesize, be converted to CIEXYZ tristimulus values and CIELAB space L, C and h value, comprising:
Application nominal sRGB space RGB three primary colors chromaticity and the white field parameters of D65, calculate the brightness value of RGB three primary colors maximum saturation:
Y
r,max=0.2126 Y
g,max=0.7152 Y
b,max=0.0722
The above value of application calculates 3 × 3 matrix coefficients:
Non-standard equipment shows the CIEXYZ tristimulus values of the image palpus white field of computing equipment and red, green and blue three primary colors maximum saturation:
Use standard spectral photometric instrument, the conveniently white field tristimulus values X of criterion equipment
w', Y
w' and Z
w', calculate white field normalization coefficient K
1:
K
1=100/Y
w’
The CIEXYZ tristimulus values of the white field of computing equipment:
X
w=X
w’×K
1,Y
w=Y
w’×K
1,Z
w=Z
w’×K
1
Use standard spectral photometric instrument, the tristimulus values conveniently under specification difference measuring equipment red, green and blue three primary colors maximum saturation condition, X
r', Y
r' and Z
r', X
g', Y
g' and Z
g', X
b', Y
b' and Z
b' calculate trichromatic CIEXYZ tristimulus values respectively:
X
r,max=X
r’×K
1,Y
r,max=Y
r’×K
1,Z
r,max=Z
r’×K
1
X
g,max=X
g’×K
1,Y
g,max=Y
g’×K
1,Z
g,max=Z
g’×K
1
X
b,max=X
b’×K
1,Y
b,max=Y
b’×K
1,Z
b,max=Z
b’×K
1
By the three primary colors CIEXYZ tristimulus values calculated above, substitute 3 × 3 matrix coefficients in the above standard method, substitute the above equipment nominal white field CIEXYZ tristimulus values with the white field CIEXYZ tristimulus values calculated, calculate CIELAB space L, C and h numerical value.
(3-2) pixel color form and aspect plane and brightness sequence merged calculate, is performed by pixel color form and aspect plane and brightness sequence Merging unit:
Be 0-359 totally 360 reference colours phase face by color of image spatial division, corresponding reference colours phase face is entered with the merger that rounds up of Color image pixel form and aspect h value, brightness L scope in form and aspect plane is divided into 0-100 totally 101 consensus sequences, corresponding bright sequence is entered with the merger that rounds up of colour brightness L value, make pixel color parameter available integer form and aspect h, integer brightness L and the saturation C containing four decimals represents, reaches one of design conditions of saturation expansion.
According to the specific embodiment of the present invention, step (4) is the expansion of computed image pixel color saturation.Call the Color image pixel intensity value expansion module in system of the present invention, calculating comprises:
(4-1) calculating pixel color saturation maps flex point C
gL, map flex point C by saturation
gLcomputing unit performs:
C
gL=C
maxL1*X
S1
C
maxL1for the maximum saturation angle value called at equipment visually-perceptible color space form and aspect bitplane data library searching with pixel color phase face and brightness sequence integer value, X
s1for the flex point function arranged as required, number range 0.65-0.95, is typically 0.8-0.9;
(4-2) calculating pixel color saturation expansion ratio BI
l, expand ratio BI by pixel color saturation
lcomputing unit performs:
BI
L=C
maxLd/C
maxL1
C
maxLdfor the equivalent intensity value called at photopic vision perceptual color space form and aspect plane color equivalent data boundary library searching with pixel color phase face and brightness sequence integer value;
Allow the multiple saturation expansion ratio regulator module called in system of the present invention:
(4-2-1) submodule of saturation expansion ratio regulation and control is set:
Described calculating comprise arrange multiple saturation expansion ratio regulation and control coefficient B I
kx, number range 0.00-1, with BI
lY=BI
kx× BI
las the saturation expansion ratio of pixel practical application, typical case, character image BI
k2be typically 0.10-0.40, landscape image BI
k1be typically 0.40-0.90;
(4-2-2) submodule of form and aspect plane interval border is set:
Described calculating comprises arranging how group form and aspect plane is interval, form and aspect interval border H
dxand H
gx, number range 0 °-359 °, uses the saturation different from outside interval to expand ratio BI to color in bulletin colour mutually interval
lY, the mutually interval H of character image typical color
d1=340 ° and H
g1=100 °, in this form and aspect interval, BI
lY=BI
k2× BI
l; Beyond this form and aspect interval, BI
lY=BI
k1× BI
l.Inside form and aspect interval border, establish intermediate color separately, control bulletin colour mutually interval inside and outside saturation expansion ratio smoothly changes, transition region number range 0-20;
(4-2-3) submodule of saturation proportion threshold value is set:
Described calculating comprises and arranges saturation ratio value as threshold value C
gx, number range 0.00-1, threshold value uses the saturation ratio boundary of different saturation expansion ratio as color in same brightness sequence, and typical case, character image arranges C
gxbe typically 0.50-0.75, the following color of threshold value, BI
lY=BI
k2× BI
l, the above color of threshold value, BI
lY=BI
k1× BI
l.Transition region is established in the above side of threshold value, and regulation and control saturation expansion ratio smoothly changes, transition region number range 0.00-0.2;
(4-3) calculating pixel color saturation C
lexpansion, by pixel color saturation C
lexpand to C
lNcomputing unit performs:
C
LN=C
L*BI
LY,
BI
lYbe subject to the regulation and control that above-mentioned three species saturation expansion ratio regulation and control are arranged, result of calculation C
lNif be greater than C
gLthen calculate mapping:
C
LN=C
gL+(C
LN-C
gL)/(C
maxLd-C
gL)*(C
maxL1-C
gL)
According to the specific embodiment of the present invention, step (5) is by Color image pixel L, h and saturation C
lNnumerical computations is specification R, G and B value.According to the preferred technical solution of the present invention, call the Color image pixel pattern transformation by reciprocal direction in system of the present invention and normalizing block, calculating comprises:
The standard method using CIE to recommend, calculates with Color image pixel and unaltered brightness L, hue angle h value and the C that obtains after expanding as calculated
lNvalue is calculated as the red, green and blue tristimulus values of equipment.This algorithm is the inverse operation of above step (3), needed for pixel color CIELAB calculation of parameter CIEXYZ tristimulus values, white field CIEXYZ tristimulus values calculates identical with forward, calculates 3 × 3 matrix coefficients needed for rgb value to be inverted acquisition by above step (3) matrix 3 × 3 used coefficient by pixel color CIEXYZ tristimulus values:
Respectively R, G and B value calculated is rounded, and 255 are turned to the numerical value specification being greater than 255,0 is turned to the numerical value specification being less than 0.
Typical case synthesizes the digital picture of color by red, green and blue three primary colors, for landscape image, after FECr algorithm according to the present invention adjusts the visually-perceptible saturation parameters of each pixel color, with image initial saturation numeric ratio comparatively, after can seeing the adjustment of FECr algorithm, color saturation value increasing degree is on average about 52%, and the pixel intensity of image about 50% adds 70%, and the pixel of 30% increases 70-30%, the pixel of 10% increases 30-10%, and the pixel of 10% increases 10-0%.Relation between the ratio of the form and aspect plane brightness sequence maximum saturation angle value of its merger relative of the pixel color intensity value before and after adjustment, shows the non-linear of the actual increment of saturation.
According to FECr algorithm of the present invention, under the condition that the device color spaces border of display image does not expand, in computed image, the more sensitive color of vision makes it to increase relatively many visible light colors vision perception characteristics, calculate relatively insensitive color increase less or remain unchanged, this non-linear Enhancement Method can make viewing image obtain relatively significantly close to the effect of watching actual scenery in visible light colors space.
Embodiment 1
Implement color digital image pixel color visually-perceptible high-fidelity shift process of the present invention.
(1) computing equipment colour vision aware space form and aspect plane color boundaries database.
Database completes via the equipment colour vision aware space form and aspect plane color boundaries computing module computing in system of the present invention, and calculating comprises:
(1-1) the red, green and blue tristimulus values of device color spaces is transformed to the calculating of CIELAB space L, C and h value, is transformed to CIELAB space L, C and h value computing unit by device color spaces red, green and blue tristimulus values and performs:
The electronic equipment with image display function is typically sRGB color space and the white field of D65, and sRGB space RGB three primary colors chromaticity is consulted:
x
r,max=0.64 y
r,max=0.33,x
g,max=0.30 y
g,max=0.60,x
b,max=0.15 y
b,max=0.06
D65 white field CIEXYZ tristimulus values is consulted:
X
w=0.950456 Y
w=1 Z
w=1.089058
3 × 3 matrix coefficients needed for above calculation of parameter colour switching:
Utilize the trichromatic rgb value in the white field of equipment and CIEXYZ tristimulus values and positive-going transition formula:
3 × 3 matrix coefficients are expressed as the product form of three primary colors chromatic value and brightness value:
The brightness value of RGB three primary colors maximum saturation is calculated by above equation:
Y
r,max=0.2126 Y
g,max=0.7152 Y
b,max=0.0722
The above value of application calculates matrix 3 × 3 coefficient:
Apply the conversion of above matrix coefficient computing equipment color rgb value to CIEXYZ space X, Y and Z value, then apply D65 white field tristimulus values calculating color XYZ value to CIELAB space L, C and h value transform.
Exemplary apparatus often plants 8 synthesis colors by red, green and blue three primary colors, and namely 2
3 × 8totally 16777216 kinds of color scalars, successively by having calculated conversion above.
Non-standard equipment calculates CIEXYZ tristimulus values when white field and red, green and blue three primary colors maximum saturation:
Use standard spectral photometric instrument, the conveniently white field tristimulus values X of criterion equipment
w', Y
w' and Z
w', calculate white field normalization coefficient K
1:
K
1=100/Y
w’
The CIEXYZ tristimulus values of the white field of computing equipment:
X
w=X
w’×K
1,Y
w=Y
w’×K
1,Z
w=Z
w’×K
1
Use standard spectral photometric instrument, the tristimulus values conveniently under specification difference measuring equipment red, green and blue three primary colors maximum saturation condition, X
r', Y
r' and Z
r', X
g', Y
g' and Z
g', X
b', Y
b' and Z
b', then calculate trichromatic CIEXYZ tristimulus values respectively:
X
r,max=X
r’×K
1,Y
r,max=Y
r’×K
1,Z
r,max=Z
r’×K
1
X
g,max=X
g’×K
1,Y
g,max=Y
g’×K
1,Z
g,max=Z
g’×K
1
X
b,max=X
b’×K
1,Y
b,max=Y
b’×K
1,Z
b,max=Z
b’×K
1
By CIEXYZ tristimulus values during the three primary colors maximum saturation calculated above, substitute 3 × 3 matrix coefficients in the above standard method, the above equipment nominal white field CIEXYZ tristimulus values is substituted with the white field CIEXYZ tristimulus values calculated, applying the above standard method, is CIELAB space L, C and h numerical value by R, G and B numerical transformation of totally 16777216 kinds of colors successively.
(1-2) calculating of equipment colour vision aware space form and aspect plane color boundaries, is performed by equipment colour vision aware space form and aspect plane color edge extraction unit.
With 0-359 integer representation reference colours phase face, enter corresponding reference colours phase face with the form and aspect h value merger equipment color that rounds up, with 0-100 integer representation Benchmark brightness sequence, enter corresponding bright sequence with the L value merger color that rounds up.Extract maximum saturation angle value C in each brightness sequence of form and aspect plane
maxL1, calculate basis as the color boundaries of this form and aspect plane.
(1-3) form and aspect plane color boundaries smoothing computation, by form and aspect plane color boundaries C
maxL1smooth unit performs:
Extract maximum saturation angle value C in form and aspect plane
maxh1the brightness L had
cmaxh1to minimum brightness L=0 brightness sequence interval corresponding to color boundaries, with standard linear interpolation algorithm calculate smooth boundary, repair the maximum saturation C of former brightness sequence
maxL1non-ly smoothly successively decrease or fill up disappearance.This part colours border C calculated
maxL1together with by brightness L
cmaxh1the interval corresponding color boundaries C of brightness sequence to L=100
maxL1, represent the final application color boundaries of this form and aspect plane.
Alleged level and smooth in above algorithm, i.e. colour brightness sequence arranges from high to low, its saturation C
maxL1be less than above sequence and be greater than following all sequences.Saturation is less than calculated value and then uses calculated value, is greater than calculated value then constant.
Above result of calculation is stored as database.Data sort according to first sequence form and aspect plane h order brightness sequence L, totally 36360 row.Above step (1) calculation process is as shown in Fig. 2-1.
(2) form and aspect plane color equivalent data boundary storehouse, visible light colors visually-perceptible space is calculated.
Form and aspect plane color equivalent data boundary storehouse, visible light colors visually-perceptible space completes via the visible light colors visually-perceptible space form and aspect plane color maximum saturation computing module in system of the present invention and visible light colors visually-perceptible space form and aspect plane color equivalent feature modeling module arithmetic, and calculating comprises:
(2-1) visible light colors visually-perceptible space form and aspect plane color maximum saturation calculates,
(2-1-1) form and aspect plane 38 °-317 ° calculating, are performed by form and aspect plane 38 ° of-317 ° of computing units:
With x, y and z numerical value of CIE 1931XYZ standard colorimetric observer spectral tristimulus value medium wavelength 380nm to 780nm interval 5nm, and D65 white field CIEXYZ tristimulus values, the method of recommending with CIE calculates CIELAB space L, C and h numerical value, and to round up merger form and aspect plane with h value, take L and the C numerical value of form and aspect plane in 38 ° to 317 ° form and aspect intervals, and L and the C value of linear interpolation calculation blank form and aspect plane wherein, the maximum saturation C using L and C value as the corresponding form and aspect plane in visible light colors visually-perceptible space
maxh2and brightness L
cmach2.
(2-1-2) form and aspect plane 0 °-37 ° and 318 °-359 ° calculating, are performed by form and aspect plane 0 °-37 ° and 318 ° of-359 ° of computing units:
Application CIERGB space RGB three primary colors chromaticity parameter:
x
r,max=0.735 Y
r,max=0.265,x
g,max=0.274 Y
g,max=0.717,x
b,max=0.167 Y
b,max=0.009
And the white field parameters of D65, calculate 3 × 3 matrix coefficients with same procedure in step (1):
X
r,max=0.4108 Y
r,max=0.1481 Z
r,max=0
X
g,max=0.3210 Y
g,max=0.8401 Z
g,max=0.0105
X
b,max=0.2185 Y
b,max=0.0118 Z
b,max=1.0783
With above-mentioned matrix coefficient and D65 white field CIEXYZ tristimulus values, calculate L, C and h parameter of whole colors of CIERGB space red, green and blue three primary colors synthesis, in the form and aspect plane of merger, select 0 ° to 37 ° and 318 ° to 359 ° form and aspect planes, and extract wherein maximum saturation C
maxh2and brightness L
cmach2numerical value.
(2-2) visible light colors visually-perceptible space form and aspect plane color equivalent feature modeling, by visible light colors visually-perceptible space form and aspect plane color equivalent border C
maxLdcomputing module performs:
(2-2-1) visible light colors visually-perceptible space and equipment colour vision aware space form and aspect plane maximum saturation ratio and optimizing calculates, and is performed by visible light colors visually-perceptible space and equipment colour vision aware space form and aspect plane maximum saturation ratio and optimization calculation unit:
Select 0 ° to 359 ° form and aspect plane, calculate visible light colors space C respectively
maxh2with device color spaces C
maxh1ratio value B
maxh:
B
maxh=C
maxh2/C
maxh1
Check and find B
maxhmaximum close to 5, the unsuitable directly application percentage value B of application discovering device sRGB color space
maxhextension color saturation.
Set scale coefficient F
x1with equivalent coefficient F
x2, wherein F
x1numerical value is 4.5, F
x2numerical value is 1.9, calculates B
maxhstandardization equivalent value B
maxd:
B
maxhvalue is greater than F
x1form and aspect plane standardization calculate:
B
maxd=(B
maxh-F
x1interval maximum scale value-the F of)/(ratio
x1) * 0.1+F
x2
B
maxhvalue is less than or equal to F
x1be greater than (F
x1-1) standardization of form and aspect plane calculates:
B
maxd=(B
maxh-(F
x1-1))/(interval maximum scale value-(F of ratio
x1-1)) * 0.05+ (F
x2-0.05)
B
maxhvalue is less than or equal to (F
x1-1) (F is greater than
x1-1.5) standardization of form and aspect plane calculates:
B
maxd=(B
maxh-(F
x1-1.5))/(interval maximum scale value-(F of ratio
x1-1.5)) * 0.05+ (F
x2-0.1)
B
maxhvalue is less than or equal to (F
x1-1.5) (F is greater than
x1-2) standardization of form and aspect plane calculates:
B
maxd=(B
maxh-(F
x1-2))/(interval maximum scale value-(F of ratio
x1-2)) * 0.1+ (F
x2-0.2)
B
maxhvalue is less than or equal to (F
x1-2) (F is greater than
x1-2.5) standardization of form and aspect plane calculates:
B
maxd=(B
maxh-(F
x1-2.5))/(interval maximum scale value-(F of ratio
x1-2.5)) * 0.05+ (F
x2-0.25)
B
maxhvalue equals (F
x1-2.5) and following form and aspect plane standardization calculate:
B
maxd=B
maxh/ ratio interval maximum scale value * 0.05+ (F
x2-0.3)
(2-2-2) visible light colors visually-perceptible space form and aspect plane maximum saturation equivalent and color equivalent feature modeling, by visible light colors visually-perceptible space form and aspect plane maximum saturation equivalent C
maxhdand color equivalent border C
maxLdcomputing unit performs:
Form and aspect plane maximum saturation equivalent C
maxhdcalculate:
C
maxhd=C
maxh1×B
maxd
Form and aspect plane color equivalent feature modeling:
In the cartesian coordinate plane of abscissa to be saturation C and ordinate be brightness L, with C
maxh2and L
cmaxh2value punctuate D
maxh2, at D
maxh2c is indicated to L=100 point line
maxhd, the brightness sequence value that its ordinate value rounds up is designated as L
cmaxhd, its coordinate points is designated as D
maxhd.
Indicate the equipment color boundaries of identical form and aspect plane at this coordinate plane, then indicate D
maxhdto L=0 point line, under the prerequisite that the maximum saturation angle value calculating corresponding bright sequence in its brightness section is smoothly successively decreased, contain the intensity value C needed for equipment color boundaries
maxLd, this partial value and D
maxhdintensity value C to L=100 point line
maxLd, form the equivalent border of visible ray form and aspect plane color.
The algorithm of the saturation above needed for alleged containing equipment color boundaries, increases 2-3% with the maximum saturation angle value of flex point brightness sequence in equipment color boundaries.
Above result of calculation is stored as database, with above equipment color data library format and sort identical.
(2-3) visible light colors calculates when quantity space and device color spaces form and aspect plane maximum saturation ratio:
Form and aspect plane maximum saturation C is retrieved respectively from above two databases
maxh1and C
maxhdboth calculating ratio, building database, sorts with form and aspect plane h, data 360 row.Above step (2) calculation process is as shown in Fig. 2-2.
(3) the red, green and blue tristimulus values completing color digital image is converted to CIELAB space L, C and h value and merger enters corresponding form and aspect plane and brightness sequence, is performed by color digital image pixel color pattern forward conversion and merger form and aspect plane and brightness sequence module.
Calculating comprises:
(3-1) color digital image pixel color rgb value is converted to the calculating of L, C and h value in CIELAB space, and the computing unit being converted to L, C and h value in CIELAB space by color digital image pixel color rgb value performs:
The white field using the equipment nominal of display image or image itself to embed and red, green and blue three primary colors relevant parameter, the canonical algorithm that application CIE recommends, be CIEXYZ tristimulus values and CIELAB space L, C and h value by the color conversion that the red, green and blue three primary colors of image pixel represent, algorithm routine and relevant parameter identical with step (1).
Non-standard equipment shows CIEXYZ tristimulus values when image needs the white field of survey calculation equipment and red, green and blue three primary colors maximum saturation, algorithm routine and relevant parameter identical with step (1).
(3-2) pixel color form and aspect plane and brightness sequence merged calculate, is performed by pixel color form and aspect plane and brightness sequence Merging unit:
Be 0-359 totally 360 reference colours phase face by color of image spatial division, corresponding reference colours phase face is entered with the merger that rounds up of form and aspect h value, brightness L scope in form and aspect plane is divided into 0-100 totally 101 consensus sequences, corresponding bright sequence is entered with the lightness l value merger that rounds up, make pixel color parameter available integer form and aspect h, integer brightness L and the saturation C containing four decimals represents, creates one of design conditions of saturation expansion.
(4) calculating pixel color saturation expansion, is performed by Color image pixel intensity value expansion module.
Calculating comprises:
(4-1) calculating pixel color saturation maps flex point C
gL, map flex point C by saturation
gLcomputing unit performs:
C
gL=C
maxL1*X
S1
Flex point function X is set
s1be 0.85;
(4-2) calculating pixel color saturation expansion ratio BI
l, expand ratio BI by pixel color saturation
lcomputing unit performs:
BI
L=C
maxLd/C
maxL1
Call the multiple saturation expansion ratio regulator module in system of the present invention:
(4-2-1) saturation expansion ratio regulation and control coefficient is set:
Described calculating comprise arrange multiple saturation expansion ratio regulation and control coefficient B I
kx, number range 0.00-1, with BI
lY=BI
kx× BI
las the saturation expansion ratio of pixel practical application.
Typical case, BI
k1=0.75 is the image of main contents for scenery, BI
k2=0.15 is the image of main contents for personage.
(4-2-2) bulletin colour phase face interval border is set:
Described calculating comprises and arranges multipair bulletin colour phase face interval border H
dxand H
gx, number range 0 °-359 °.Typical case, character image arranges H
d1=340 ° and H
g1=100 °, hue angle h≤H
g1or h>=H
d1form and aspect plane color application BI
lY=BI
k2× BI
l, all the other color application BI
lY=BI
k1× BI
l.Arranging form and aspect interval border inner transition form and aspect interval numerical value is 10.
(4-2-3) saturation proportion threshold value is set:
Described calculating comprises and arranges multiple saturation proportion threshold value C
gx, number range 0.00-1.Typical case, character image C
g1=0.6, to specifying h≤H above
g1or h>=H
d1the interval color of form and aspect, saturation ratio lower than threshold value, BI
lY=BI
k2× BI
l, saturation ratio higher than threshold value, BI
lY=BI
k1× BI
l.Transition region is established in the above side of threshold value, arranges transition zone ranges 0.1.
(4-3) calculating pixel color saturation C
lexpansion, by pixel color saturation C
lexpand to C
lNcomputing unit performs:
C
LN=C
L*BI
LY,
Judge, if C
lNbe greater than C
gLmust calculate and map:
C
LN=C
gL+(C
LN-C
gL)/(C
maxLd-C
gL)*(C
maxL1-C
gL)
(5) by Color image pixel L, h and saturation C
lNnumerical computations is R, G and B value.
Call Color image pixel pattern transformation by reciprocal direction and normalizing block, calculating comprises:
The standard method using CIE to recommend, obtains with Color image pixel positive-going transition and the C obtained after L, h value remained unchanged and as calculated expansion
lNvalue is calculated as the red, green and blue tristimulus values of image.This algorithm is the inverse operation that above step (3) calculates, calculate white field needed for CIEXYZ tristimulus values by pixel color CIELAB spatial parameter and be similarly D65, calculate 3 × 3 matrix coefficients needed for rgb value by pixel color CIEXYZ tristimulus values and to be inverted acquisition by above step (3) matrix 3 × 3 used coefficient:
Round respectively R, G and B value calculated, and turn to 255 to the numerical value specification being greater than 255, the numerical value specification being less than 0 turns to 0.Above step (3) (4) (5) calculation process as Figure 2-3.
The FECr algorithm flow that the whole pixel of image performs above-mentioned color digital image successively completes described calculating, and image just completes the conversion of visually-perceptible high-fidelity.