History

use radians instead of degrees (almost) everywhere

Andrew Meadows committed 12 years ago

Commit aa8c2fc1 parent de8165c51 files · +302 −306Browse files

Showing the changes to interface/src/Environment.cpp (1 of 51 files). Show all

Unified · Split

interface/src/Environment.cpp+2−2
@@ -237,8 +237,8 @@ void Environment::renderAtmosphere(Camera& camera, const EnvironmentData& data) · 236 unmodified lines
237237 program->setUniformValue(locations[INNER_RADIUS_LOCATION], data.getAtmosphereInnerRadius());
238238 program->setUniformValue(locations[KR_ESUN_LOCATION], data.getRayleighScattering() * data.getSunBrightness());
239239 program->setUniformValue(locations[KM_ESUN_LOCATION], data.getMieScattering() * data.getSunBrightness());
240− program->setUniformValue(locations[KR_4PI_LOCATION], data.getRayleighScattering() * 4.0f * PIf);
241− program->setUniformValue(locations[KM_4PI_LOCATION], data.getMieScattering() * 4.0f * PIf);
240+ program->setUniformValue(locations[KR_4PI_LOCATION], data.getRayleighScattering() * 4.0f * PI);
241+ program->setUniformValue(locations[KM_4PI_LOCATION], data.getMieScattering() * 4.0f * PI);
242242 program->setUniformValue(locations[SCALE_LOCATION], 1.0f / (data.getAtmosphereOuterRadius() - data.getAtmosphereInnerRadius()));
243243 program->setUniformValue(locations[SCALE_DEPTH_LOCATION], 0.25f);
244244 program->setUniformValue(locations[SCALE_OVER_SCALE_DEPTH_LOCATION],