Lines Matching refs:Lab
54 8 bit Lab PCS:
60 16 bit Lab PCS:
133 // Standard XYZ to Lab. it can handle negative XZY numbers in some cases
134 void CMSEXPORT cmsXYZ2Lab(const cmsCIEXYZ* WhitePoint, cmsCIELab* Lab, const cmsCIEXYZ* xyz)
145 Lab->L = 116.0*fy - 16.0;
146 Lab->a = 500.0*(fx - fy);
147 Lab->b = 200.0*(fy - fz);
151 // Standard XYZ to Lab. It can return negative XYZ in some cases
152 void CMSEXPORT cmsLab2XYZ(const cmsCIEXYZ* WhitePoint, cmsCIEXYZ* xyz, const cmsCIELab* Lab)
159 y = (Lab-> L + 16.0) / 116.0;
160 x = y + 0.002 * Lab -> a;
161 z = y - 0.005 * Lab -> b;
209 void CMSEXPORT cmsLabEncoded2FloatV2(cmsCIELab* Lab, const cmsUInt16Number wLab[3])
211 Lab->L = L2float2(wLab[0]);
212 Lab->a = ab2float2(wLab[1]);
213 Lab->b = ab2float2(wLab[2]);
217 void CMSEXPORT cmsLabEncoded2Float(cmsCIELab* Lab, const cmsUInt16Number wLab[3])
219 Lab->L = L2float4(wLab[0]);
220 Lab->a = ab2float4(wLab[1]);
221 Lab->b = ab2float4(wLab[2]);
247 cmsCIELab Lab;
249 Lab.L = Clamp_L_doubleV2(fLab ->L);
250 Lab.a = Clamp_ab_doubleV2(fLab ->a);
251 Lab.b = Clamp_ab_doubleV2(fLab ->b);
253 wLab[0] = L2Fix2(Lab.L);
254 wLab[1] = ab2Fix2(Lab.a);
255 wLab[2] = ab2Fix2(Lab.b);
291 cmsCIELab Lab;
293 Lab.L = Clamp_L_doubleV4(fLab ->L);
294 Lab.a = Clamp_ab_doubleV4(fLab ->a);
295 Lab.b = Clamp_ab_doubleV4(fLab ->b);
297 wLab[0] = L2Fix4(Lab.L);
298 wLab[1] = ab2Fix4(Lab.a);
299 wLab[2] = ab2Fix4(Lab.b);
340 void CMSEXPORT cmsLab2LCh(cmsCIELCh* LCh, const cmsCIELab* Lab)
342 LCh -> L = Lab -> L;
343 LCh -> C = pow(Sqr(Lab ->a) + Sqr(Lab ->b), 0.5);
344 LCh -> h = atan2deg(Lab ->b, Lab ->a);
349 void CMSEXPORT cmsLCh2Lab(cmsCIELab* Lab, const cmsCIELCh* LCh)
353 Lab -> L = LCh -> L;
354 Lab -> a = LCh -> C * cos(h);
355 Lab -> b = LCh -> C * sin(h);
428 // Returns dE on two Lab values
473 cmsFloat64Number ComputeLBFD(const cmsCIELab* Lab)
477 if (Lab->L > 7.996969)
478 yt = (Sqr((Lab->L+16)/116)*((Lab->L+16)/116))*100;
480 yt = 100 * (Lab->L / 903.3);
709 static cmsUInt16Number LABblack[4] = { 0, 0x8080, 0x8080 }; // V4 Lab encoding