The XLATEOBJ structure is used to translate color indexes from one palette to another.
typedef struct _XLATEOBJ {
ULONG iUniq;
FLONG flXlate;
USHORT iSrcType;
USHORT iDstType;
ULONG cEntries;
ULONG *pulXlate;
} XLATEOBJ;
| Value | Meaning |
|---|---|
| XO_DEVICE_ICM | ICM is enabled on the device. The driver should translate color according to the color transform created by DrvIcmCreateColorTransform. The driver should call XLATEOBJ_hGetColorTransform to get the color transform handle. This bit is mutually exclusive from XO_HOST_ICM. |
| XO_FROM_CMYK | As a result of ICM translation, source indices are translated to the 32-bit CMYK color format. When this bit is set, iSrcType, iDstType, cEntries, and pulXlate should be ignored. |
| XO_HOST_ICM | ICM is performed by the graphics engine, so the colors in this color table are corrected to the target surface. This bit is set by the GDI as information for the driver: no action is required by the driver. This bit is mutually exclusive from XO_DEVICE_ICM. |
| XO_TABLE | A table is provided to translate source indices to target indices. |
| XO_TO_MONO | Source indices are translated to a monochrome format with the special property that all indices map to zero, except for one. A driver can use this to accelerate a block transfer. |
| XO_TRIVIAL | Source indices are usable as target indices. |
Declared in winddi.h. Include winddi.h.
The destination palette always belongs to the destination surface of some drawing operation. The source palette is an application-selected palette or a palette from another surface.
The XLATEOBJ structure is used to translate color indices that refer to the source palette to indices for the destination palette. The resulting index identifies a color that matches the source color as closely as possible.
XLATEOBJ_piVector, XLATEOBJ_cGetPalette, DrvIcmCreateColorTransform, XLATEOBJ_hGetColorTransform