Break cel shading (it'll be fixed soon, I have to poke at RageDisplay stuff), add TODOs for myself, and comment out some 2D character stuff... 2d chars should be possible to implement in lua instead.

This commit is contained in:
Colby Klein
2011-02-25 02:08:30 -08:00
parent 9a88c8ec54
commit dc493450bf
2 changed files with 28 additions and 16 deletions
+11 -12
View File
@@ -65,6 +65,7 @@ void Model::Load( const RString &sFile )
#define THROW RageException::Throw( "Parse error in \"%s\" at line %d: \"%s\".", sPath.c_str(), iLineNum, sLine.c_str() )
// TODO: Move MS3D loading into its own class. - Colby
void Model::LoadMilkshapeAscii( const RString &sPath )
{
LoadPieces( sPath, sPath, sPath );
@@ -288,19 +289,17 @@ bool Model::EarlyAbortDraw() const
void Model::DrawCelShaded()
{
// TODO: use shell shader for outline.
this->SetGlow(RageColor(0,0,0,1));
this->SetDiffuseAlpha(0);
DISPLAY->SetPolygonMode( POLYGON_LINE );
DISPLAY->SetLineWidth( 3 );
this->SetZWrite( false );
this->Draw();
this->SetDiffuseAlpha(1);
this->SetGlow(RageColor(1,1,1,0));
DISPLAY->SetPolygonMode( POLYGON_FILL );
this->SetZWrite( true );
DISPLAY->SetCelShaded( true );
// First pass: outline/shell
// DISPLAY->SetCelShaded(1);
this->Draw();
DISPLAY->SetCelShaded( false );
// Second pass: normal shading
// DISPLAY->SetCelShaded(2);
// this->Draw();
// DISPLAY->SetCelShaded(0)
}
void Model::DrawPrimitives()
@@ -375,7 +374,7 @@ void Model::DrawPrimitives()
}
// go
DrawMesh( i );
DrawMesh(i);
// Turn off environment mapping on tex unit 0.
DISPLAY->SetSphereEnvironmentMapping( TextureUnit_1, false );