Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

In order to use colors keys when calling IDirectDrawSurface::Blt, you pass one or both of the DDBLT_KEYSRC or DDBLT_KEYDEST flags in the dwFlagsparameter.

Alternatively, you can put the appropriate color values in the ddckDestColorkeyand ddckSrcColorkeymembers of the DDBLTFXstructure that is passed to the method through the lpDDBltFxparameter.

In this case you must also set the DBLT_KEYSRCOVERRIDE or DDBLT_KEYDESTOVERRIDE flag, or both, in the dwFlagsparameter, so that the selected keys are taken from the DDBLTFXstructure rather than from the surface properties.

See Also