From 12185dfd0df3146d3121f35ffa0123920e1c3202 Mon Sep 17 00:00:00 2001 From: Chris Danford Date: Tue, 26 Apr 2005 20:18:51 +0000 Subject: [PATCH] revert order to fix env mapping (not sure why yet) --- stepmania/src/Model.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/stepmania/src/Model.cpp b/stepmania/src/Model.cpp index 248d9b53af..7d7c5e7739 100644 --- a/stepmania/src/Model.cpp +++ b/stepmania/src/Model.cpp @@ -413,6 +413,11 @@ void Model::DrawPrimitives() } else { + // render the diffuse texture with texture unit 1 + DISPLAY->SetTexture( 0, mat.diffuse.GetCurrentTexture() ); + Actor::SetTextureRenderStates(); // set Actor-specified render states + DISPLAY->SetSphereEnvironmentMapping( mat.diffuse.m_bSphereMapped ); + // render the additive texture with texture unit 2 if( mat.alpha.GetCurrentTexture() ) { @@ -427,11 +432,6 @@ void Model::DrawPrimitives() DISPLAY->SetTexture( 1, NULL ); } - // render the diffuse texture with texture unit 1 - DISPLAY->SetTexture( 0, mat.diffuse.GetCurrentTexture() ); - Actor::SetTextureRenderStates(); // set Actor-specified render states - DISPLAY->SetSphereEnvironmentMapping( mat.diffuse.m_bSphereMapped ); - /* go */ DrawMesh( i );