Richard Boegli's CnC_Generals_Zero_Hour Fork WIP
This is documentation of Richard Boegil's Zero Hour Fork
 
Loading...
Searching...
No Matches
CSimplePlayer Class Reference

#include <simpleplayer.h>

Inherits IWMReaderCallback.

Public Member Functions

 CSimplePlayer (HRESULT *phr)
 
 ~CSimplePlayer ()
 
virtual HRESULT Play (LPCWSTR pszUrl, DWORD dwSecDuration, HANDLE hCompletionEvent, HRESULT *phrCompletion)
 
virtual HRESULT STDMETHODCALLTYPE QueryInterface (REFIID riid, void **ppvObject)
 
virtual ULONG STDMETHODCALLTYPE AddRef ()
 
virtual ULONG STDMETHODCALLTYPE Release ()
 
virtual HRESULT STDMETHODCALLTYPE OnSample (DWORD dwOutputNum, QWORD cnsSampleTime, QWORD cnsSampleDuration, DWORD dwFlags, INSSBuffer __RPC_FAR *pSample, void __RPC_FAR *pvContext)
 
virtual HRESULT STDMETHODCALLTYPE OnStatus (WMT_STATUS Status, HRESULT hr, WMT_ATTR_DATATYPE dwType, BYTE __RPC_FAR *pValue, void __RPC_FAR *pvContext)
 

Protected Member Functions

HRESULT Close ()
 
void OnWaveOutMsg (UINT uMsg, DWORD dwParam1, DWORD dwParam2)
 
HRESULT AddWaveHeader (LPWAVEHDR pwh)
 
void RemoveWaveHeaders (void)
 

Static Protected Member Functions

static void CALLBACK WaveProc (HWAVEOUT hwo, UINT uMsg, DWORD dwInstance, DWORD dwParam1, DWORD dwParam2)
 

Protected Attributes

CRITICAL_SECTION m_CriSec
 
WAVEHDR_LISTm_whdrHead
 
LONG m_cRef
 
LONG m_cBuffersOutstanding
 
BOOL m_fEof
 
HANDLE m_hCompletionEvent
 
IWMReader * m_pReader
 
IWMHeaderInfo * m_pHeader
 
HWAVEOUT m_hwo
 
HRESULT * m_phrCompletion
 
HRESULT m_hrOpen
 
HANDLE m_hOpenEvent
 
HANDLE m_hCloseEvent
 
union { 
 
   WAVEFORMATEX   m_wfx 
 
   BYTE   m_WfxBuf [1024] 
 
};  
 
LPWSTR m_pszUrl
 

Detailed Description

Definition at line 38 of file simpleplayer.h.

Constructor & Destructor Documentation

◆ CSimplePlayer()

CSimplePlayer::CSimplePlayer ( HRESULT * phr)

Definition at line 25 of file simpleplayer.cpp.

◆ ~CSimplePlayer()

CSimplePlayer::~CSimplePlayer ( )

Definition at line 61 of file simpleplayer.cpp.

Member Function Documentation

◆ AddRef()

ULONG STDMETHODCALLTYPE CSimplePlayer::AddRef ( )
virtual

Definition at line 113 of file simpleplayer.cpp.

◆ AddWaveHeader()

HRESULT CSimplePlayer::AddWaveHeader ( LPWAVEHDR pwh)
protected

Definition at line 676 of file simpleplayer.cpp.

◆ Close()

HRESULT CSimplePlayer::Close ( )
protected

Definition at line 623 of file simpleplayer.cpp.

◆ OnSample()

HRESULT STDMETHODCALLTYPE CSimplePlayer::OnSample ( DWORD dwOutputNum,
QWORD cnsSampleTime,
QWORD cnsSampleDuration,
DWORD dwFlags,
INSSBuffer __RPC_FAR * pSample,
void __RPC_FAR * pvContext )
virtual

Definition at line 134 of file simpleplayer.cpp.

◆ OnStatus()

HRESULT STDMETHODCALLTYPE CSimplePlayer::OnStatus ( WMT_STATUS Status,
HRESULT hr,
WMT_ATTR_DATATYPE dwType,
BYTE __RPC_FAR * pValue,
void __RPC_FAR * pvContext )
virtual

Definition at line 501 of file simpleplayer.cpp.

◆ OnWaveOutMsg()

void CSimplePlayer::OnWaveOutMsg ( UINT uMsg,
DWORD dwParam1,
DWORD dwParam2 )
protected

Definition at line 642 of file simpleplayer.cpp.

◆ Play()

HRESULT CSimplePlayer::Play ( LPCWSTR pszUrl,
DWORD dwSecDuration,
HANDLE hCompletionEvent,
HRESULT * phrCompletion )
virtual

Definition at line 217 of file simpleplayer.cpp.

◆ QueryInterface()

HRESULT STDMETHODCALLTYPE CSimplePlayer::QueryInterface ( REFIID riid,
void ** ppvObject )
virtual

Definition at line 104 of file simpleplayer.cpp.

◆ Release()

ULONG STDMETHODCALLTYPE CSimplePlayer::Release ( )
virtual

Definition at line 120 of file simpleplayer.cpp.

◆ RemoveWaveHeaders()

void CSimplePlayer::RemoveWaveHeaders ( void )
protected

Definition at line 693 of file simpleplayer.cpp.

◆ WaveProc()

void CALLBACK CSimplePlayer::WaveProc ( HWAVEOUT hwo,
UINT uMsg,
DWORD dwInstance,
DWORD dwParam1,
DWORD dwParam2 )
staticprotected

Definition at line 663 of file simpleplayer.cpp.

Member Data Documentation

◆ [union]

union { ... } CSimplePlayer

◆ m_cBuffersOutstanding

LONG CSimplePlayer::m_cBuffersOutstanding
protected

Definition at line 99 of file simpleplayer.h.

◆ m_cRef

LONG CSimplePlayer::m_cRef
protected

Definition at line 98 of file simpleplayer.h.

◆ m_CriSec

CRITICAL_SECTION CSimplePlayer::m_CriSec
protected

Definition at line 95 of file simpleplayer.h.

◆ m_fEof

BOOL CSimplePlayer::m_fEof
protected

Definition at line 100 of file simpleplayer.h.

◆ m_hCloseEvent

HANDLE CSimplePlayer::m_hCloseEvent
protected

Definition at line 111 of file simpleplayer.h.

◆ m_hCompletionEvent

HANDLE CSimplePlayer::m_hCompletionEvent
protected

Definition at line 101 of file simpleplayer.h.

◆ m_hOpenEvent

HANDLE CSimplePlayer::m_hOpenEvent
protected

Definition at line 110 of file simpleplayer.h.

◆ m_hrOpen

HRESULT CSimplePlayer::m_hrOpen
protected

Definition at line 109 of file simpleplayer.h.

◆ m_hwo

HWAVEOUT CSimplePlayer::m_hwo
protected

Definition at line 105 of file simpleplayer.h.

◆ m_pHeader

IWMHeaderInfo* CSimplePlayer::m_pHeader
protected

Definition at line 104 of file simpleplayer.h.

◆ m_phrCompletion

HRESULT* CSimplePlayer::m_phrCompletion
protected

Definition at line 107 of file simpleplayer.h.

◆ m_pReader

IWMReader* CSimplePlayer::m_pReader
protected

Definition at line 103 of file simpleplayer.h.

◆ m_pszUrl

LPWSTR CSimplePlayer::m_pszUrl
protected

Definition at line 119 of file simpleplayer.h.

◆ m_wfx

WAVEFORMATEX CSimplePlayer::m_wfx

Definition at line 115 of file simpleplayer.h.

◆ m_WfxBuf

BYTE CSimplePlayer::m_WfxBuf[1024]

Definition at line 116 of file simpleplayer.h.

◆ m_whdrHead

WAVEHDR_LIST* CSimplePlayer::m_whdrHead
protected

Definition at line 96 of file simpleplayer.h.


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