Changes to fix Dawn scene.

This commit is contained in:
Jonathas Costa
2020-01-27 17:23:05 -05:00
parent bf9df85327
commit 607451e04b
5 changed files with 36 additions and 13 deletions

View File

@@ -666,11 +666,17 @@ local Dawn = {
local DawnSolarArray1 = {
Identifier = "DawnSolar1",
Parent = Dawn.Identifier,
Transformation = {
Transform = {
-- JCC: Spice rotations are commented because spice ck files
-- are not present.
-- Rotation = {
-- Type = "SpiceRotation",
-- SourceFrame = "DAWN_SA-Y",
-- DestinationFrame = "DAWN_SPACECRAFT"
-- }
Rotation = {
Type = "SpiceRotation",
SourceFrame = "DAWN_SA-Y",
DestinationFrame = "DAWN_SPACECRAFT"
Type = "StaticRotation",
Rotation = {0.0, 4.71225, 0.0}
}
},
Renderable = {
@@ -693,11 +699,15 @@ local DawnSolarArray1 = {
local DawnSolarArray2 = {
Identifier = "DawnSolar2",
Parent = Dawn.Identifier,
Transformation = {
Transform = {
-- Rotation = {
-- Type = "SpiceRotation",
-- SourceFrame = "DAWN_SA+Y",
-- DestinationFrame = "DAWN_SPACECRAFT"
-- }
Rotation = {
Type = "SpiceRotation",
SourceFrame = "DAWN_SA+Y",
DestinationFrame = "DAWN_SPACECRAFT"
Type = "StaticRotation",
Rotation = {3.1415, 1.57075, 0.0}
}
},
Renderable = {

View File

@@ -2,7 +2,7 @@ local Kernels = asset.syncedResource({
Name = "Dawn Kernels",
Type = "HttpSynchronization",
Identifier = "dawn_kernels",
Version = 1
Version = 2
})
asset.export("Kernels", Kernels)

View File

@@ -47,8 +47,9 @@ local Vesta = {
Type = "RenderableModelProjection",
Geometry = {
Type = "MultiModelGeometry",
GeometryFile = models .. "/VestaComet/VestaComet_5000.obj"
GeometryFile = models .. "/VestaComet_5000.obj"
},
BoundingSphereRadius = 10.0,
ColorTexture = textures .. "/dummy.jpg",
Projection = {
Sequence = images,

View File

@@ -59,6 +59,7 @@ Asset = "default"
-- Asset = "apollo8"
-- Asset = "apollo_sites"
-- Asset = "touch"
-- Asset = "dawn"
-- These scripts are executed after the initialization of each scene, thus making
-- it possible to have global overrides to default values or execute other scripts
@@ -135,7 +136,7 @@ ModuleConfigurations = {
WebSocketInterface = "DefaultWebSocketInterface"
},
CefWebGui = {
--GuiScale = 2.1,
GuiScale = 2.1,
Enabled = true,
Visible = true
}

View File

@@ -141,15 +141,26 @@ Renderable::Renderable(const ghoul::Dictionary& dictionary)
}
if (dictionary.hasKey(OpacityInfo.identifier)) {
_opacity = static_cast<float>(dictionary.value<double>(OpacityInfo.identifier));
_opacity = static_cast<float>(dictionary.value<double>(
OpacityInfo.identifier)
);
}
addProperty(_enabled);
//set type for UI
if (dictionary.hasKey(RenderableTypeInfo.identifier)) {
_renderableType = dictionary.value<std::string>(RenderableTypeInfo.identifier);
_renderableType = dictionary.value<std::string>(
RenderableTypeInfo.identifier
);
}
if (dictionary.hasKey(BoundingSphereInfo.identifier)) {
_boundingSphere = static_cast<float>(
dictionary.value<double>(BoundingSphereInfo.identifier)
);
}
addProperty(_renderableType);
addProperty(_boundingSphere);
}