Michaël Lemaire
08ca1e5d59
git-svn-id: https://subversion.assembla.com/svn/thunderk/paysages@240 b1fd45b6-86a6-48da-8261-f70d1f35bdcc
44 lines
1.1 KiB
C++
44 lines
1.1 KiB
C++
#include "formtextures.h"
|
|
|
|
#include "../lib_paysages/textures.h"
|
|
#include "../lib_paysages/scenery.h"
|
|
|
|
static TexturesDefinition _definition;
|
|
|
|
/**************** Previews ****************/
|
|
|
|
/**************** Form ****************/
|
|
FormTextures::FormTextures(QWidget *parent):
|
|
BaseForm(parent)
|
|
{
|
|
_definition = texturesCreateDefinition();
|
|
|
|
/*previewHeight = new PreviewTerrainHeight(this);
|
|
previewColor = new PreviewTerrainColor(this);
|
|
addPreview(previewHeight, QString("Height preview (normalized)"));
|
|
addPreview(previewColor, QString("Textured preview (no shadow)"));*/
|
|
|
|
/*addInputNoise("Noise", _definition.height_noise);
|
|
addInputDouble("Height", &_definition.height_factor, 0.0, 20.0, 0.1, 1.0);
|
|
addInputDouble("Scaling", &_definition.scaling, 1.0, 20.0, 0.1, 1.0);*/
|
|
|
|
revertConfig();
|
|
}
|
|
|
|
void FormTextures::revertConfig()
|
|
{
|
|
sceneryGetTextures(&_definition);
|
|
BaseForm::revertConfig();
|
|
}
|
|
|
|
void FormTextures::applyConfig()
|
|
{
|
|
scenerySetTextures(&_definition);
|
|
BaseForm::applyConfig();
|
|
}
|
|
|
|
void FormTextures::configChangeEvent()
|
|
{
|
|
texturesValidateDefinition(&_definition);
|
|
BaseForm::configChangeEvent();
|
|
}
|