|
PDF 1.3 CIELab color space(ISO 32000-1 8.6.5.3)를 auto-generated resource name(Lab1, Lab2, ...) 아래에 등록합니다. 반환된 name을 THPDFPage.SetFillColorSpace / SetStrokeColorSpace와 함께 사용한 뒤 세 L*a*b* component를 전달해 SetFillColor / SetStrokeColor를 호출하십시오
Delphi 구문:
function RegisterLabColorSpace(WhitePointX, WhitePointY, WhitePointZ: Single; RangeAMin, RangeAMax, RangeBMin, RangeBMax: Single): AnsiString;
C++ 구문:
AnsiString RegisterLabColorSpace(float WhitePointX, float WhitePointY, float WhitePointZ, float RangeAMin, float RangeAMax, float RangeBMin, float RangeBMax);
설명
CIELab color space는 display 또는 printing device와 독립적으로 color를 설명합니다. L*는 [0..100] 범위의 lightness를, a*는 green/red axis를, b*는 blue/yellow axis(일반적으로 [-128..127])를 나타냅니다. Conforming PDF viewer는 configured WhitePoint illuminant를 사용해 L*a*b*를 device color로 변환합니다. Common illuminant는 다음과 같습니다
D50 - ICC print standard. WhitePoint = [0.9505, 1.0, 1.089].
D65 - sRGB / display standard. WhitePoint = [0.95047, 1.0, 1.08883].
WhitePoint Y must equal 1.0 per spec table 64; X and Z must be positive. Passing all four Range parameters as zero falls back to the spec's implicit default [-100 100 -100 100]; pass any non-zero combination to override.
반환 값: auto-generated resource name(Lab1, Lab2, ...)입니다. StrictVersionLock이 켜져 있고 active Version이 PDF 1.3보다 낮으면 빈 string을 반환합니다. 그렇지 않으면 version이 1.3으로 auto-bump됩니다
Code Example
// Register a D50 Lab space for print, paint a magenta swatch
var
CSName: AnsiString;
begin
HPDF.Version := pdf14;
HPDF.BeginDoc;
CSName := HPDF.RegisterLabColorSpace(
0.9505, 1.0, 1.089, // D50 WhitePoint
-128, 127, -128, 127); // standard a* and b* range
HPDF.CurrentPage.SetFillColorSpace(CSName);
HPDF.CurrentPage.SetFillColor([50.0, 60.0, -50.0]); // L* a* b*
HPDF.CurrentPage.Rectangle(60, 60, 200, 100);
HPDF.CurrentPage.Fill;
HPDF.EndDoc;
end;
See Also
Version, Compression, PDF Filter Support
|