Platform SDK: Broadcast Architecture

Handling Power Management Events

Computers that implement advanced power management or the Advanced Configuration and Power Interface (ACPI) cause Windows 98 to request that the Video Access server and Video controls suspend operation when the computer enters the sleeping state. In handling the Video control's power management events, your application should not attempt to access the Video control or devices while they are unavailable.

When the Video Access server receives a suspension request from the power management system, it releases all devices and destroys the filter graph. Each instance of the Video control sends a BPCVid.Power event to its container, specifying the value PBT_APMQUERYSUSPEND, which indicates that the power management system is requesting permission to suspend. Applications should not call the Video control or devices until they receive one of the following values in a subsequent Power event:

When your application receives one of these values, it can resume use of the Video control and server. Because the filter graph is rebuilt after suspension, your application must re-enumerate devices and refresh any device information it had stored.

If the value returned in the Power event is PBT_APMQUERYSUSPENDFAILED, the operation was not suspended, because another application overrode the suspension request.