ULONG
GetKeyColourFunc(
PDEVICE_INFO pDevInfo
);
The GetKeyColourFunc function returns the current key color. The function is provided by the kernel-mode driver, and the GetKeyColourFunc name is a placeholder for a driver-specified function name.
Parameters
pDevInfo
Pointer to the DEVICE_INFO structure returned by VC_Init.
Return Value
Returns the current key color. See the following Comments section.
Comments
The VCKernel.lib library calls a kernel-mode driver's GetKeyColourFunc function when the driver receives an IOCTL_VIDC_GET_KEY_COLOUR control code. User-mode drivers using VCUser.lib send this control code by calling VC_GetKeyColour.
The driver returns the key color as either an RGBQUAD type or as a palette index number. The return type must be consistent with the value of the VCO_KEYCOLOUR_RGB flag returned by the driver's GetOverlayModeFunc function. That is, if the driver sets the flag, it must return an RGBQUAD-typed key color.
Support for a GetKeyColourFunc function is required, if the device supports a key color. If a driver does support the function, it must place its address in the VC_CALLBACK structure supplied by VCKernel.lib. If a driver that does not provide a GetKeyColourFunc function receives an IOCTL_VIDC_GET_KEY_COLOUR control code, VCKernel.lib sets the Win32 error code value to STATUS_INVALID_DEVICE_REQUEST.