Hide details about ambient light in irr_driver.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/irrlicht@3265 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
parent
41020d56ac
commit
f5d9330e77
@ -156,6 +156,15 @@ video::ITexture *IrrDriver::getTexture(const std::string &filename)
|
|||||||
return m_scene_manager->getVideoDriver()->getTexture(filename.c_str());
|
return m_scene_manager->getVideoDriver()->getTexture(filename.c_str());
|
||||||
} // getTexture
|
} // getTexture
|
||||||
|
|
||||||
|
// ----------------------------------------------------------------------------
|
||||||
|
/** Sets the ambient light.
|
||||||
|
* \param light The colour of the light to set.
|
||||||
|
*/
|
||||||
|
void IrrDriver::setAmbientLight(const video::SColor &light)
|
||||||
|
{
|
||||||
|
m_scene_manager->setAmbientLight(light);
|
||||||
|
} // setAmbientLight
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
/** Update, called once per frame.
|
/** Update, called once per frame.
|
||||||
* \param dt Time since last update
|
* \param dt Time since last update
|
||||||
|
@ -48,6 +48,7 @@ public:
|
|||||||
gui::IGUIEnvironment *getGUI() const { return m_gui_env; }
|
gui::IGUIEnvironment *getGUI() const { return m_gui_env; }
|
||||||
irr::gui::IGUIFont *getRaceFont() const { return m_race_font; }
|
irr::gui::IGUIFont *getRaceFont() const { return m_race_font; }
|
||||||
bool OnEvent(const irr::SEvent &event);
|
bool OnEvent(const irr::SEvent &event);
|
||||||
|
void setAmbientLight(const video::SColor &light);
|
||||||
video::ITexture *getTexture(const std::string &filename);
|
video::ITexture *getTexture(const std::string &filename);
|
||||||
scene::ISceneNode *addOctTree(scene::IMesh *mesh);
|
scene::ISceneNode *addOctTree(scene::IMesh *mesh);
|
||||||
scene::ISceneNode *addMesh(scene::IMesh *mesh);
|
scene::ISceneNode *addMesh(scene::IMesh *mesh);
|
||||||
|
@ -1487,7 +1487,7 @@ void Track::loadTrackModel()
|
|||||||
m_light = irr_driver->getSceneManager()->addLightSceneNode(0, sun_pos);
|
m_light = irr_driver->getSceneManager()->addLightSceneNode(0, sun_pos);
|
||||||
video::SLight light;
|
video::SLight light;
|
||||||
m_light->setLightData(light);
|
m_light->setLightData(light);
|
||||||
//irr_driver->getSceneManager()->setAmbientLight(video::SColorf(1.0f,1.0f,1.0f,1.0f));
|
irr_driver->setAmbientLight(video::SColor(255, 255, 255, 255));
|
||||||
// Note: the physics world for irrlicht is created in loadMainTrack
|
// Note: the physics world for irrlicht is created in loadMainTrack
|
||||||
createPhysicsModel();
|
createPhysicsModel();
|
||||||
} // loadTrack
|
} // loadTrack
|
||||||
|
Loading…
x
Reference in New Issue
Block a user