X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FTime%2Flight.hxx;h=1880c3deab0a3cf9fa34b95e39b23a0c9f5dc105;hb=cd20c6073c8f4341d0f82070abae14b765cc8630;hp=09b13baeadc925b2915bdae9fbd28391480d6e8e;hpb=552c3149aeaaea7abdc00eee644ef81414644e7b;p=flightgear.git diff --git a/src/Time/light.hxx b/src/Time/light.hxx index 09b13baea..1880c3dea 100644 --- a/src/Time/light.hxx +++ b/src/Time/light.hxx @@ -36,6 +36,7 @@ #include +#include #include #include @@ -60,9 +61,6 @@ private: double _sun_lon, _sun_lat; double _moon_lon, _moon_gc_lat; - // in cartesian coordiantes - SGVec3d _sunpos, _moonpos; - // (in view coordinates) SGVec4f _sun_vec, _moon_vec; @@ -88,6 +86,7 @@ private: SGVec4f _scene_ambient; SGVec4f _scene_diffuse; SGVec4f _scene_specular; + SGVec4f _scene_chrome; // clear sky, fog and cloud color SGVec4f _sky_color; @@ -98,11 +97,21 @@ private: SGVec4f _adj_fog_color; SGVec4f _adj_sky_color; + // input parameters affected by the weather system + float _saturation; + float _scattering; + float _overcast; + double _dt_total; void update_sky_color (); void update_adj_fog_color (); + void updateSunPos(); + + // properties for chrome light; not a tie because I want to fire + // property listeners when the values change. + SGPropertyNode_ptr _chromeProps[4]; public: FGLight (); @@ -120,11 +129,12 @@ public: inline const SGVec4f& scene_ambient () const { return _scene_ambient; } inline const SGVec4f& scene_diffuse () const { return _scene_diffuse; } inline const SGVec4f& scene_specular () const { return _scene_specular; } + inline const SGVec4f& scene_chrome () const { return _scene_chrome; } inline const SGVec4f& sky_color () const { return _sky_color; } inline const SGVec4f& cloud_color () const { return _cloud_color; } inline const SGVec4f& adj_fog_color () const { return _adj_fog_color; } - + inline const SGVec4f& adj_sky_color () const { return _adj_sky_color; } // Sun related functions @@ -140,9 +150,6 @@ public: inline double get_sun_lat () const { return _sun_lat; } inline void set_sun_lat (double l) { _sun_lat = l; } - inline const SGVec3d& get_sunpos () const { return _sunpos; } - inline void set_sunpos (const SGVec3d& p) { _sunpos = p; } - inline SGVec4f& sun_vec () { return _sun_vec; } inline SGVec4f& sun_vec_inv () { return _sun_vec_inv; } @@ -161,9 +168,6 @@ public: inline double get_moon_gc_lat () const { return _moon_gc_lat; } inline void set_moon_gc_lat (double l) { _moon_gc_lat = l; } - inline const SGVec3d& get_moonpos () const { return _moonpos; } - inline void set_moonpos (const SGVec3d& p) { _moonpos = p; } - inline const SGVec4f& moon_vec () const { return _moon_vec; } inline const SGVec4f& moon_vec_inv () const { return _moon_vec_inv; } };