paysages3d/src/interface/modeler/quickapp/AtmosphereModeler.cpp

31 lines
753 B
C++
Raw Normal View History

2014-08-28 13:09:47 +00:00
#include "AtmosphereModeler.h"
#include "MainModelerWindow.h"
#include "Scenery.h"
#include "AtmosphereDefinition.h"
#include "OpenGLRenderer.h"
#include "OpenGLSkybox.h"
#include "OpenGLTerrain.h"
#include "FloatNode.h"
2014-08-28 13:09:47 +00:00
AtmosphereModeler::AtmosphereModeler(MainModelerWindow *main):
main(main)
{
QObject *item = main->findQmlObject("atmosphere_daytime");
if (item)
{
item->setProperty("value", propDayTime()->getValue());
2014-08-28 13:09:47 +00:00
connect(item, SIGNAL(changed(double)), this, SLOT(daytimeChanged(double)));
}
}
void AtmosphereModeler::daytimeChanged(double value)
{
propDayTime()->setValue(value);
}
FloatNode *AtmosphereModeler::propDayTime() const
{
return main->getScenery()->getAtmosphere()->propDayTime();
2014-08-28 13:09:47 +00:00
}