Microsoft DirectX 9.0

IMediaEvent::FreeEventParams

The FreeEventParams method frees resources associated with the parameters of an event.

Syntax

HRESULT FreeEventParams(
  long lEventCode,
  long lParam1,
  long lParam2
);

Parameters

lEventCode

[in] Event code.

lParam1

[in] First event parameter.

lParam2

[in] Second event parameter.

Return Value

Returns S_OK.

Remarks

After you call the IMediaEvent::GetEvent method to retrieve an event notification, you must call FreeEventParams. This method frees any resources that were allocated for the event parameters. Pass in the same variables used for the GetEvent call.

Example Code

hr = pEvent->GetEvent(&evCode, &param1, &param2, 0);
// Handle the event (not shown). 
hr = pEvent->FreeEventParams(evCode, param1, param2);

See Also