The PCEVENT_REQUEST structure specifies an event request.
typedef struct _PCEVENT_REQUEST
{
PUNKNOWN MajorTarget;
PUNKNOWN MinorTarget;
ULONG Node;
const PCEVENT_ITEM *EventItem;
PKSEVENT_ENTRY EventEntry;
ULONG Verb;
PIRP Irp;
} PCEVENT_REQUEST, *PPCEVENT_REQUEST;
| Value | Meaning |
|---|---|
| PCEVENT_VERB_ADD | Indicates that a client wants to enable the specified event. After validating the event and target information, the EventHandler routine adds the event by calling the IPortEvents::AddEventToEventList method. |
| PCEVENT_VERB_REMOVE | Notifies the EventHandler that an event is being disabled and removed from the list. |
| PCEVENT_VERB_SUPPORT | This request is a query for support. If the miniport driver supports the event for the target identified in the request, it should succeed this query. Otherwise, it should fail the query. |
| PCEVENT_VERB_NONE | No action is needed. |
This is the structure that the port driver passes to the miniport driver's EventHandler routine. The PCEVENT_ITEM structure contains a function pointer to an event handler that takes a PCEVENT_REQUEST pointer as its only call parameter. The port driver allocates a PCEVENT_REQUEST structure, extracts the relevant information from the original event request (which the Irp member points to), and loads the information into this structure before calling the handler.
In WDM audio, the target of an event request can be a pin instance but not a filter instance. The target can also include a node ID.
The MajorTarget and MinorTarget members are IUnknown pointers to the main miniport object and an associated stream object, respectively. The event handler can query these objects for their miniport and stream interfaces.
For example, if the target for the event request is a pin instance on a WaveCyclic filter:
PCFILTER_NODE, PCEVENT_ITEM, KSEVENT_ENTRY, EventHandler, IPortEvents::AddEventToEventList