IMFVideoSampleAllocatorEx::InitializeSampleAllocatorEx Method

Initializes the video sample allocator object.

Syntax

public:
HRESULT InitializeSampleAllocatorEx(
         DWORD cInitialSamples,
         DWORD cMaximumSamples,
         IMFAttributes *pAttributes,
         IMFMediaType *pMediaType
)  

Parameters

cInitialSamples
Type: DWORD 

The initial number of samples to allocate.

cMaximumSamples
Type: DWORD 

The maximum number of samples to allocate.

pAttributes
Type: IMFAttributes *

A pointer to the IMFAttributes interface. You can use this interface to configure the allocator. Currently, the following configuration attributes are defined:

pMediaType
Type: IMFMediaType *

A pointer to the IMFMediaType interface of a media type that describes the video format.

Return value

Type: HRESULT 

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Refer to Media Foundation return codes.

Requirements

Header: Declared in mfidl.h.