CBaseFilter Class Reference

#include <amfilter.h>

Inheritance diagram for CBaseFilter:

CUnknown CBaseObject CAsyncReader CBaseRenderer CSource CTransformFilter fsFileReader CBaseVideoRenderer CTransInPlaceFilter CVideoTransformFilter

List of all members.

Public Member Functions

 CBaseFilter (const TCHAR *pName, LPUNKNOWN pUnk, CCritSec *pLock, REFCLSID clsid)
 CBaseFilter (TCHAR *pName, LPUNKNOWN pUnk, CCritSec *pLock, REFCLSID clsid, HRESULT *phr)
 ~CBaseFilter ()
DECLARE_IUNKNOWN STDMETHODIMP NonDelegatingQueryInterface (REFIID riid, void **ppv)
STDMETHODIMP GetClassID (CLSID *pClsID)
STDMETHODIMP GetState (DWORD dwMSecs, FILTER_STATE *State)
STDMETHODIMP SetSyncSource (IReferenceClock *pClock)
STDMETHODIMP GetSyncSource (IReferenceClock **pClock)
STDMETHODIMP Stop ()
STDMETHODIMP Pause ()
STDMETHODIMP Run (REFERENCE_TIME tStart)
virtual HRESULT StreamTime (CRefTime &rtStream)
BOOL IsActive ()
BOOL IsStopped ()
STDMETHODIMP EnumPins (IEnumPins **ppEnum)
STDMETHODIMP FindPin (LPCWSTR Id, IPin **ppPin)
STDMETHODIMP QueryFilterInfo (FILTER_INFO *pInfo)
STDMETHODIMP JoinFilterGraph (IFilterGraph *pGraph, LPCWSTR pName)
STDMETHODIMP QueryVendorInfo (LPWSTR *pVendorInfo)
HRESULT NotifyEvent (long EventCode, LONG_PTR EventParam1, LONG_PTR EventParam2)
IFilterGraph * GetFilterGraph ()
HRESULT ReconnectPin (IPin *pPin, AM_MEDIA_TYPE const *pmt)
virtual LONG GetPinVersion ()
void IncrementPinVersion ()
virtual int GetPinCount () PURE
virtual CBasePinGetPin (int n) PURE
STDMETHODIMP Register ()
STDMETHODIMP Unregister ()
virtual LPAMOVIESETUP_FILTER GetSetupData ()

Protected Attributes

FILTER_STATE m_State
IReferenceClock * m_pClock
CRefTime m_tStart
CLSID m_clsid
CCritSecm_pLock
WCHARm_pName
IFilterGraph * m_pGraph
IMediaEventSink * m_pSink
LONG m_PinVersion

Friends

class CBasePin


Detailed Description

Definition at line 95 of file amfilter.h.


Constructor & Destructor Documentation

CBaseFilter::CBaseFilter ( const TCHAR pName,
LPUNKNOWN  pUnk,
CCritSec pLock,
REFCLSID  clsid 
)

Definition at line 224 of file amfilter.cpp.

References ASSERT, and NULL.

CBaseFilter::CBaseFilter ( TCHAR pName,
LPUNKNOWN  pUnk,
CCritSec pLock,
REFCLSID  clsid,
HRESULT *  phr 
)

Definition at line 242 of file amfilter.cpp.

References ASSERT, and NULL.

CBaseFilter::~CBaseFilter (  ) 

Definition at line 301 of file amfilter.cpp.

References m_pClock, m_pName, and NULL.


Member Function Documentation

STDMETHODIMP CBaseFilter::NonDelegatingQueryInterface ( REFIID  riid,
void **  ppv 
)

Reimplemented from CUnknown.

Reimplemented in CBaseRenderer.

Definition at line 197 of file amfilter.cpp.

References GetInterface(), and CUnknown::NonDelegatingQueryInterface().

Referenced by CBaseRenderer::NonDelegatingQueryInterface().

STDMETHODIMP CBaseFilter::GetClassID ( CLSID pClsID  ) 

Definition at line 312 of file amfilter.cpp.

References CheckPointer, m_clsid, and ValidateReadWritePtr.

STDMETHODIMP CBaseFilter::GetState ( DWORD  dwMSecs,
FILTER_STATE *  State 
)

STDMETHODIMP CBaseFilter::SetSyncSource ( IReferenceClock *  pClock  ) 

Definition at line 332 of file amfilter.cpp.

References m_pClock, and m_pLock.

STDMETHODIMP CBaseFilter::GetSyncSource ( IReferenceClock **  pClock  ) 

Definition at line 350 of file amfilter.cpp.

References CheckPointer, m_pClock, m_pLock, and ValidateReadWritePtr.

STDMETHODIMP CBaseFilter::Stop (  ) 

Reimplemented in CBaseRenderer, and CTransformFilter.

Definition at line 365 of file amfilter.cpp.

References c, FAILED, GetPin(), GetPinCount(), hr, HRESULT, CBasePin::Inactive(), CBasePin::IsConnected(), m_pLock, and m_State.

Referenced by CBaseRenderer::Stop().

STDMETHODIMP CBaseFilter::Pause (  ) 

STDMETHODIMP CBaseFilter::Run ( REFERENCE_TIME  tStart  ) 

Reimplemented in CBaseRenderer.

Definition at line 415 of file amfilter.cpp.

References c, FAILED, GetPin(), GetPinCount(), hr, HRESULT, CBasePin::IsConnected(), m_pLock, m_State, m_tStart, Pause(), CBasePin::Run(), and S_OK.

Referenced by CBaseRenderer::Run().

HRESULT CBaseFilter::StreamTime ( CRefTime rtStream  )  [virtual]

Definition at line 449 of file amfilter.cpp.

References FAILED, hr, HRESULT, m_pClock, m_tStart, NULL, and S_OK.

BOOL CBaseFilter::IsActive (  )  [inline]

Definition at line 186 of file amfilter.h.

References CBasePin::m_pLock.

Referenced by CSourceStream::Active(), and CBaseRenderer::PrepareReceive().

BOOL CBaseFilter::IsStopped (  )  [inline]

Definition at line 192 of file amfilter.h.

Referenced by CTransInPlaceOutputPin::CheckMediaType().

STDMETHODIMP CBaseFilter::EnumPins ( IEnumPins **  ppEnum  ) 

Definition at line 467 of file amfilter.cpp.

References CheckPointer, E_OUTOFMEMORY, NULL, and ValidateReadWritePtr.

STDMETHODIMP CBaseFilter::FindPin ( LPCWSTR  Id,
IPin **  ppPin 
)

STDMETHODIMP CBaseFilter::QueryFilterInfo ( FILTER_INFO *  pInfo  ) 

Definition at line 505 of file amfilter.cpp.

References CheckPointer, lstrcpynW, m_pGraph, m_pName, and ValidateReadWritePtr.

STDMETHODIMP CBaseFilter::JoinFilterGraph ( IFilterGraph *  pGraph,
LPCWSTR  pName 
)

Reimplemented in CBaseVideoRenderer.

Definition at line 522 of file amfilter.cpp.

References ASSERT, FAILED, hr, HRESULT, lstrlenW, m_pGraph, m_pLock, m_pName, m_pSink, and NULL.

Referenced by CBaseVideoRenderer::JoinFilterGraph().

STDMETHODIMP CBaseFilter::QueryVendorInfo ( LPWSTR pVendorInfo  ) 

Definition at line 560 of file amfilter.cpp.

HRESULT CBaseFilter::NotifyEvent ( long  EventCode,
LONG_PTR  EventParam1,
LONG_PTR  EventParam2 
)

IFilterGraph* CBaseFilter::GetFilterGraph (  )  [inline]

Definition at line 235 of file amfilter.h.

HRESULT CBaseFilter::ReconnectPin ( IPin *  pPin,
AM_MEDIA_TYPE const *  pmt 
)

Definition at line 587 of file amfilter.cpp.

References E_NOINTERFACE, hr, HRESULT, m_pGraph, and NULL.

Referenced by CTransInPlaceFilter::CompleteConnect().

LONG CBaseFilter::GetPinVersion (  )  [virtual]

void CBaseFilter::IncrementPinVersion (  ) 

Definition at line 612 of file amfilter.cpp.

References m_PinVersion.

virtual int CBaseFilter::GetPinCount (  )  [virtual]

virtual CBasePin* CBaseFilter::GetPin ( int  n  )  [virtual]

STDMETHODIMP CBaseFilter::Register (  ) 

Definition at line 617 of file amfilter.cpp.

References AMovieSetupRegisterFilter(), ASSERT, GetSetupData(), hr, HRESULT, LPVOID, NULL, S_FALSE, and TRUE.

STDMETHODIMP CBaseFilter::Unregister (  ) 

Definition at line 645 of file amfilter.cpp.

References AMovieSetupRegisterFilter(), ASSERT, FALSE, GetSetupData(), hr, HRESULT, LPVOID, NULL, and S_FALSE.

virtual LPAMOVIESETUP_FILTER CBaseFilter::GetSetupData (  )  [inline, virtual]

Definition at line 262 of file amfilter.h.

References NULL.

Referenced by Register(), and Unregister().


Friends And Related Function Documentation

friend class CBasePin [friend]

Definition at line 100 of file amfilter.h.


Member Data Documentation

FILTER_STATE CBaseFilter::m_State [protected]

IReferenceClock* CBaseFilter::m_pClock [protected]

Definition at line 105 of file amfilter.h.

Referenced by Run(), and StreamTime().

Definition at line 106 of file amfilter.h.

Referenced by GetClassID().

Definition at line 108 of file amfilter.h.

Referenced by FindPin(), GetSyncSource(), JoinFilterGraph(), Pause(), Run(), SetSyncSource(), and Stop().

Definition at line 110 of file amfilter.h.

Referenced by JoinFilterGraph(), QueryFilterInfo(), and ~CBaseFilter().

IFilterGraph* CBaseFilter::m_pGraph [protected]

IMediaEventSink* CBaseFilter::m_pSink [protected]

Definition at line 112 of file amfilter.h.

Referenced by JoinFilterGraph(), and NotifyEvent().

Definition at line 113 of file amfilter.h.

Referenced by GetPinVersion(), and IncrementPinVersion().


The documentation for this class was generated from the following files:

Generated on Sun May 25 00:20:34 2008 by  doxygen 1.5.6