Xojo Developer Conference
25/27th April 2018 in Denver.
MBS Xojo Conference
6/7th September 2018 in Munich, Germany.

DynaPDF Manual - Page 471

Previous Page 470   Index   Next Page 472

Function Reference
Page 471 of 750
Although Black Point Compensation (BPC) is not enabled by default, it is recommended to enable it
because it improves the rendering quality of CMYK images a lot.
Remarks:
All profile paths must be absolute paths. Otherwise it is maybe not possible to reload a profile if
necessary. DynaPDF must be able to reload the profiles if a PDF file contains ICCBased color spaces.
Initializing the color management requires a considerable amount of processing time. It is strongly
recommended to use one PDF instance as long as possible so that it must not be initialized again
when another PDF file will be rendered.
The color management can be initialized right after the PDF instance was created.
Return values:
If the function succeeds the return value is 1. If the function fails the return value is 0.
InitColorManagementEx
Syntax:
LBOOL pdfInitColorManagementEx(
const PPDF* IPDF,
// Instance pointer
struct TPDFColorProfilesEx* Profiles, // Color profiles or NULL
TPDFColorSpace DestSpace,
// Destination color space
TPDFInitCMFlags Flags)
// See below
struct TPDFColorProfilesEx
{
UI32
StructSize;
// Must be set to sizeof(TPDFColorProfilesEx)
const void* DefInGray;
// Optional
UI32
DefInGrayLen;
// Optional
const void* DefInRGB;
// Optional
UI32
DefInRGBLen;
// Optional
const void* DefInCMYK;
// Optional, but this is the most important
UI32
DefInCMYKLen;
// but this is the most important profile.
const void* DeviceProfile;
// Optional, must be compatible with the output color
UI32
DeviceProfileLen; // space. Default is sRGB.
const void* SoftProof;
// Optional, emulates another output device.
UI32
SoftProofLen;
// Optional.
};
typedef enum
{
icmDefault
= 0, // Default rules.
icmBPCompensation = 1, // Black point compensation preserves the black
// point when converting CMYK colors to
// different color spaces.
icmCheckBlackPoint = 2 // If set, soft proofing will be disabled if the
// black point of the output intent is probably
// invalid. The limit is 35 for L* measured in
// Lab color space.
}TPDFInitCMFlags;
 

Previous topic: InitColorManagement

Next topic: InitOCGContUsage