The KsFilterGenerateEvents function generates events of an indicated type that are present in Filter's event list.
void _inline KsFilterGenerateEvents( _In_ PKSFILTER Filter, _In_opt_ const GUID *EventSet, _In_ ULONG EventId, _In_ ULONG DataSize, _In_ PVOID Data, _In_opt_ PFNKSGENERATEEVENTCALLBACK CallBack, _In_opt_ PVOID CallBackContext );
A pointer to a KSFILTER structure on which to generate events.
A pointer to the event set GUID to match for determination of which events to generate. If this parameter is NULL, the event set GUID is not taken into account for determining matching events.
The event ID to match for determining which events to generate.
The size of Data in bytes.
A pointer to a data buffer. Specify if generating a data event.
A pointer to a caller-specified function that is called to determine whether a given event should be generated. If this is NULL, no callback verification is performed to determine whether an event should be generated (only EventSet and EventId are used). For more information, see the Remarks section below.
An optional pointer to a caller-specified context that is passed to the callback function CallBack. For more information, see the Remarks section below.
When calling this function, a minidriver must place Data and CallBackContext in a locked, nonpageable data segment. In addition, note that the CallBack is made at DISPATCH_LEVEL. The callback function must be in a locked segment and must be prepared to run at IRQL = DISPATCH_LEVEL. Note that there is an additional issue in DX8 only: EventSet must be in a locked data segment.
This is an inline function call to KsGenerateEvents that performs the necessary typecasting. Minidrivers should usually call this version instead of directly calling KsGenerateEvents.
An event is generated if the following conditions hold:
The event is present in Filter's event list and EventId matches the event's ID
EventSet either matches the event's set GUID or is NULL
CallBack is either NULL or authorizes the match
BOOLEAN CallBack (IN PVOID Context, IN PKSEVENT_ENTRY EventEntry);
|Windows version||Available in Microsoft Windows XP and later operating systems and DirectX 8.0 and later DirectX versions.|
|Header||ks.h (include Ks.h)|
|IRQL||"<=DISPATCH_LEVEL (See Remarks section.)"|