From 78a45c8158a7e632031bb8e6fbba4839efcbded7 Mon Sep 17 00:00:00 2001 From: Chris Danford Date: Sat, 24 Apr 2004 09:30:30 +0000 Subject: [PATCH] fix Model glow pass doesn't draw with correct bone transform --- stepmania/src/Model.cpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/stepmania/src/Model.cpp b/stepmania/src/Model.cpp index 5484332ef0..0578e665e4 100644 --- a/stepmania/src/Model.cpp +++ b/stepmania/src/Model.cpp @@ -576,7 +576,21 @@ void Model::DrawPrimitives() DISPLAY->ClearAllTextures(); } + // apply mesh-specific bone (if any) + if( pMesh->nBoneIndex != -1 ) + { + DISPLAY->PushMatrix(); + + RageMatrix &mat = m_vpBones[pMesh->nBoneIndex].mFinal; + DISPLAY->PreMultMatrix( mat ); + } + DISPLAY->DrawCompiledGeometry( TempGeometry, i, m_pGeometry->m_Meshes ); + + if( pMesh->nBoneIndex != -1 ) + { + DISPLAY->PopMatrix(); + } } } }