PVIDEO_HW_POWER_GET callback function (video.h)

HwVidGetPowerState queries whether the device can support the requested power state.

Syntax

PVIDEO_HW_POWER_GET PvideoHwPowerGet;

VP_STATUS PvideoHwPowerGet(
  PVOID HwDeviceExtension,
  ULONG HwId,
  PVIDEO_POWER_MANAGEMENT VideoPowerControl
)
{...}

Parameters

HwDeviceExtension

Pointer to the miniport driver's per-adapter storage area. For more information, see Device Extensions.

HwId

Pointer to a 32-bit device ID that uniquely identifies the device that the miniport driver should query. This parameter is returned by the miniport driver's HwVidGetVideoChildDescriptor function. Alternatively, a value of DISPLAY_ADAPTER_HW_ID indicates that power information is being requested of the adapter itself.

VideoPowerControl

Pointer to a VIDEO_POWER_MANAGEMENT structure that specifies the power state for which support is being queried.

Return value

HwVidGetPowerState returns one of the following values:

Return code Description
NO_ERROR The device supports the requested power state.
ERROR_DEVICE_REINITIALIZATION_NEEDED The driver failed the power state query.

Remarks

HwVidGetPowerState is a required function in a video miniport driver.

The driver should check the ID specified in HwId to determine which device to query. The driver should then determine whether that device supports the power state specified in the PowerState member of the VIDEO_POWER_MANAGEMENT structure to which VideoPowerControl points.

This function must not return the current power state of the device.

HwVidGetPowerState should be made pageable.

Requirements

Requirement Value
Target Platform Desktop
Header video.h (include Video.h)

See also

HwVidGetVideoChildDescriptor

HwVidSetPowerState

VIDEO_POWER_MANAGEMENT