ILMDVRSink::CreateEvents

#include "ILMDVRSink.h"

C Syntax

HRESULT ILMDVRSink_CreateEvents(pILMDVRSink, nRegistrationID, TargetProcessID, pDataWrittenEvent, pRecordingListChangedEvent)

C++ Syntax

HRESULT CreateEvents(nRegistrationID, TargetProcessID, pDataWrittenEvent, pRecordingListChangedEvent)

 

ILMDVRSink *pILMDVRSink ;

/* pointer to an interface */

long nRegistrationID;

/* events registration id */

long TargetProcessID;

/* process id of subscriber. */

OLE_HANDLE * pDataWrittenEvent;

/* pointer to handle a data write event */

OLE_HANDLE * pRecordingListChangedEvent;

/* pointer to handle a list changed event */

Creates the windows event objects used by the DVRSink to signal data write and recording list changed events.

Parameter

Description

pILMDVRSink

Pointer to an ILMDVRSink interface.

nRegistrationID

A unique identifier for this event registration.

TargetProcessID

The process id of the event subscriber.

pDataWrittenEvent

Pointer to a handle for the write event.

pRecordingListChangedEvent

Pointer to a handle for the list changed event.

Returns

S_OK

The function was successful.

<> S_OK

An error occurred. Refer to the Error Codes or the HRESULT error codes in the DirectShow documentation.

Comments

Whenever data is written to a buffer file, the windows event for the returned write event handle will be set. Likewise, when a buffer file is created or closed, the windows event for the list changed event handle will be set.

Returns S_OK if successful, otherwise a return code indicating the reason for failure:

E_OUTOFMEMORY = Memory allocation error was encountered.

Required DLLs and Libraries

LMDVRSink

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application.

Platforms

Win32, x64

See Also

Elements:

ILMDVRSink::FreeEvents, ILMDVRSink::StartChangingAttributes, ILMDVRSink::StopChangingAttributes,

Topics:

Multimedia Function Group, DVR Function Groups, Introduction to the LEADTOOLS DVR Module, DVR Module FAQs, LEAD DVR Sink Filter, Accessing the DVR Sink Object,How to Use the DVR Sink Object to Control Capture Buffer Settings (C++), How to Set Capture Buffers on More Than One Physical Disk, How to Copy Buffered DVR Data to a New File

Example

For a C example, refer to ILMDVRSink::CreateEvents Example for C

For a C++ example, refer to ILMDVRSink::CreateEvents Example for C++