21 #ifndef _ATMOSTPHERE_HPP_ 22 #define _ATMOSTPHERE_HPP_ 24 #include "Skylight.hpp" 25 #include "VecMath.hpp" 27 #include "Skybright.hpp" 28 #include "StelFader.hpp" 30 #include <QOpenGLBuffer> 45 void computeColor(
double JD,
Vec3d _sunPos,
Vec3d moonPos,
float moonPhase,
StelCore* core,
46 float latitude = 45.f,
float altitude = 200.f,
47 float temperature = 15.f,
float relativeHumidity = 40.f);
49 void update(
double deltaTime) {fader.update((
int)(deltaTime*1000));}
66 float getFadeIntensity()
const {
return fader.getInterstate();}
86 int skyResolutionY,skyResolutionX;
89 QOpenGLBuffer posGridBuffer;
90 QOpenGLBuffer indicesBuffer;
92 QOpenGLBuffer colorGridBuffer;
95 float averageLuminance;
96 bool overrideAverageLuminance;
99 float lightPollutionLuminance;
102 class QOpenGLShaderProgram* atmoShaderProgram;
104 int alphaWaOverAlphaDa;
106 int term2TimesOneOverMaxdLpOneOverGamma;
109 int term_x, Ax, Bx, Cx, Dx, Ex;
110 int term_y, Ay, By, Cy, Dy, Ey;
111 int projectionMatrix;
114 } shaderAttribLocations;
117 #endif // _ATMOSTPHERE_HPP_ void setFlagShow(bool b)
Define whether to display atmosphere.
float getRealDisplayIntensityFactor() const
Get the actual atmosphere intensity due to eclipses + fader.
Implementation of StelFader which implements a linear transition.
Compute and display the daylight sky color using openGL.
bool getFlagShow() const
Get whether atmosphere is displayed.
void setLightPollutionLuminance(float f)
Set the light pollution luminance in cd/m^2.
Main class for Stellarium core processing.
A templatized 2d vector compatible with openGL.
Converts tones in function of the eye adaptation to luminance.
float getLightPollutionLuminance() const
Get the light pollution luminance in cd/m^2.
float getFadeDuration()
Get fade in/out duration in seconds.
Provide the main interface to all operations of projecting coordinates from sky to screen...
This class makes use of the 1998 sky brightness model by Bradley Schaefer.
void setAverageLuminance(float overrideLum)
override computable luminance.
void setFadeDuration(float duration)
Set fade in/out duration in seconds.
float getAverageLuminance() const
Get the average luminance of the atmosphere in cd/m2 If atmosphere is off, the luminance includes the...