Changeset 3659 for OpenSceneGraph/trunk/examples/osgplanets/osgplanets.cpp
- Timestamp:
- 11/18/04 11:08:29 (9 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
OpenSceneGraph/trunk/examples/osgplanets/osgplanets.cpp
r3634 r3659 382 382 383 383 // create the sun 384 osg::Node* s un = solarSystem.createPlanet( solarSystem._radiusSun, "Sun", osg::Vec4( 1.0f, 1.0f, 1.0f, 1.0f), solarSystem._mapSun );385 osg::StateSet* sunStateSet = s un->getOrCreateStateSet();384 osg::Node* solarSun = solarSystem.createPlanet( solarSystem._radiusSun, "Sun", osg::Vec4( 1.0f, 1.0f, 1.0f, 1.0f), solarSystem._mapSun ); 385 osg::StateSet* sunStateSet = solarSun->getOrCreateStateSet(); 386 386 osg::Material* material = new osg::Material; 387 387 material->setEmission( osg::Material::FRONT_AND_BACK, osg::Vec4( 1.0f, 1.0f, 0.0f, 0.0f ) ); … … 397 397 398 398 // stick sun right under root, no transformations for the sun 399 sunLight->addChild( s un );399 sunLight->addChild( solarSun ); 400 400 401 401 // create light source in the sun
