Code can set the color keys for surface when created
Figure 10-4: Transparency using source and destination color keys
DWORD dwFlags, // 1
LPDDCOLORKEY lpDDColorKey // 2
Action |
---|
DDCKEY_COLORSPACE
DDCKEY_DESTBLT
The structure specifies a color key or color space to be used as a destination color key for blit operations.
The structure specifies a color key or color space to be used as a destination color key for overlay operations.
DirectDrawSurface object. If this value is NULL, then the existing color key is removed from
the surface.
DDERR_INVALIDPARAMS
DDERR_INVALIDSURFACETYPE