mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-01-06 03:29:44 -06:00
72 lines
2.4 KiB
Plaintext
72 lines
2.4 KiB
Plaintext
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}/naif0011.tls")
|
|
openspace.spice.loadKernel("${SPICE}/pck00010.tpc")
|
|
-- openspace.spice.loadKernel("${OPENSPACE_DATA}/spice/de430_1850-2150.bsp")
|
|
|
|
openspace.time.setTime(openspace.time.currentWallTime())
|
|
|
|
--Test for vernal equinox time 2017
|
|
--openspace.time.setTime("2017 MAR 20 10:28:30.500")
|
|
|
|
dofile(openspace.absPath('${SCRIPTS}/bind_keys_satellites.lua'))
|
|
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("SunMarker.renderable.Enabled", false)
|
|
openspace.setPropertyValue("SunGlare.renderable.Enabled", false)
|
|
openspace.setPropertyValue("MilkyWay.renderable.Enabled", false)
|
|
openspace.setPropertyValue("EarthMarker.renderable.Enabled", false)
|
|
openspace.setPropertyValue("EarthTrail.renderable.Enabled", false)
|
|
openspace.setPropertyValue("Earth.renderable.PerformShading", false)
|
|
|
|
openspace.navigation.resetCameraDirection()
|
|
|
|
openspace.printInfo("Done setting default values")
|
|
|
|
if openspace.modules.isLoaded("ISWA") then
|
|
|
|
openspace.iswa.addCdfFiles("${OPENSPACE_DATA}/cdflist.json");
|
|
|
|
--openspace.iswa.addCygnet(7);
|
|
|
|
--openspace.iswa.addCygnet(-4,"Data","Gm");
|
|
--openspace.iswa.addCygnet(-5,"Data","Gm");
|
|
--openspace.iswa.addCygnet(-6,"Data","Gm");
|
|
--openspace.iswa.addCygnet(-7,"Data","Gm");
|
|
--openspace.iswa.addCygnet(-8,"Data","Gm");
|
|
--openspace.iswa.addCygnet(-9,"Data","Gm");
|
|
end
|
|
end
|
|
|
|
return {
|
|
ScenePath = ".",
|
|
CommonFolder = "common",
|
|
Camera = {
|
|
Focus = "Earth",
|
|
Position = {-54343425747.129051, -73298476295.934555, 116584089130.590012},
|
|
Rotation = {-0.078983, 0.830093, 0.014241, -0.551819},
|
|
},
|
|
Modules = {
|
|
--"satellites/earth",
|
|
"sun",
|
|
"earth",
|
|
-- "stars",
|
|
-- "milkyway",
|
|
"satellites"
|
|
}
|
|
}
|
|
|