From e628f744916bf02ce8700052325b4dc805431953 Mon Sep 17 00:00:00 2001 From: Chris Danford Date: Tue, 4 Oct 2005 19:45:45 +0000 Subject: [PATCH] do note coloring with tex coord shifting, not separate elements --- stepmania/src/Model.cpp | 2 +- stepmania/src/NoteDisplay.cpp | 167 +++++++++++++++++------------- stepmania/src/NoteDisplay.h | 21 +++- stepmania/src/NoteField.cpp | 2 +- stepmania/src/NoteSkinManager.cpp | 6 +- stepmania/src/NoteTypes.h | 1 - stepmania/src/RageDisplay.cpp | 4 +- stepmania/src/RageDisplay.h | 3 +- 8 files changed, 121 insertions(+), 85 deletions(-) diff --git a/stepmania/src/Model.cpp b/stepmania/src/Model.cpp index d74d6ed743..6b2153d6d7 100644 --- a/stepmania/src/Model.cpp +++ b/stepmania/src/Model.cpp @@ -358,7 +358,7 @@ void Model::DrawPrimitives() if( vTexTranslate.x != 0 || vTexTranslate.y != 0 ) { DISPLAY->TexturePushMatrix(); - DISPLAY->TextureTranslate( vTexTranslate.x, vTexTranslate.y, 0 ); + DISPLAY->TextureTranslate( vTexTranslate.x, vTexTranslate.y ); } /* There's some common code that could be folded out here, but it seems diff --git a/stepmania/src/NoteDisplay.cpp b/stepmania/src/NoteDisplay.cpp index 5441e99ee6..d0f0074ebb 100644 --- a/stepmania/src/NoteDisplay.cpp +++ b/stepmania/src/NoteDisplay.cpp @@ -12,22 +12,10 @@ #include "PlayerState.h" #include "LuaBinding.h" -enum Part -{ - PART_TAP, - PART_ADDITION, - PART_MINE, - PART_HOLD_HEAD, - PART_HOLD_TAIL, - PART_HOLD_TOP_CAP, - PART_HOLD_BODY, - PART_HOLD_BOTTOM_CAP, - NUM_PARTS -}; -const CString& PartToString( Part p ); -#define FOREACH_Part( p ) FOREACH_ENUM( Part, NUM_PARTS, p ) +const CString& NoteNotePartToString( NotePart i ); +#define FOREACH_NotePart( i ) FOREACH_ENUM( NotePart, NUM_NotePart, i ) -static const CString PartNames[] = { +static const CString NotePartNames[] = { "TapNote", "TapAddition", "TapMine", @@ -37,16 +25,17 @@ static const CString PartNames[] = { "HoldBottomCap", "HoldTail", }; -XToString( Part, NUM_PARTS ); +XToString( NotePart, NUM_NotePart ); +static const RageVector2 g_emptyVector = RageVector2( 0, 0 ); // cache struct NoteMetricCache_t { bool m_bDrawHoldHeadForTapsOnSameRow; - float m_fAnimationLengthInBeats[NUM_PARTS]; - bool m_bAnimationIsVivid[NUM_PARTS]; - bool m_bAnimationIsNoteColor[NUM_PARTS]; + float m_fAnimationLengthInBeats[NUM_NotePart]; + bool m_bAnimationIsVivid[NUM_NotePart]; + RageVector2 m_fNoteColorTextureCoordSpacing[NUM_NotePart]; bool m_bHoldHeadIsAboveWavyParts; bool m_bHoldTailIsAboveWavyParts; @@ -66,12 +55,14 @@ struct NoteMetricCache_t void NoteMetricCache_t::Load( const CString &sButton ) { m_bDrawHoldHeadForTapsOnSameRow = NOTESKIN->GetMetricB(sButton,"DrawHoldHeadForTapsOnSameRow"); - FOREACH_Part( p ) - m_fAnimationLengthInBeats[p] = NOTESKIN->GetMetricF(sButton,PartToString(p)+"AnimationLengthInBeats"); - FOREACH_Part( p ) - m_bAnimationIsVivid[p] = NOTESKIN->GetMetricB(sButton,PartToString(p)+"AnimationIsVivid"); - FOREACH_Part( p ) - m_bAnimationIsNoteColor[p] = NOTESKIN->GetMetricB(sButton,PartToString(p)+"AnimationIsNoteColor"); + FOREACH_NotePart( p ) + { + const CString s = NotePartToString(p); + m_fAnimationLengthInBeats[p] = NOTESKIN->GetMetricF(sButton,s+"AnimationLengthInBeats"); + m_bAnimationIsVivid[p] = NOTESKIN->GetMetricB(sButton,s+"AnimationIsVivid"); + m_fNoteColorTextureCoordSpacing[p].x = NOTESKIN->GetMetricF(sButton,s+"NoteColorTextureCoordSpacingX"); + m_fNoteColorTextureCoordSpacing[p].y = NOTESKIN->GetMetricF(sButton,s+"NoteColorTextureCoordSpacingY"); + } m_bHoldHeadIsAboveWavyParts = NOTESKIN->GetMetricB(sButton,"HoldHeadIsAboveWavyParts"); m_bHoldTailIsAboveWavyParts = NOTESKIN->GetMetricB(sButton,"HoldTailIsAboveWavyParts"); m_iStartDrawingHoldBodyOffsetFromHead = NOTESKIN->GetMetricI(sButton,"StartDrawingHoldBodyOffsetFromHead"); @@ -123,9 +114,9 @@ struct NoteResource static map g_NoteResource; -static NoteResource *MakeNoteResource( const CString &sButton, const CString &sElement, NoteType nt, bool bSpriteOnly ) +static NoteResource *MakeNoteResource( const CString &sButton, const CString &sElement, bool bSpriteOnly ) { - CString sElementAndType = sElement + " " + NoteTypeToString(nt); + CString sElementAndType = sElement; NoteSkinAndPath nsap( NOTESKIN->GetCurrentNoteSkin(), NOTESKIN->GetPath(sButton, sElementAndType) ); map::iterator it = g_NoteResource.find( nsap ); @@ -185,15 +176,15 @@ static void DeleteNoteResource( const Actor *pActor ) delete pRes; } -Actor *MakeRefcountedActor( const CString &sButton, const CString &sElement, NoteType nt ) +Actor *MakeRefcountedActor( const CString &sButton, const CString &sElement ) { - NoteResource *pRes = MakeNoteResource( sButton, sElement, nt, false ); + NoteResource *pRes = MakeNoteResource( sButton, sElement, false ); return pRes->m_pActor; } -Sprite *MakeRefcountedSprite( const CString &sButton, const CString &sElement, NoteType nt ) +Sprite *MakeRefcountedSprite( const CString &sButton, const CString &sElement ) { - NoteResource *pRes = MakeNoteResource( sButton, sElement, nt, true ); + NoteResource *pRes = MakeNoteResource( sButton, sElement, true ); return (Sprite *) pRes->m_pActor; /* XXX ick */ } @@ -211,17 +202,17 @@ NoteColorActor::~NoteColorActor() m_bIsNoteColor = false; } -void NoteColorActor::Load( bool bIsNoteColor, const CString &sButton, const CString &sElement ) +void NoteColorActor::Load( const CString &sButton, const CString &sElement ) { - m_bIsNoteColor = bIsNoteColor; + m_bIsNoteColor = false; if( m_bIsNoteColor ) { for( int i=0; iLoad( sButton ); - m_TapNote.Load( cache->m_bAnimationIsNoteColor[PART_TAP], sButton, "tap note" ); - m_TapAddition.Load( cache->m_bAnimationIsNoteColor[PART_ADDITION], sButton, "tap addition" ); - m_TapMine.Load( cache->m_bAnimationIsNoteColor[PART_MINE], sButton, "tap mine" ); + m_TapNote.Load( sButton, "tap note" ); + m_TapAddition.Load( sButton, "tap addition" ); + m_TapMine.Load( sButton, "tap mine" ); FOREACH_HoldType( ht ) { FOREACH_ActiveType( at ) { - m_HoldHead[ht][at].Load( cache->m_bAnimationIsNoteColor[PART_HOLD_HEAD], sButton, HoldTypeToString(ht)+" head "+ActiveTypeToString(at) ); - m_HoldTopCap[ht][at].Load( cache->m_bAnimationIsNoteColor[PART_HOLD_TOP_CAP], sButton, HoldTypeToString(ht)+" topcap "+ActiveTypeToString(at) ); - m_HoldBody[ht][at].Load( cache->m_bAnimationIsNoteColor[PART_HOLD_BODY], sButton, HoldTypeToString(ht)+" body "+ActiveTypeToString(at) ); - m_HoldBottomCap[ht][at].Load( cache->m_bAnimationIsNoteColor[PART_HOLD_BOTTOM_CAP], sButton, HoldTypeToString(ht)+" bottomcap "+ActiveTypeToString(at) ); - m_HoldTail[ht][at].Load( cache->m_bAnimationIsNoteColor[PART_HOLD_TAIL], sButton, HoldTypeToString(ht)+" tail "+ActiveTypeToString(at) ); + m_HoldHead[ht][at].Load( sButton, HoldTypeToString(ht)+" head "+ActiveTypeToString(at) ); + m_HoldTopCap[ht][at].Load( sButton, HoldTypeToString(ht)+" topcap "+ActiveTypeToString(at) ); + m_HoldBody[ht][at].Load( sButton, HoldTypeToString(ht)+" body "+ActiveTypeToString(at) ); + m_HoldBottomCap[ht][at].Load( sButton, HoldTypeToString(ht)+" bottomcap "+ActiveTypeToString(at) ); + m_HoldTail[ht][at].Load( sButton, HoldTypeToString(ht)+" tail "+ActiveTypeToString(at) ); } } } @@ -343,7 +334,7 @@ void NoteDisplay::Update( float fDeltaTime ) } } -void NoteDisplay::SetActiveFrame( float fNoteBeat, Actor &actorToSet, float fAnimationLengthInBeats, bool bVivid, bool bNoteColor ) +void NoteDisplay::SetActiveFrame( float fNoteBeat, Actor &actorToSet, float fAnimationLengthInBeats, bool bVivid ) { /* -inf ... inf */ float fSongBeat = GAMESTATE->m_fSongBeat; @@ -383,9 +374,8 @@ Actor * NoteDisplay::GetTapNoteActor( float fNoteBeat ) SetActiveFrame( fNoteBeat, *pActorOut, - cache->m_fAnimationLengthInBeats[PART_TAP], - cache->m_bAnimationIsVivid[PART_TAP], - cache->m_bAnimationIsNoteColor[PART_TAP] ); + cache->m_fAnimationLengthInBeats[NotePart_Tap], + cache->m_bAnimationIsVivid[NotePart_Tap] ); return pActorOut; } @@ -398,9 +388,8 @@ Actor * NoteDisplay::GetTapAdditionActor( float fNoteBeat ) SetActiveFrame( fNoteBeat, *pActorOut, - cache->m_fAnimationLengthInBeats[PART_ADDITION], - cache->m_bAnimationIsVivid[PART_ADDITION], - cache->m_bAnimationIsNoteColor[PART_ADDITION] ); + cache->m_fAnimationLengthInBeats[NotePart_Addition], + cache->m_bAnimationIsVivid[NotePart_Addition] ); return pActorOut; } @@ -413,9 +402,8 @@ Actor * NoteDisplay::GetTapMineActor( float fNoteBeat ) SetActiveFrame( fNoteBeat, *pActorOut, - cache->m_fAnimationLengthInBeats[PART_MINE], - cache->m_bAnimationIsVivid[PART_MINE], - cache->m_bAnimationIsNoteColor[PART_MINE] ); + cache->m_fAnimationLengthInBeats[NotePart_Mine], + cache->m_bAnimationIsVivid[NotePart_Mine] ); return pActorOut; } @@ -428,9 +416,8 @@ Sprite * NoteDisplay::GetHoldTopCapSprite( float fNoteBeat, bool bIsRoll, bool b SetActiveFrame( fNoteBeat, *pSpriteOut, - cache->m_fAnimationLengthInBeats[PART_HOLD_TOP_CAP], - cache->m_bAnimationIsVivid[PART_HOLD_TOP_CAP], - cache->m_bAnimationIsNoteColor[PART_HOLD_TOP_CAP] ); + cache->m_fAnimationLengthInBeats[NotePart_HoldTopCap], + cache->m_bAnimationIsVivid[NotePart_HoldTopCap] ); return pSpriteOut; } @@ -443,9 +430,8 @@ Sprite * NoteDisplay::GetHoldBottomCapSprite( float fNoteBeat, bool bIsRoll, boo SetActiveFrame( fNoteBeat, *pSpriteOut, - cache->m_fAnimationLengthInBeats[PART_HOLD_BOTTOM_CAP], - cache->m_bAnimationIsVivid[PART_HOLD_BOTTOM_CAP], - cache->m_bAnimationIsNoteColor[PART_HOLD_BOTTOM_CAP] ); + cache->m_fAnimationLengthInBeats[NotePart_HoldBottomCap], + cache->m_bAnimationIsVivid[NotePart_HoldBottomCap] ); return pSpriteOut; } @@ -459,9 +445,8 @@ Actor* NoteDisplay::GetHoldHeadActor( float fNoteBeat, bool bIsRoll, bool bIsBei SetActiveFrame( fNoteBeat, *pActorOut, - cache->m_fAnimationLengthInBeats[PART_HOLD_HEAD], - cache->m_bAnimationIsVivid[PART_HOLD_HEAD], - cache->m_bAnimationIsNoteColor[PART_HOLD_HEAD] ); + cache->m_fAnimationLengthInBeats[NotePart_HoldHead], + cache->m_bAnimationIsVivid[NotePart_HoldHead] ); return pActorOut; } @@ -474,9 +459,8 @@ Sprite *NoteDisplay::GetHoldBodySprite( float fNoteBeat, bool bIsRoll, bool bIsB SetActiveFrame( fNoteBeat, *pSpriteOut, - cache->m_fAnimationLengthInBeats[PART_HOLD_BODY], - cache->m_bAnimationIsVivid[PART_HOLD_BODY], - cache->m_bAnimationIsNoteColor[PART_HOLD_BODY] ); + cache->m_fAnimationLengthInBeats[NotePart_HoldBody], + cache->m_bAnimationIsVivid[NotePart_HoldBody] ); return pSpriteOut; } @@ -489,9 +473,8 @@ Actor* NoteDisplay::GetHoldTailActor( float fNoteBeat, bool bIsRoll, bool bIsBei SetActiveFrame( fNoteBeat, *pActorOut, - cache->m_fAnimationLengthInBeats[PART_HOLD_TAIL], - cache->m_bAnimationIsVivid[PART_HOLD_TAIL], - cache->m_bAnimationIsNoteColor[PART_HOLD_TAIL] ); + cache->m_fAnimationLengthInBeats[NotePart_HoldTail], + cache->m_bAnimationIsVivid[NotePart_HoldTail] ); return pActorOut; } @@ -825,6 +808,13 @@ void NoteDisplay::DrawHoldTail( const TapNote& tn, int iCol, int iRow, bool bIsB pSprTail->SetXY( fX, fY ); pSprTail->SetZ( fZ ); + if( cache->m_fNoteColorTextureCoordSpacing[NotePart_HoldTail] != g_emptyVector ) + { + DISPLAY->TexturePushMatrix(); + NoteType nt = GetNoteType( iRow ); + DISPLAY->TextureTranslate( cache->m_fNoteColorTextureCoordSpacing[NotePart_HoldTail]*nt ); + } + if( bGlow ) { pSprTail->SetDiffuse( RageColor(1,1,1,0) ); @@ -854,6 +844,11 @@ void NoteDisplay::DrawHoldTail( const TapNote& tn, int iCol, int iRow, bool bIsB DISPLAY->SetLightOff( 0 ); DISPLAY->SetLighting( false ); } + + if( cache->m_fNoteColorTextureCoordSpacing[NotePart_HoldTail] != g_emptyVector ) + { + DISPLAY->TexturePopMatrix(); + } } void NoteDisplay::DrawHoldHead( const TapNote& tn, int iCol, int iRow, bool bIsBeingHeld, float fYHead, float fPercentFadeToFail, float fColorScale, bool bGlow, float fYStartOffset, float fYEndOffset ) @@ -881,6 +876,13 @@ void NoteDisplay::DrawHoldHead( const TapNote& tn, int iCol, int iRow, bool bIsB pActor->SetXY( fX, fY ); pActor->SetZ( fZ ); + if( cache->m_fNoteColorTextureCoordSpacing[NotePart_HoldHead] != g_emptyVector ) + { + DISPLAY->TexturePushMatrix(); + NoteType nt = GetNoteType( iRow ); + DISPLAY->TextureTranslate( cache->m_fNoteColorTextureCoordSpacing[NotePart_HoldHead]*nt ); + } + if( bGlow ) { pActor->SetDiffuse( RageColor(1,1,1,0) ); @@ -910,6 +912,11 @@ void NoteDisplay::DrawHoldHead( const TapNote& tn, int iCol, int iRow, bool bIsB DISPLAY->SetLightOff( 0 ); DISPLAY->SetLighting( false ); } + + if( cache->m_fNoteColorTextureCoordSpacing[NotePart_HoldHead] != g_emptyVector ) + { + DISPLAY->TexturePopMatrix(); + } } void NoteDisplay::DrawHold( const TapNote &tn, int iCol, int iRow, bool bIsBeingHeld, bool bIsActive, const HoldNoteResult &Result, float fPercentFadeToFail, bool bDrawGlowOnly, float fReverseOffsetPixels, float fYStartOffset, float fYEndOffset ) @@ -987,7 +994,7 @@ void NoteDisplay::DrawHold( const TapNote &tn, int iCol, int iRow, bool bIsBeing DrawHold( tn, iCol, iRow, bIsBeingHeld, bIsActive, Result, fPercentFadeToFail, true, fReverseOffsetPixels, fYStartOffset, fYEndOffset ); } -void NoteDisplay::DrawActor( Actor* pActor, int iCol, float fBeat, float fPercentFadeToFail, float fLife, float fReverseOffsetPixels, bool bUseLighting ) +void NoteDisplay::DrawActor( Actor* pActor, int iCol, float fBeat, float fPercentFadeToFail, float fLife, float fReverseOffsetPixels, bool bUseLighting, NotePart part ) { const float fYOffset = ArrowEffects::GetYOffset( m_pPlayerState, iCol, fBeat ); const float fYPos = ArrowEffects::GetYPos( m_pPlayerState, iCol, fYOffset, fReverseOffsetPixels ); @@ -1008,6 +1015,13 @@ void NoteDisplay::DrawActor( Actor* pActor, int iCol, float fBeat, float fPercen pActor->SetGlow( glow ); pActor->SetZoom( fZoom ); + if( cache->m_fNoteColorTextureCoordSpacing[part] != g_emptyVector ) + { + DISPLAY->TexturePushMatrix(); + NoteType nt = BeatToNoteType( fBeat ); + DISPLAY->TextureTranslate( cache->m_fNoteColorTextureCoordSpacing[part]*nt ); + } + if( bUseLighting ) { DISPLAY->SetLighting( true ); @@ -1026,6 +1040,11 @@ void NoteDisplay::DrawActor( Actor* pActor, int iCol, float fBeat, float fPercen DISPLAY->SetLightOff( 0 ); DISPLAY->SetLighting( false ); } + + if( cache->m_fNoteColorTextureCoordSpacing[part] != g_emptyVector ) + { + DISPLAY->TexturePopMatrix(); + } } void NoteDisplay::DrawTap( int iCol, float fBeat, bool bOnSameRowAsHoldStart, bool bIsAddition, bool bIsMine, float fPercentFadeToFail, float fLife, float fReverseOffsetPixels ) @@ -1053,7 +1072,7 @@ void NoteDisplay::DrawTap( int iCol, float fBeat, bool bOnSameRowAsHoldStart, bo bUseLighting = cache->m_bTapNoteUseLighting; } - DrawActor( pActor, iCol, fBeat, fPercentFadeToFail, fLife, fReverseOffsetPixels, bUseLighting ); + DrawActor( pActor, iCol, fBeat, fPercentFadeToFail, fLife, fReverseOffsetPixels, bUseLighting, NotePart_Tap ); } /* diff --git a/stepmania/src/NoteDisplay.h b/stepmania/src/NoteDisplay.h index ea33fb90ef..1a57e4e7bc 100644 --- a/stepmania/src/NoteDisplay.h +++ b/stepmania/src/NoteDisplay.h @@ -11,13 +11,26 @@ struct HoldNoteResult; struct NoteMetricCache_t; class PlayerState; +enum NotePart +{ + NotePart_Tap, + NotePart_Addition, + NotePart_Mine, + NotePart_HoldHead, + NotePart_HoldTail, + NotePart_HoldTopCap, + NotePart_HoldBody, + NotePart_HoldBottomCap, + NUM_NotePart +}; + #define NOTE_COLOR_IMAGES 8 struct NoteColorActor { NoteColorActor(); ~NoteColorActor(); - void Load( bool bIsNoteColor, const CString &sButton, const CString &sElement ); + void Load( const CString &sButton, const CString &sElement ); Actor* Get( NoteType nt ); private: Actor* m_p[NOTE_COLOR_IMAGES]; @@ -28,7 +41,7 @@ struct NoteColorSprite { NoteColorSprite(); ~NoteColorSprite(); - void Load( bool bIsNoteColor, const CString &sButton, const CString &sElement ); + void Load( const CString &sButton, const CString &sElement ); Sprite* Get( NoteType nt ); private: Sprite* m_p[NOTE_COLOR_IMAGES]; @@ -54,14 +67,14 @@ public: static void Update( float fDeltaTime ); - void DrawActor( Actor* pActor, int iCol, float fBeat, float fPercentFadeToFail, float fLife, float fReverseOffsetPixels, bool bUseLighting ); + void DrawActor( Actor* pActor, int iCol, float fBeat, float fPercentFadeToFail, float fLife, float fReverseOffsetPixels, bool bUseLighting, NotePart part ); void DrawTap( int iCol, float fBeat, bool bOnSameRowAsHoldStart, bool bIsAddition, bool bIsMine, float fPercentFadeToFail, float fLife, float fReverseOffsetPixels ); void DrawHold( const TapNote& tn, int iCol, int iRow, bool bIsBeingHeld, bool bIsActive, const HoldNoteResult &Result, float fPercentFadeToFail, bool bDrawGlowOnly, float fReverseOffsetPixels, float fYStartOffset, float fYEndOffset ); bool DrawHoldHeadForTapsOnSameRow() const; protected: - void SetActiveFrame( float fNoteBeat, Actor &actorToSet, float fAnimationLengthInBeats, bool bVivid, bool bNoteColor ); + void SetActiveFrame( float fNoteBeat, Actor &actorToSet, float fAnimationLengthInBeats, bool bVivid ); Actor *GetTapNoteActor( float fNoteBeat ); Actor *GetTapAdditionActor( float fNoteBeat ); Actor *GetTapMineActor( float fNoteBeat ); diff --git a/stepmania/src/NoteField.cpp b/stepmania/src/NoteField.cpp index f1e0579391..9812473eb8 100644 --- a/stepmania/src/NoteField.cpp +++ b/stepmania/src/NoteField.cpp @@ -798,7 +798,7 @@ void NoteField::DrawPrimitives() Sprite sprite; sprite.Load( THEME->GetPathG("NoteField","attack "+tn.sAttackModifiers) ); float fBeat = NoteRowToBeat(i); - nd->display[c].DrawActor( &sprite, c, fBeat, bIsInSelectionRange ? fSelectedRangeGlow : m_fPercentFadeToFail, 1, m_fYReverseOffsetPixels, false ); + nd->display[c].DrawActor( &sprite, c, fBeat, bIsInSelectionRange ? fSelectedRangeGlow : m_fPercentFadeToFail, 1, m_fYReverseOffsetPixels, false, NotePart_Tap ); } else { diff --git a/stepmania/src/NoteSkinManager.cpp b/stepmania/src/NoteSkinManager.cpp index a3561dc384..1f12e226c0 100644 --- a/stepmania/src/NoteSkinManager.cpp +++ b/stepmania/src/NoteSkinManager.cpp @@ -162,8 +162,12 @@ CString NoteSkinManager::GetMetric( const CString &sButtonName, const CString &s if( data.metrics.GetValue( sButtonName, sValue, sReturn ) ) return sReturn; if( !data.metrics.GetValue( "NoteDisplay", sValue, sReturn ) ) - RageException::Throw( "Could not read metric '[%s] %s' or '[NoteDisplay] %s' in '%s'", + { + CString sError = ssprintf( + "Could not read metric '[%s] %s' or '[NoteDisplay] %s' in '%s'", sButtonName.c_str(), sValue.c_str(), sValue.c_str(), sNoteSkinName.c_str() ); + RageException::Throw( sError ); + } return sReturn; } diff --git a/stepmania/src/NoteTypes.h b/stepmania/src/NoteTypes.h index d6589ff2e3..84306df520 100644 --- a/stepmania/src/NoteTypes.h +++ b/stepmania/src/NoteTypes.h @@ -178,7 +178,6 @@ enum NoteType // MD 11/02/03 - added finer divisions NOTE_TYPE_48TH, // forty-eighth note NOTE_TYPE_64TH, // sixty-fourth note - // Not having this triggers asserts all over the place. Go figure. NOTE_TYPE_192ND, NUM_NOTE_TYPES, NOTE_TYPE_INVALID diff --git a/stepmania/src/RageDisplay.cpp b/stepmania/src/RageDisplay.cpp index 4a85cb07d2..9b89600ae6 100644 --- a/stepmania/src/RageDisplay.cpp +++ b/stepmania/src/RageDisplay.cpp @@ -445,9 +445,9 @@ void RageDisplay::TexturePopMatrix() g_TextureStack.Pop(); } -void RageDisplay::TextureTranslate( float x, float y, float z ) +void RageDisplay::TextureTranslate( float x, float y ) { - g_TextureStack.TranslateLocal(x, y, z); + g_TextureStack.TranslateLocal(x, y, 0); } diff --git a/stepmania/src/RageDisplay.h b/stepmania/src/RageDisplay.h index 6e44756709..d1fff1e9a0 100644 --- a/stepmania/src/RageDisplay.h +++ b/stepmania/src/RageDisplay.h @@ -275,7 +275,8 @@ public: /* Texture matrix functions */ void TexturePushMatrix(); void TexturePopMatrix(); - void TextureTranslate( float x, float y, float z ); + void TextureTranslate( float x, float y ); + void TextureTranslate( const RageVector2 &v ) { this->TextureTranslate( v.x, v.y ); } /* Projection and View matrix stack functions. */ void CameraPushMatrix();