From 24b5f0552234bb4b3df9c28e3d33ea597f64c2c9 Mon Sep 17 00:00:00 2001 From: curt Date: Fri, 9 Jan 2004 16:49:13 +0000 Subject: [PATCH] Make the vasi lights slightly larger/brighter. --- simgear/scene/tgdb/pt_lights.cxx | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/simgear/scene/tgdb/pt_lights.cxx b/simgear/scene/tgdb/pt_lights.cxx index 42eb4671..ed98df96 100644 --- a/simgear/scene/tgdb/pt_lights.cxx +++ b/simgear/scene/tgdb/pt_lights.cxx @@ -34,7 +34,7 @@ // strobe pre-draw (we want a larger point size) static int StrobePreDraw( ssgEntity *e ) { glPushAttrib( GL_POINT_BIT ); - glPointSize(3.0); + glPointSize(4.0); glEnable(GL_POINT_SMOOTH); return true; @@ -48,6 +48,23 @@ static int StrobePostDraw( ssgEntity *e ) { } +// vasi pre-draw (we want a larger point size) +static int VASIPreDraw( ssgEntity *e ) { + glPushAttrib( GL_POINT_BIT ); + glPointSize(2.0); + glEnable(GL_POINT_SMOOTH); + + return true; +} + +// vasi post-draw (we want a larger point size) +static int VASIPostDraw( ssgEntity *e ) { + glPopAttrib(); + + return true; +} + + // Generate a directional light ssgLeaf *sgMakeDirectionalLight( sgVec3 pt, sgVec3 dir, sgVec3 up, const SGMaterial *mat ) { @@ -631,8 +648,8 @@ ssgBranch *sgMakeDirectionalLights( const point_list &nodes, // structure. ssgRangeSelector *lod = (ssgRangeSelector *)light_group->getKid(0); ssgLeaf *leaf = (ssgLeaf *)lod->getKid(0); - // leaf->setCallback( SSG_CALLBACK_PREDRAW, StrobePreDraw ); - // leaf->setCallback( SSG_CALLBACK_POSTDRAW, StrobePostDraw ); + leaf->setCallback( SSG_CALLBACK_PREDRAW, VASIPreDraw ); + leaf->setCallback( SSG_CALLBACK_POSTDRAW, VASIPostDraw ); SGVASIUserData *vasi = new SGVASIUserData( pos, leaf ); -- 2.39.5