mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-01-05 03:00:58 -06:00
78 lines
2.5 KiB
Plaintext
78 lines
2.5 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.time.setTime(openspace.time.currentWallTime())
|
|
dofile(openspace.absPath('${SCRIPTS}/bind_keys.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("Sun.renderable.enab`led", true)
|
|
openspace.setPropertyValue("SunGlare.renderable.enabled", false)
|
|
openspace.setPropertyValue("SunMarker.renderable.enabled", false)
|
|
openspace.setPropertyValue("EarthMarker.renderable.enabled", false)
|
|
openspace.setPropertyValue("Constellation Bounds.renderable.enabled", false)
|
|
|
|
openspace.setPropertyValue("MilkyWay.renderable.transparency", 0.55)
|
|
openspace.setPropertyValue("MilkyWay.renderable.segments", 50)
|
|
|
|
openspace.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 = {526781518487.171326, 257168309890.072144, -1381125204152.817383},
|
|
Rotation = {-0.106166, 0.981574, -0.084545, 0.134513},
|
|
},
|
|
Modules = {
|
|
"sun",
|
|
"mercury",
|
|
"venus",
|
|
"earth",
|
|
"mars",
|
|
"jupiter",
|
|
"saturn",
|
|
"uranus",
|
|
"neptune",
|
|
"stars",
|
|
-- "stars-denver",
|
|
"milkyway",
|
|
--"milkyway-eso",
|
|
"constellationbounds",
|
|
}
|
|
}
|