From 73978603236c2c28abb99b974b7cc18480040091 Mon Sep 17 00:00:00 2001 From: curt Date: Wed, 11 Aug 1999 18:35:23 +0000 Subject: [PATCH] Fixed --shading-flat option so it sets the material properties correctly. --- src/Objects/materialmgr.cxx | 6 +++++- src/Scenery/tileentry.hxx | 1 - 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/Objects/materialmgr.cxx b/src/Objects/materialmgr.cxx index 90b007636..73cc8f96e 100644 --- a/src/Objects/materialmgr.cxx +++ b/src/Objects/materialmgr.cxx @@ -179,7 +179,11 @@ fgMATERIAL_MGR::load_lib ( void ) ssgSimpleState *state = new ssgSimpleState; state->enable( GL_LIGHTING ); - state->setShadeModel( GL_SMOOTH ); + if ( current_options.get_shading() == 1 ) { + state->setShadeModel( GL_SMOOTH ); + } else { + state->setShadeModel( GL_FLAT ); + } state->enable ( GL_CULL_FACE ) ; if ( current_options.get_textures() ) { state->enable( GL_TEXTURE_2D ); diff --git a/src/Scenery/tileentry.hxx b/src/Scenery/tileentry.hxx index aaa9088a8..5b6824d6f 100644 --- a/src/Scenery/tileentry.hxx +++ b/src/Scenery/tileentry.hxx @@ -48,7 +48,6 @@ #include // plib includes #include -#include #include #include -- 2.39.5