cleanup
This commit is contained in:
@@ -248,15 +248,15 @@ bool RageMovieTexture::PlayMovie()
|
|||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
void RageMovieTexture::CheckMovieStatus()
|
void RageMovieTexture::CheckMovieStatus()
|
||||||
{
|
{
|
||||||
long lEventCode;
|
if(!m_bLoop) return;
|
||||||
long lParam1;
|
|
||||||
long lParam2;
|
|
||||||
|
|
||||||
// Check for completion events
|
// Check for completion events
|
||||||
CComPtr<IMediaEvent> pME;
|
CComPtr<IMediaEvent> pME;
|
||||||
m_pGB.QueryInterface(&pME);
|
m_pGB.QueryInterface(&pME);
|
||||||
|
|
||||||
|
long lEventCode, lParam1, lParam2;
|
||||||
pME->GetEvent( &lEventCode, &lParam1, &lParam2, 0 );
|
pME->GetEvent( &lEventCode, &lParam1, &lParam2, 0 );
|
||||||
if( EC_COMPLETE == lEventCode && m_bLoop )
|
if( EC_COMPLETE == lEventCode )
|
||||||
SetPosition(0);
|
SetPosition(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -267,19 +267,16 @@ void RageMovieTexture::Play()
|
|||||||
|
|
||||||
void RageMovieTexture::Pause()
|
void RageMovieTexture::Pause()
|
||||||
{
|
{
|
||||||
LOG->Trace("RageMovieTexture::Pause()");
|
|
||||||
CComPtr<IMediaControl> pMC;
|
CComPtr<IMediaControl> pMC;
|
||||||
m_pGB.QueryInterface(&pMC);
|
m_pGB.QueryInterface(&pMC);
|
||||||
|
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
if( FAILED( hr = pMC->Pause() ) )
|
if( FAILED( hr = pMC->Pause() ) )
|
||||||
throw RageException( hr_ssprintf(hr, "Could not pause the DirectShow graph.") );
|
throw RageException( hr_ssprintf(hr, "Could not pause the DirectShow graph.") );
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void RageMovieTexture::Stop()
|
void RageMovieTexture::Stop()
|
||||||
{
|
{
|
||||||
LOG->Trace("RageMovieTexture::Stop()");
|
|
||||||
CComPtr<IMediaControl> pMC;
|
CComPtr<IMediaControl> pMC;
|
||||||
m_pGB.QueryInterface(&pMC);
|
m_pGB.QueryInterface(&pMC);
|
||||||
|
|
||||||
@@ -292,7 +289,6 @@ void RageMovieTexture::Stop()
|
|||||||
|
|
||||||
void RageMovieTexture::SetPosition( float fSeconds )
|
void RageMovieTexture::SetPosition( float fSeconds )
|
||||||
{
|
{
|
||||||
LOG->Trace("RageMovieTexture::Stop()");
|
|
||||||
CComPtr<IMediaPosition> pMP;
|
CComPtr<IMediaPosition> pMP;
|
||||||
m_pGB.QueryInterface(&pMP);
|
m_pGB.QueryInterface(&pMP);
|
||||||
pMP->put_CurrentPosition(0);
|
pMP->put_CurrentPosition(0);
|
||||||
|
|||||||
Reference in New Issue
Block a user