Files
OpenSpace/data/scene/newhorizons.scene
T
Alexander Bock fc63e51ece Sort milkyway and stars
Remove keybinding scripts
Remove satellites
2017-07-28 14:10:55 -04:00

202 lines
7.6 KiB
Plaintext

UseAccurateNewHorizonsKernels = false
-- TextureResolution = "low"
TextureResolution = "med"
-- TextureResolution = "high"
function preInitialization()
--[[
The scripts in this function are executed after the scene is loaded but before the
scene elements have been initialized, thus they should be used to set the time at
which the scene should start and other settings that might determine initialization
critical objects.
]]--
openspace.spice.loadKernel("${SPICE}/naif0012.tls")
openspace.spice.loadKernel("${SPICE}/pck00010.tpc")
openspace.time.setTime("2015-07-14T10:05:00.00")
-- Load the common helper functions
dofile(openspace.absPath('${SCRIPTS}/common.lua'))
openspace.clearKeys()
helper.setCommonKeys()
helper.setDeltaTimeKeys({
1, 5, 10, 20, 40, 60, 120, 360, 540, 1080,
2160, 4320, 8640
})
openspace.bindKey(
"a",
"openspace.setPropertyValue('Interaction.origin', 'NewHorizons')",
"Sets the focus of the camera on 'NewHorizons'."
)
openspace.bindKey(
"s",
"openspace.setPropertyValue('Interaction.origin', 'Pluto')",
"Sets the focus of the camera on 'Pluto'"
)
openspace.bindKey(
"d",
"openspace.setPropertyValue('Interaction.origin', 'Charon')",
"Sets the focus of the camera on 'Charon'."
)
openspace.bindKey(
"z",
"openspace.setPropertyValue('Interaction.origin', 'JupiterProjection')",
"Sets the focus of the camera on 'Jupiter'."
)
openspace.bindKey(
"x",
"openspace.setPropertyValue('Interaction.origin', 'Europa')",
"Sets the focus of the camera on 'Europa'."
)
openspace.bindKey(
"F8",
"openspace.setPropertyValue('Pluto.renderable.ProjectionComponent.clearAllProjections', true);" ..
"openspace.setPropertyValue('Charon.renderable.ProjectionComponent.clearAllProjections', true);",
"Removes all image projections from Pluto and Charon."
)
openspace.bindKey(
"F9",
"openspace.time.setTime('2015-07-14T09:00:00.00');" ..
"openspace.setPropertyValue('Pluto.renderable.clearAllProjections', true);" ..
"openspace.setPropertyValue('Charon.renderable.clearAllProjections', true);",
"Jumps to the 14th of July 2015 at 0900 UTC and clears all projections."
)
openspace.bindKey(
"KP_8",
helper.property.increment('Pluto.renderable.heightExaggeration', 0.1),
"Increases the height map exaggeration on Pluto."
)
openspace.bindKey(
"KP_2",
helper.property.decrement('Pluto.renderable.heightExaggeration', 0.1),
"Decreases the height map exaggeration on Pluto."
)
openspace.bindKey(
"KP_9",
helper.property.increment('Charon.renderable.heightExaggeration', 2),
"Increases the height map exaggeration on Charon."
)
openspace.bindKey(
"KP_3",
helper.property.decrement('Charon.renderable.heightExaggeration', 2),
"Decreases the height map exaggeration on Charon."
)
openspace.bindKey(
"q",
helper.property.invert('SunMarker.renderable.enabled'),
"Toggles the visibility of the text marking the location of the Sun."
)
openspace.bindKey(
"e",
helper.property.invert('EarthMarker.renderable.enabled'),
"Toggles the visibility of the text marking the location of the Earth."
)
openspace.bindKey(
"o",
helper.property.invert('PlutoTrail.renderable.enabled'),
"Toggles the visibility of the trail behind Pluto."
)
openspace.bindKey(
"j",
helper.renderable.toggle('PlutoText') .. helper.renderable.toggle('CharonText') ..
helper.renderable.toggle('HydraText') .. helper.renderable.toggle('NixText') ..
helper.renderable.toggle('KerberosText') .. helper.renderable.toggle('StyxText'),
"Toggles the visibility of the text labels of Pluto, Charon, Hydra, Nix, Kerberos, and Styx."
)
openspace.bindKey(
"l",
helper.property.invert('Labels.renderable.performFading'),
"Toggles the visibility of the labels for the New Horizons instruments."
)
openspace.bindKey("m",
helper.property.invert('NH_LORRI.renderable.solidDraw') ..
helper.property.invert('NH_RALPH_LEISA.renderable.solidDraw') ..
helper.property.invert('NH_RALPH_MVIC_PAN1.renderable.solidDraw') ..
helper.property.invert('NH_RALPH_MVIC_PAN2.renderable.solidDraw') ..
helper.property.invert('NH_RALPH_MVIC_RED.renderable.solidDraw') ..
helper.property.invert('NH_RALPH_MVIC_BLUE.renderable.solidDraw') ..
helper.property.invert('NH_RALPH_MVIC_FT.renderable.solidDraw') ..
helper.property.invert('NH_RALPH_MVIC_METHANE.renderable.solidDraw') ..
helper.property.invert('NH_RALPH_MVIC_NIR.renderable.solidDraw') ..
helper.property.invert('NH_ALICE_AIRGLOW.renderable.solidDraw') ..
helper.property.invert('NH_ALICE_SOC.renderable.solidDraw'),
"Draws the instrument field of views in a solid color or as lines."
)
openspace.bindKey(
"t",
helper.renderable.toggle('PlutoShadow') .. helper.renderable.toggle('CharonShadow'),
"Toggles the visibility of the shadow visualization of Pluto and Charon."
)
openspace.bindKey("p",
helper.property.invert('JupiterProjection.renderable.performProjection') ..
helper.property.invert('Io.renderable.performProjection') ..
helper.property.invert('Ganymede.renderable.performProjection') ..
helper.property.invert('Europa.renderable.performProjection') ..
helper.property.invert('Callisto.renderable.performProjection') ..
helper.property.invert('Pluto.renderable.performProjection') ..
helper.property.invert('Charon.renderable.performProjection'),
"Enables or disables the image projection on the different available objects."
)
end
function postInitialization()
--[[
The scripts in this function are executed after all objects in the scene have been
created and initialized, but before the first render call. This is the place to set
graphical settings for the renderables.
]]--
openspace.printInfo("Setting default values")
openspace.setPropertyValue("Sun.renderable.Enabled", false)
openspace.setPropertyValue("SunMarker.renderable.Enabled", true)
openspace.setPropertyValue("EarthMarker.renderable.Enabled", true)
--openspace.setPropertyValue("Constellation Bounds.renderable.enabled", false)
openspace.setPropertyValue("PlutoTrail.renderable.Enabled", false)
openspace.setPropertyValue("PlutoTexture.renderable.Enabled", false)
openspace.setPropertyValue("MilkyWay.renderable.Transparency", 0.55)
openspace.setPropertyValue("MilkyWay.renderable.Segments", 50)
openspace.printInfo("Done setting default values")
end
return {
ScenePath = ".",
CommonFolder = "common",
Camera = {
Focus = "NewHorizons",
Position = {4662120063743.592773, 1263245003503.724854, -955413856565.788086},
Rotation = {0.683224, -0.165934, 0.701234, 0.118073},
},
Modules = {
"sun",
"mercury",
"venus",
"earth",
"mars",
"saturn/saturn",
"uranus",
"neptune",
"stars/digitaluniverse",
-- "stars/denver",
"milkyway/digitaluniverse",
--"milkyway/eso",
"missions/newhorizons/pluto",
"missions/newhorizons/jupiter",
"missions/newhorizons/newhorizons",
"missions/newhorizons/newhorizonsfov"
}
}