Share via


CBaseAllocator::ReleaseBuffer (Compact 2013)

3/26/2014

Releases the object back to the list of free objects.

Syntax

HRESULT ReleaseBuffer(
  IMediaSample* pSample
); 

Parameters

  • pSample
    Pointer to the IMediaSample interface of the media sample object.

Return Value

None.

Remarks

This member function implements the IMemAllocator::ReleaseBuffer method.

It adds the sample to the free list (represented by m_lFree) and calls CBaseAllocator::NotifySample to notify any blocked thread waiting for a free sample.

If there is a pending CBaseAllocator::Decommit call (indicated by m_bDecommitInProgress), the pure virtual CBaseAllocator::Free member function is called to decommit memory when the last buffer is placed on the free list.

Requirements

Header

dshow.h,
Streams.h

Library

ole32.lib,
Ole32auth.lib,
Strmbase.lib,
Strmiids.lib,
uuid.lib

See Also

Reference

CBaseAllocator Class