次の方法で共有


IMediaStream::AllocateSample (Compact 2013)

3/26/2014

This method allocates a new stream sample object for the current media stream.

Syntax

HRESULT AllocateSample(
  DWORD dwFlags,
  IStreamSample** ppSample
);

Parameters

  • dwFlags
    [in] Flags. Must be zero.
  • ppSample
    [out] Address of a pointer to the newly created stream sample's IStreamSample interface.

Return Value

Returns one of the following values.

Value

Description

E_OUTOFMEMORY

There is not enough memory available to create a stream sample.

E_POINTER

A parameter is invalid.

S_OK

Success.

Remarks

This method allocates the sample and its associated backing object or buffer.

The backing object is either the Microsoft DirectDraw® surface for video or the IAudioData object for audio.

Requirements

Header

dshow.h

Library

Strmiids.lib

See Also

Reference

IMediaStream Interface