Remove constants.h file

Reenable LuaConsole rendering
This commit is contained in:
Alexander Bock
2015-12-14 17:21:22 -08:00
parent c99666e75a
commit c92fc923f9
17 changed files with 83 additions and 108 deletions
+3 -2
View File
@@ -34,6 +34,7 @@
#include <ghoul/io/texture/texturereader.h>
#include <ghoul/opengl/textureunit.h>
#include <ghoul/filesystem/filesystem.h>
#include <openspace/scene/scenegraphnode.h>
#include <openspace/util/time.h>
#include <openspace/util/spicemanager.h>
@@ -72,13 +73,13 @@ RenderableModel::RenderableModel(const ghoul::Dictionary& dictionary)
, _frameCount(0)
{
std::string name;
bool success = dictionary.getValue(constants::scenegraphnode::keyName, name);
bool success = dictionary.getValue(SceneGraphNode::KeyName, name);
ghoul_assert(success, "Name was not passed to RenderableModel");
ghoul::Dictionary geometryDictionary;
success = dictionary.getValue(keyGeometry, geometryDictionary);
if (success) {
geometryDictionary.setValue(constants::scenegraphnode::keyName, name);
geometryDictionary.setValue(SceneGraphNode::KeyName, name);
_geometry = modelgeometry::ModelGeometry::createFromDictionary(geometryDictionary);
}
+4 -3
View File
@@ -31,6 +31,7 @@
#include <openspace/util/constants.h>
#include <openspace/util/time.h>
#include <openspace/util/spicemanager.h>
#include <openspace/scene/scenegraphnode.h>
#include <ghoul/filesystem/filesystem.h>
#include <ghoul/misc/assert.h>
@@ -65,9 +66,9 @@ RenderablePlanet::RenderablePlanet(const ghoul::Dictionary& dictionary)
, _hasNightTexture(false)
{
std::string name;
bool success = dictionary.getValue(constants::scenegraphnode::keyName, name);
bool success = dictionary.getValue(SceneGraphNode::KeyName, name);
ghoul_assert(success,
"RenderablePlanet need the '" <<constants::scenegraphnode::keyName<<"' be specified");
"RenderablePlanet need the '" << SceneGraphNode::KeyName<<"' be specified");
//std::string path;
//success = dictionary.getValue(constants::scenegraph::keyPathModule, path);
@@ -77,7 +78,7 @@ RenderablePlanet::RenderablePlanet(const ghoul::Dictionary& dictionary)
ghoul::Dictionary geometryDictionary;
success = dictionary.getValue(keyGeometry, geometryDictionary);
if (success) {
geometryDictionary.setValue(constants::scenegraphnode::keyName, name);
geometryDictionary.setValue(SceneGraphNode::KeyName, name);
//geometryDictionary.setValue(constants::scenegraph::keyPathModule, path);
_geometry = planetgeometry::PlanetGeometry::createFromDictionary(geometryDictionary);
}
@@ -25,6 +25,7 @@
#include <modules/base/rendering/simplespheregeometry.h>
#include <openspace/util/constants.h>
#include <openspace/util/powerscaledsphere.h>
#include <openspace/scene/scenegraphnode.h>
namespace {
const std::string _loggerCat = "SimpleSphereGeometry";
@@ -48,12 +49,11 @@ SimpleSphereGeometry::SimpleSphereGeometry(const ghoul::Dictionary& dictionary)
, _segments("segments", "Segments", 20, 1, 50)
, _sphere(nullptr)
{
using constants::scenegraphnode::keyName;
using constants::simplespheregeometry::keyRadius;
using constants::simplespheregeometry::keySegments;
// The name is passed down from the SceneGraphNode
bool success = dictionary.getValue(keyName, _name);
bool success = dictionary.getValue(SceneGraphNode::KeyName, _name);
assert(success);
glm::vec4 radius;