Update RenderableGlobe to use transformation from SceneGraphnNode and fix bug in SpiceRotation.

This commit is contained in:
Kalle Bladin
2016-08-18 14:21:20 -04:00
parent b5b388bf54
commit ae1f8e457b
12 changed files with 54 additions and 79 deletions
@@ -178,13 +178,6 @@ namespace openspace {
}
void RenderableGlobe::update(const UpdateData& data) {
// set spice-orientation in accordance to timestamp
_chunkedLodGlobe->setStateMatrix(
SpiceManager::ref().positionTransformMatrix(_frame, "GALACTIC", data.time));
// We currently do not consider rotation anywhere in the rendering.
// @TODO Consider rotation everywhere in the rendering (culling, splitting, camera, etc)
//_chunkedLodGlobe->setStateMatrix(glm::dmat3(1.0));
_time = data.time;
_distanceSwitch.update(data);
@@ -207,10 +200,6 @@ namespace openspace {
return _ellipsoid;
}
const glm::dmat3& RenderableGlobe::stateMatrix() {
return _chunkedLodGlobe->stateMatrix();
}
float RenderableGlobe::getHeight(glm::dvec3 position) {
// Get the tile provider for the height map
const auto& heightMapProviders = _tileProviderManager->getTileProviderGroup(LayeredTextures::HeightMaps).getActiveTileProviders();