CTransformFilter::InitializeOutputSample

 
Microsoft DirectShow 9.0

CTransformFilter::InitializeOutputSample

The InitializeOutputSample method retrieves a new output sample and initializes it.

Syntax

  HRESULT InitializeOutputSample(
    IMediaSample *pSample, 
    IMediaSample **ppOutSample
);

Parameters

pSample

Pointer to the input sample's IMediaSample interface.

ppOutSample

Receives a pointer to the output sample's IMediaSample interface.

Return Value

Returns S_OK or another HRESULT value.

Remarks

This method is called by the CTransformFilter::Receive method to prepare the output sample. Generally you do not have to call this method in your derived class, unless you override the Receive method.

This method retrieves a new sample from the output pin's allocator. Then it copies the sample properties from the input sample to the output sample. The sample properties are defined in the AM_SAMPLE2_PROPERTIES structure.

Requirements

**  Header:** Declared in Transfrm.h; include Streams.h.

**  Library:** Use Strmbase.lib (retail builds) or Strmbasd.lib (debug builds).

See Also