?? cdecodedstream.h
字號:
//
// CDecodedStream.h
//
#ifndef __H_CDecodedStream__
#define __H_CDecodedStream__
class CFilterMpeg2Dec;
class CMpeg2Controller;
class CDecodedStream : public CSourceStream
{
friend class CFilterMpeg2Dec;
private:
CFilterMpeg2Dec * mDecodeFilter;
CMpeg2Controller * mMpeg2Controller;
// implement IMediaPosition by passing upstream
IUnknown * mPosition;
BOOL mFlushing;
ULONG mSamplesSent;
CCritSec mDataAccess;
public:
CDecodedStream(TCHAR * inObjectName, HRESULT * outResult, CFilterMpeg2Dec * inFilter);
~CDecodedStream();
void SetController(CMpeg2Controller * inController);
// override to expose IMediaPosition
STDMETHODIMP NonDelegatingQueryInterface(REFIID riid, void **ppv);
STDMETHODIMP BeginFlush(void);
STDMETHODIMP EndFlush(void);
STDMETHODIMP EndOfStream(void);
HRESULT StopThreadSafely(void);
HRESULT RunThreadSafely(void);
protected:
// Override this to provide the worker thread a means
// of processing a buffer
virtual HRESULT FillBuffer(IMediaSample *pSample); // PURE
virtual HRESULT DecideBufferSize(IMemAllocator * pAllocator,
ALLOCATOR_PROPERTIES *pprop); // PURE
virtual HRESULT CheckMediaType(const CMediaType *mtOut);
virtual HRESULT GetMediaType(int iPosition, CMediaType *pMediaType);
// IQualityControl
STDMETHODIMP Notify(IBaseFilter * pSender, Quality q);
HRESULT CompleteConnect(IPin *pReceivePin);
STDMETHODIMP QueryId(LPWSTR * Id);
virtual HRESULT DoBufferProcessingLoop(void);
virtual HRESULT OnThreadStartPlay(void);
virtual HRESULT OnThreadDestroy(void);
HRESULT DeliverCurrentPicture(IMediaSample * pSample);
// Media type
public:
CMediaType& CurrentMediaType(void) { return m_mt; }
};
#endif // __H_CDecodedStream__
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -