Simplify.

This commit is contained in:
Steve Checkoway
2006-10-11 11:12:09 +00:00
parent 35a20193ef
commit 6fd4694b79
5 changed files with 6 additions and 27 deletions
+1 -5
View File
@@ -426,11 +426,7 @@ void LightsManager::ChangeTestCabinetLight( int iDir )
m_iControllerTestManualCycleCurrent = -1;
m_clTestManualCycleCurrent = (CabinetLight)(m_clTestManualCycleCurrent+iDir);
{
int temp = m_clTestManualCycleCurrent;
wrap( temp, NUM_CabinetLight );
m_clTestManualCycleCurrent = CabinetLight( temp );
}
wrap( UnionCast(m_clTestManualCycleCurrent), NUM_CabinetLight );
}
void LightsManager::ChangeTestGameButtonLight( int iDir )
+1 -5
View File
@@ -1161,11 +1161,7 @@ void Profile::LoadGeneralDataFromNode( const XNode* pNode )
pNode->GetChildValue( "TotalGameplaySeconds", m_iTotalGameplaySeconds );
pNode->GetChildValue( "CurrentCombo", m_iCurrentCombo );
pNode->GetChildValue( "TotalCaloriesBurned", m_fTotalCaloriesBurned );
{
int temp;
pNode->GetChildValue( "GoalType", temp );
m_GoalType = GoalType( temp );
}
pNode->GetChildValue( "GoalType", UnionCast(m_GoalType) );
pNode->GetChildValue( "GoalCalories", m_iGoalCalories );
pNode->GetChildValue( "GoalSeconds", m_iGoalSeconds );
pNode->GetChildValue( "LastPlayedMachineGuid", m_sLastPlayedMachineGuid );
+1 -5
View File
@@ -406,11 +406,7 @@ void ScreenTextEntryVisual::MoveY( int iDir )
do
{
m_iFocusY = enum_add2( m_iFocusY, +iDir );
{
int temp = m_iFocusY;
wrap( temp, NUM_KeyboardRow );
m_iFocusY = KeyboardRow( temp );
}
wrap( UnionCast(m_iFocusY), NUM_KeyboardRow );
// HACK: Round to nearest option so that we always stop
// on KEYBOARD_ROW_SPECIAL.
@@ -589,10 +589,7 @@ void MovieDecoder_FFMpeg::Close()
RageSurface *MovieDecoder_FFMpeg::CreateCompatibleSurface( int iTextureWidth, int iTextureHeight, bool bPreferHighColor )
{
int temp = m_AVTexfmt;
RageSurface *surface = MovieTexture_FFMpeg::AVCodecCreateCompatibleSurface( iTextureWidth, iTextureHeight, bPreferHighColor, temp );
m_AVTexfmt = avcodec::PixelFormat( temp );
return surface;
return MovieTexture_FFMpeg::AVCodecCreateCompatibleSurface( iTextureWidth, iTextureHeight, bPreferHighColor, UnionCast(m_AVTexfmt) );
}
MovieTexture_FFMpeg::MovieTexture_FFMpeg( RageTextureID ID ):
@@ -267,10 +267,7 @@ int MovieDecoder_Theora::GetFrame( RageSurface *pOut, float fTargetTime )
RageSurface *MovieDecoder_Theora::CreateCompatibleSurface( int iTextureWidth, int iTextureHeight, bool bPreferHighColor )
{
int temp = m_OutputPixFmt;
RageSurface *surface = MovieTexture_FFMpeg::AVCodecCreateCompatibleSurface( iTextureWidth, iTextureHeight, bPreferHighColor, temp );
m_OutputPixFmt = avcodec::PixelFormat( temp );
return surface;
return MovieTexture_FFMpeg::AVCodecCreateCompatibleSurface( iTextureWidth, iTextureHeight, bPreferHighColor, UnionCast(m_OutputPixFmt) );
}
void MovieDecoder_Theora::ConvertToSurface( RageSurface *pSurface ) const
@@ -607,10 +604,7 @@ int MovieDecoder_Theora::GetFrame( RageSurface *pOut, float fTargetTime )
RageSurface *MovieDecoder_Theora::CreateCompatibleSurface( int iTextureWidth, int iTextureHeight, bool bPreferHighColor )
{
int temp = m_OutputPixFmt;
RageSurface *surface = MovieTexture_FFMpeg::AVCodecCreateCompatibleSurface( iTextureWidth, iTextureHeight, bPreferHighColor, temp );
m_OutputPixFmt = avcodec::PixelFormat( temp );
return surface;
return MovieTexture_FFMpeg::AVCodecCreateCompatibleSurface( iTextureWidth, iTextureHeight, bPreferHighColor, UnionCast(m_OutputPixFmt) );
}
void MovieDecoder_Theora::DecodeStripeStub( void *pCtx, theora_ycbcr_buffer yuv, int yfrag0, int yfrag_end )