/* render/lightenvironment.h This file is part of the Osirion project and is distributed under the terms of the GNU General Public License version 2 */ #ifndef __INCLUDED_RENDER_LIGHTENVIRONMENT_H__ #define __INCLUDED_RENDER_LIGHTENVIRONMENT_H__ #include #include "render/light.h" namespace render { /** * @brief a collection of lights * */ class LightEnvironment { public: LightEnvironment(); ~LightEnvironment(); /** * @brief enable all lights in the environment * */ void enable(); /** * @brief disable all lights in the environment * */ void disable(); /** * @brief remove all lights in the environment * */ void clear(); /** * @brief add a light to the environment * */ void add(Light *light); /** * @brief transfer light environment to OpenGL state */ void draw(); /** * @brief transfer light environment to OpenGL state */ void draw(const math::Vector3f translate); /** * @brief number of lights in the environment * */ inline size_t size() const { return env_container.size(); } private: typedef std::vector Container; Container env_container; int env_base_id; float env_attenuation; float env_ambient_intensity; float env_diffuse_intensity; float env_specular_intensity; }; } #endif // __INCLUDED_RENDER_LIGHTENVIRONMENT_H__