Issue/890 (#892)

* Cleanup of Apollo scene shortcuts
* Fixing Apollo 8 and flipbook shortcuts
* Updated Apollo sites to new LEM model based on photogrammetry
* Add new asset file to manage synchronization of LEM model
This commit is contained in:
Micah Acinapura
2019-06-03 05:07:25 -04:00
committed by Alexander Bock
parent 00f7e7dba0
commit 62f92e0ff2
10 changed files with 197 additions and 216 deletions
+39 -20
View File
@@ -9,14 +9,6 @@ asset.require('scene/solarsystem/missions/apollo/apollo8.asset')
-- Custom Keybindings
local Keybindings = {
-- {
-- Key = "SHIFT+E",
-- Command = "openspace.time.setPause(true);" ..
-- "openspace.time.setTime('1968 DEC 24 16:37:19');",
-- Documentation = "Jump to time pre earthrise",
-- Local = false
-- },
{
Key = "E",
Command = "openspace.time.setPause(true);" ..
@@ -24,61 +16,88 @@ local Keybindings = {
"openspace.setPropertyValue('Scene.Apollo8LaunchTrail.Renderable.Enabled', false)"..
"openspace.sessionRecording.startPlayback('apollo8')",
Documentation = "Jump to right before the earthrise photo",
Name = "Set Earthrise time",
GuiPath = "/Missions/Apollo/8",
Local = false
},
{
Key = "U",
Command = "openspace.time.setTime('1968-12-21T12:51:37.00')" ..
"openspace.setPropertyValueSingle('Scene.Apollo8LaunchTrail.Renderable.Enabled', true);",
Documentation = "Jump to time right before A8 liftoff",
Documentation = "Jump to time right before Apollo 8 liftoff, with its trail enabled",
Name = "Set Apollo 8 launch time",
GuiPath = "/Missions/Apollo/8",
Local = false
},
{
Key = "K",
Command = propertyHelper.invert('Scene.Moon.Renderable.Layers.ColorLayers.Kaguya_Utah.Enabled'),
Documentation = "Toggles Moon Kaguya color layer",
Name = "Toggle Kaguya layer on the Moon",
GuiPath = "/Missions/Apollo",
Local = false
},
{
Key = "T",
Command = propertyHelper.invert('Scene.Apollo8MoonTrail.Renderable.Enabled'),
Documentation = "Toggles the trails of the Apollo8 orbits",
Documentation = "Toggles the trails of the Apollo 8 orbits, focused around the Moon",
Name = "Toggle Apollo 8 orbits",
GuiPath = "/Missions/Apollo/8",
Local = false
},
{
Key = "SHIFT+T",
Command = propertyHelper.invert('Scene.Apollo8LaunchTrail.Renderable.Enabled'),
Documentation = "Toggles the trails of the Apollo8 Launch",
Documentation = "Toggles the trails of the Apollo 8 Launch, focused around the Earth",
Name = "Toggle Apollo 8 launch trail",
GuiPath = "/Missions/Apollo/8",
Local = false
},
{
Key = "CTRL+T",
Command = propertyHelper.invert('Scene.Apollo8EarthBarycenterTrail.Renderable.Enabled'),
Documentation = "Toggles the trails of the full Apollo8",
Documentation = "Toggles the trails of the full Apollo 8, with Earth's frame of reference",
Name = "Toggles Apollo 8 full trail",
GuiPath = "/Missions/Apollo/8",
Local = false
},
{
Key = "S",
Command = propertyHelper.invert('Scene.Moon.RenderableGlobe.PerformShading'),
Documentation = "Toggles shading for the moon",
Command = propertyHelper.invert('Scene.Moon.Renderable.PerformShading'),
Documentation = "Toggles shading for the Moon",
Name = "Toggle Moon shading",
GuiPath = "/Missions/Apollo",
Local = false
},
{
Key = "PAGE_UP",
Command = "openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.Anchor', 'Apollo8');",
Documentation = "Focus on apollo 8",
Command = "openspace.setPropertyValueSingle('NavigationHandler.OrbitalNavigator.Aim', '')" ..
"openspace.setPropertyValueSingle('NavigationHandler.OrbitalNavigator.Anchor', 'Apollo8')" ..
"openspace.setPropertyValueSingle('NavigationHandler.OrbitalNavigator.RetargetAnchor', nil)",
Documentation = "Set camera focus to Apollo 8",
Name = "Focus on Apollo 8",
GuiPath = "/Missions/Apollo/8",
Local = false
},
{
Key = "PAGE_DOWN",
Command = "openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.Anchor', 'Moon');",
Documentation = "Focus on moon",
Command = "openspace.setPropertyValueSingle('NavigationHandler.OrbitalNavigator.Aim', '')" ..
"openspace.setPropertyValueSingle('NavigationHandler.OrbitalNavigator.Anchor', 'Moon')" ..
"openspace.setPropertyValueSingle('NavigationHandler.OrbitalNavigator.RetargetAnchor', nil)",
Documentation = "Set camera focus to the Moon",
Name = "Focus on Moon",
GuiPath = "/Missions/Apollo",
Local = false
},
{
Key = "HOME",
Command = "openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.Anchor', 'Earth');",
Documentation = "Focus on earth",
Command = "openspace.setPropertyValueSingle('NavigationHandler.OrbitalNavigator.Aim', '')" ..
"openspace.setPropertyValueSingle('NavigationHandler.OrbitalNavigator.Anchor', 'Earth')" ..
"openspace.setPropertyValueSingle('NavigationHandler.OrbitalNavigator.RetargetAnchor', nil)",
Documentation = "Set camera focus to the Earth",
Name = "Focus on Earth",
GuiPath = "/Missions/Apollo",
Local = false
}
}
+8 -21
View File
@@ -23,16 +23,13 @@ local Keybindings = {
},
{
Key = "F9",
Command = "openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.ColorLayers.A17_LEM.Enabled', false);" ..
Command = "openspace.setPropertyValue('Scene.Moon.Renderable.Layers.ColorLayers.A17_*.Enabled', false);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.HeightLayers.LRO_NAC_Apollo_11.Enabled', false);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.ColorLayers.A11_M177481212_p_longlat.Enabled', false);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.ColorLayers.A17_NAC_Alt_p.Enabled', false);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.HeightLayers.LRO_NAC_Apollo_17.Enabled', false);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.ColorLayers.A17_LEM.Enabled', false);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.ColorLayers.A17_travmap.Enabled', false)",
Documentation = "Disable site when switching",
Name = "Disable apollo site",
GuiPath = "/Missions/Apollo/11",
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.HeightLayers.LRO_NAC_Apollo_17.Enabled', false);",
Documentation = "Disable apollo site on moon when switching",
Name = "Disable Apollo site",
GuiPath = "/Missions/Apollo",
Local = false
},
{
@@ -41,7 +38,7 @@ local Keybindings = {
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.HeightLayers.LRO_NAC_Apollo_11.Enabled', true);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.ColorLayers.A11_M177481212_p_longlat.Enabled', true);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.LodScaleFactor', 20.11);" ..
"openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.Anchor', 'Apollo11Lem');" ..
"openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.Anchor', 'Apollo11LemModel');" ..
"openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.RetargetAnchor', nil);",
Documentation = "Setup for A11 site",
Name = "Setup A11 site",
@@ -64,23 +61,13 @@ local Keybindings = {
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.ColorLayers.A17_NAC_Alt_p.Enabled', true);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.ColorLayers.A17_NAC_Alt_p.BlendMode', 0.000000);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.LodScaleFactor', 20.17);" ..
"openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.Anchor', 'Apollo17Lem');" ..
"openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.Anchor', 'Apollo17LemModel');" ..
"openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.RetargetAnchor', nil);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.ColorLayers.A17_station7.BlendMode', 0.000000);",
Documentation = "Setup for A17 site",
Name = "Setup A17 site",
GuiPath = "/Missions/Apollo/17",
Local = false
},
{
Key = "SHIFT+F7",
Command = "openspace.setPropertyValue('Scene.Moon.Renderable.Layers.ColorLayers.A17_*.Enabled', false);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.HeightLayers.LRO_NAC_Apollo_17.Enabled', false);" ..
"openspace.setPropertyValueSingle('Scene.Moon.Renderable.LodScaleFactor', 20.117);",
Documentation = "Setup for A17 site",
Name = "Setup A17 layers",
GuiPath = "/Missions/Apollo/17",
Local = false
}
}
@@ -90,7 +77,7 @@ asset.onInitialize(function ()
sceneHelper.bindKeys(Keybindings)
openspace.markInterestingNodes({ "Apollo11Lem", "Apollo17Lem" })
openspace.markInterestingNodes({ "Apollo11LemModel", "Apollo17LemModel" })
-- To enable both sites by default, uncomment these lines
-- openspace.setPropertyValueSingle('Scene.Moon.Renderable.Layers.ColorLayers.A17_travmap.BlendMode', 0.000000);
+8 -4
View File
@@ -10,13 +10,15 @@ local Keybindings = {
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.HeightLayers.OnMarsHiRISELS.Settings.Offset', -470.800006);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.insight_ctx.Enabled', true);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.HeightLayers.OnMarsHiRISELS.Enabled', true);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.insight_ctx.Settings.Gamma', 3.098590);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.insight_ctx.Settings.Multiplier', 3.568080);" ..
-- "openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.insight_ctx.Settings.Gamma', 3.098590);" ..
-- "openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.insight_ctx.Settings.Multiplier', 3.568080);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.MOC_WA_Color_Utah.Settings.Multiplier', 2.816900);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.OnMarsHiRISELS.Settings.Gamma', 0.938970);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.MOC_WA_Color_Utah.Settings.Gamma', 2.394370);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.OnMarsHiRISELS.Enabled', true);",
Documentation = "Setup Insight landing layers",
Name = "Setup Insight layers",
GuiPath = "/Missions/Insight",
Local = false
},
{
@@ -26,12 +28,14 @@ local Keybindings = {
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.insight_ctx.Enabled', false);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.HeightLayers.OnMarsHiRISELS.Enabled', false);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.OnMarsHiRISELS.Enabled', false);",
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.insight_ctx.Settings.Gamma', 1.0);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.insight_ctx.Settings.Multiplier', 1.0);" ..
-- "openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.insight_ctx.Settings.Gamma', 1.0);" ..
-- "openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.insight_ctx.Settings.Multiplier', 1.0);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.MOC_WA_Color_Utah.Settings.Multiplier', 1.0);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.OnMarsHiRISELS.Settings.Gamma', 1.0);" ..
"openspace.setPropertyValueSingle('Scene.Mars.Renderable.Layers.ColorLayers.MOC_WA_Color_Utah.Settings.Gamma', 1.0);";
Documentation = "Undo Insight landing layers setup",
Name = "Unset Insight layers",
GuiPath = "/Missions/Insight",
Local = false
}
}
+40 -18
View File
@@ -12,62 +12,84 @@ local Keybindings = {
Key = "a",
Command = "openspace.setPropertyValue('NavigationHandler.Origin', 'OsirisRex')",
Documentation = "Sets the focus of the camera on 'OsirisRex'.",
Name = "Focus on OsirisRex",
GuiPath = "/Missions/Osiris Rex",
Local = false
},
{
Key = "s",
Command = "openspace.setPropertyValue('NavigationHandler.Origin', 'BennuBarycenter')",
Documentation = "Sets the focus of the camera on 'Bennu'",
Name = "Focus on Bennu",
GuiPath = "/Missions/Osiris Rex",
Local = false
},
{
Key = "F6",
Command = "openspace.printInfo('Set time: Launch');openspace.time.setTime('2016 SEP 08 23:05:00');",
Documentation = "Sets the time to the launch.",
Local = false
},
{
Key = "F7",
Command = "openspace.printInfo('Set time: Gravity Assist');openspace.time.setTime('2017 SEP 22 15:00:00');",
Documentation = "Sets the time to the Earth gravity assist.",
Local = false
},
-- TODO
-- Maybe these can be fixed later
-- {
-- Key = "F6",
-- Command = "openspace.printInfo('Set time: Launch');openspace.time.setTime('2016 SEP 08 23:05:00');",
-- Documentation = "Sets the time to the launch of Osiris Rex.",
-- Name = "Set launch time",
-- GuiPath = "/Missions/Osiris Rex",
-- Local = false
-- },
-- {
-- Key = "F7",
-- Command = "openspace.printInfo('Set time: Gravity Assist');openspace.time.setTime('2017 SEP 22 15:00:00');",
-- Documentation = "Sets the time to the Earth gravity assist.",
-- Name = "Set Earth gravity assist time",
-- GuiPath = "/Missions/Osiris Rex",
-- Local = false
-- },
{
Key = "F8",
Command = "openspace.printInfo('Set time: Approach');openspace.time.setTime('2018-SEP-11 21:31:01.183');",
Documentation = "Sets the time to the approach at Bennu.",
Name = "Set Bennu approach time",
GuiPath = "/Missions/Osiris Rex",
Local = false
},
{
Key = "F9",
Command = "openspace.printInfo('Set time: Preliminary Survey');openspace.time.setTime('2018-NOV-20 01:13:12.183');",
Documentation = "Sets the time to the preliminary survey of Bennu.",
Name = "Set Bennu survey time",
GuiPath = "/Missions/Osiris Rex",
Local = false
},
{
Key = "F10",
Command = "openspace.printInfo('Set time: Orbital B');openspace.time.setTime('2019-APR-08 10:35:27.186');",
Documentation = "Sets the time to the orbital B event.",
Name = "Set orbital B event time",
GuiPath = "/Missions/Osiris Rex",
Local = false
},
{
Key = "F11",
Command = "openspace.printInfo('Set time: Recon');openspace.time.setTime('2019-MAY-25 03:50:31.195');",
Documentation = "Sets the time to the recon event.",
Name = "Set recon event time",
GuiPath = "/Missions/Osiris Rex",
Local = false
},
{
Key = "q",
Command = propertyHelper.invert('Scene.SunMarker.Renderable.Enabled'),
Documentation = "Toggles the visibility of the text marking the location of the Sun.",
Name = "Toggle Sun marker",
GuiPath = "/Missions/Osiris Rex",
Local = false
},
{
Key = "e",
Command = propertyHelper.invert('Scene.EarthMarker.Renderable.Enabled'),
Documentation = "Toggles the visibility of the text marking the location of the Earth.",
Local = false
}
-- {
-- Key = "e",
-- Command = propertyHelper.invert('Scene.EarthMarker.Renderable.Enabled'),
-- Documentation = "Toggles the visibility of the text marking the location of the Earth.",
-- Name = "Toggle Earth marker",
-- GuiPath = "/Missions/Osiris Rex",
-- Local = false
-- }
}
local OsirisRexAsset = asset.require('scene/solarsystem/missions/osirisrex/model')
+26 -6
View File
@@ -17,6 +17,8 @@ local Keybindings = {
"openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.Aim', '');" ..
"openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.RetargetAnchor', nil)",
Documentation = "Sets the focus of the camera on '67P'.",
Name = "Focus on 67P",
GuiPath = "/Missions/Rosetta",
Local = false
},
{
@@ -25,55 +27,73 @@ local Keybindings = {
"openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.Aim', '');" ..
"openspace.setPropertyValue('NavigationHandler.OrbitalNavigator.RetargetAnchor', nil)",
Documentation = "Sets the focus of the camera on 'Rosetta'",
Name = "Focus on Rosetta",
GuiPath = "/Missions/Rosetta",
Local = false
},
{
Key = "F5",
Command = "openspace.time.setTime('2014-08-01T03:05:18.101')",
Documentation = "Jumps to the time of initial approach of Rosetta to 67P.",
Name = "Set initial approach time",
GuiPath = "/Missions/Rosetta",
Local = false
},
{
Key = "F6",
Command = "openspace.time.setTime('2014-11-12T08:20:00.00')",
Documentation = "Jumps to the time when the Philae lander is released.",
Name = "Set lander release time",
GuiPath = "/Missions/Rosetta",
Local = false
},
{
Key = "F8",
Command = "openspace.setPropertyValue('Scene.67P.Renderable.ProjectionComponent.ClearAllProjections', true)",
Documentation = "Removes all image projections from 67P.",
Name = "Clear 67P projections",
GuiPath = "/Missions/Rosetta",
Local = false
},
{
Key = "q",
Command = propertyHelper.invert('Scene.SunMarker.Renderable.Enabled'),
Documentation = "Toggles the visibility of the text marking the location of the Sun.",
Local = false
},
-- {
-- Key = "q",
-- Command = propertyHelper.invert('Scene.SunMarker.Renderable.Enabled'),
-- Documentation = "Toggles the visibility of the text marking the location of the Sun.",
-- Name = "Toggle Sun marker",
-- GuiPath = "/Missions/Rosetta",
-- Local = false
-- },
{
Key = "e",
Command = renderableHelper.toggle('Scene.JupiterTrail') .. renderableHelper.toggle('Scene.SaturnTrail') ..
renderableHelper.toggle('Scene.UranusTrail') .. renderableHelper.toggle('Scene.NeptuneTrail'),
Documentation = "Toggles the visibility of all trails further from the Sun than 67P.",
Name = "Toggle outer planetary trails",
GuiPath = "/Missions/Rosetta",
Local = false
},
{
Key = "i",
Command = renderableHelper.toggle('Scene.ImagePlaneRosetta'),
Documentation = "Toggles the visibility of the free floating image plane.",
Name = "Toggle image plane",
GuiPath = "/Missions/Rosetta",
Local = false
},
{
Key = "g",
Command = renderableHelper.toggle('Scene.PhilaeTrail'),
Documentation = "Toggles the visibility of Philae's trail.",
Name = "Toggle Philae trail",
GuiPath = "/Missions/Rosetta",
Local = false
},
{
Key = "p",
Command = propertyHelper.invert('Scene.67P.Renderable.ProjectionComponent.PerformProjection'),
Documentation = "Enables or disables the image projection on 67P.",
Name = "Toggle 67P projection",
GuiPath = "/Missions/Rosetta",
Local = false
}
}
@@ -1,9 +1,10 @@
-- a11_lem.asset
local assetHelper = asset.require('util/asset_helper')
local sunTransforms = asset.require('scene/solarsystem/sun/transforms')
local moonAsset = asset.require('scene/solarsystem/planets/earth/moon/moon')
local lem = asset.require('./apollo_lem')
local model = asset.require('scene/solarsystem/missions/apollo/lem_model')
local Apollo11Lem = {
Identifier = "Apollo11Lem",
@@ -17,98 +18,43 @@ local Apollo11Lem = {
FixedAltitude = -1927.65,
UseFixedAltitude = true
},
Scale = {
Type = "StaticScale",
Scale = 1.0
},
},
GUI = {
Name = "Apollo 11 Lem Position",
Path = "/Solar System/Missions/Apollo/11"
}
}
local Apollo11LemModel = {
Identifier = "Apollo11LemModel",
Parent = Apollo11Lem.Identifier,
Transform = {
Scale = {
Type = "StaticScale",
Scale = 0.24
}
},
Renderable = {
Type = "RenderableModel",
Geometry = {
Type = "MultiModelGeometry",
GeometryFile = model.modelFolder .. "/LM-2_ver2clean.obj"
},
ColorTexture = model.modelFolder .. "/LM-2_ver2clean_u1_v1.jpeg",
LightSources = assetHelper.getDefaultLightSources(sunTransforms.SolarSystemBarycenter.Identifier)
},
GUI = {
Hidden = false,
Name = "Apollo 11 Lem",
Path = "/Solar System/Missions/Apollo/11"
}
}
local Apollo11LemModel = {
Identifier = "Apollo11LemModel",
Parent = Apollo11Lem.Identifier,
GUI = {
Hidden = true,
Name = "Apollo 11 Lem Model",
Path = "/Solar System/Missions/Apollo/11"
}
}
-- local Apollo17LemPosition = {
-- Identifier = "Apollo17LemPosition",
-- Parent = moonAsset.Moon.Identifier,
-- Transform = {
-- Translation = {
-- Type = "GlobeTranslation",
-- Globe = moonAsset.Moon.Identifier,
-- Longitude = -360+30.77170,
-- Latitude = 20.19092,
-- }
-- }
-- }
-- local Apollo17Lem = {
-- Identifier = "Apollo17Lem",
-- Parent = Apollo17LemPosition.Identifier,
-- Transform = {
-- Scale = {
-- Type = "StaticScale",
-- Scale = 1.0
-- },
-- },
-- GUI = {
-- Name = "Apollo 17 Lem",
-- Path = "/Solar System/Missions/Apollo/17/Lem"
-- }
-- }
assetHelper.registerSceneGraphNodesAndExport(asset, {
Apollo11Lem,
Apollo11LemModel,
Apollo11LemModel
})
lem.registerLem(asset, Apollo11LemModel.Identifier)
asset.onInitialize(function ()
-- openspace.setPropertyValueSingle('Scene.Apollo17Lem.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Apollo11LemModel.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-texture_lem_flag.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-texture_lem_unitedstates.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-booster.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-bright_white.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-black.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-blue_glass.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-dark_grey_dish.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-dull_white.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-gold.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-light_grey.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-mid_grey.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-orange.Renderable.RotationVector', {73.074631,89.194031,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel-yellow_buttons.Renderable.RotationVector', {73.074631,89.194031,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_texture_lem_flag7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_texture_lem_unitedstates7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_booster7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_bright_white7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_Black7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_blue_glass7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_dark_grey_dish7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_dull_white7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_gold7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_light_grey7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_mid_grey7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_orange7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
-- openspace.setPropertyValueSingle('Scene.Lem_Part_yellow_buttons7.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo11LemModel.Renderable.RotationVector', { 91.044090,171.229706,111.666664} );
end)
@@ -1,10 +1,9 @@
--a11_lem.asset
--a17_lem.asset
local assetHelper = asset.require('util/asset_helper')
local earthAsset = asset.require('scene/solarsystem/planets/earth/earth')
local sunTransforms = asset.require('scene/solarsystem/sun/transforms')
local moonAsset = asset.require('scene/solarsystem/planets/earth/moon/moon')
local lem = asset.require('./apollo_lem')
local model = asset.require('scene/solarsystem/missions/apollo/lem_model')
local Apollo17Lem = {
Identifier = "Apollo17Lem",
@@ -13,54 +12,47 @@ local Apollo17Lem = {
Translation = {
Type = "GlobeTranslation",
Globe = moonAsset.Moon.Identifier,
Longitude = -360+30.77170,
Longitude = -329.22833,
Latitude = 20.19092,
},
Scale = {
Type = "StaticScale",
Scale = 1.0
},
},
GUI = {
Name = "Apollo 17 Lem",
Hidden = true,
Name = "Apollo 17 Lem Position",
Path = "/Solar System/Missions/Apollo/17"
}
}
local Apollo17LemModel = {
Identifier = "Apollo17LemModel",
Parent = Apollo17Lem.Identifier,
Transform = {
Scale = {
Type = "StaticScale",
Scale = 0.24
}
},
Renderable = {
Type = "RenderableModel",
Geometry = {
Type = "MultiModelGeometry",
GeometryFile = model.modelFolder .. "/LM-2_ver2clean.obj"
},
ColorTexture = model.modelFolder .. "/LM-2_ver2clean_u1_v1.jpeg",
LightSources = assetHelper.getDefaultLightSources(sunTransforms.SolarSystemBarycenter.Identifier)
},
GUI = {
Hidden = true,
Name = "Apollo 17 Lem Model",
Hidden = false,
Name = "Apollo 17 Lem",
Path = "/Solar System/Missions/Apollo/17"
}
}
assetHelper.registerSceneGraphNodesAndExport(asset, {
Apollo17Lem,
Apollo17LemModel,
})
lem.registerLem(asset, Apollo17LemModel.Identifier)
asset.onInitialize(function ()
-- openspace.setPropertyValueSingle('Scene.Apollo17LemModel.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-texture_lem_flag.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-texture_lem_unitedstates.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-booster.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-bright_white.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-black.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-blue_glass.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-dark_grey_dish.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-dull_white.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-gold.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-light_grey.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-mid_grey.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-orange.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel-yellow_buttons.Renderable.RotationVector', {68.031502,68.031502,8.545990});
openspace.setPropertyValueSingle('Scene.Apollo17LemModel.Renderable.RotationVector', { 110.255219,171.229706,126.666664 });
end)
@@ -14,42 +14,26 @@ local vrts = asset.syncedResource({
Version = 1
})
openspace.printDebug("set up assetfor vrts:" .. vrts);
asset.onInitialize(function ()
openspace.globebrowsing.addBlendingLayersFromDirectory(vrts, assetGlobe);
flipbook = helper.createFlipbook(assetPrefix, assetGlobe, 19);
-- openspace.setPropertyValueSingle("Scene.Moon.Renderable.Layers.ColorLayers.LRO_NAC_Apollo_11.Enabled", true)
-- openspace.setPropertyValueSingle("Scene.Moon.Renderable.Layers.HeightLayers.LRO_NAC_Apollo_11.Enabled", true)
-- openspace.setPropertyValueSingle("NavigationHandler.OrbitalNavigator.Aim", '')
-- openspace.setPropertyValueSingle("NavigationHandler.OrbitalNavigator.Anchor", 'Moon')
-- openspace.setPropertyValueSingle("NavigationHandler.OrbitalNavigator.RetargetAnchor", nil)
-- openspace.globebrowsing.goToGeo(0.6782993, 23.4664611, 2000)
openspace.globebrowsing.addBlendingLayersFromDirectory(vrts, assetGlobe);
flipbook = helper.createFlipbook(assetPrefix, assetGlobe, 19);
function nextFlip()
openspace.printDebug("Goto next flip" .. flipbook.CurrentFlipIndex)
function nextFlip()
helper.nextFlipbookPage(flipbook);
end
end
function previousFlip()
function previousFlip()
helper.previousFlipbookPage(flipbook);
end
openspace.bindKey("RIGHT", "nextFlip()")
openspace.bindKey("LEFT", "previousFlip()")
end
openspace.bindKey("RIGHT", "nextFlip()", "Show the next Apollo 11 flipbook image.", "Next A11 flip", "/Missions/Apollo/11")
openspace.bindKey("LEFT", "previousFlip()","Show the previous Apollo 11 flipbook image.", "Prev A11 flip", "/Missions/Apollo/11")
end)
asset.onDeinitialize(function ()
flipbook = nil;
flipbook = nil;
openspace.clearKey("RIGHT")
openspace.clearKey("LEFT")
end)
end)
@@ -1,11 +1,10 @@
--apollo_lem.asset (hopeful title)
-- This asset exports a function to create an Apollo Command and Service Module (CSM).
-- This asset exports a function to create an Apollo Lunar Excursion Module (LEM).
-- Instead of hard-coding the scene graph node parent,
-- client assets can decide which object that the CSM should be attached to.
-- Usage example: registerCsm(asset, Apollo8.Idenfitier)
-- ...where Apollo8 is the scene graph node identifier to attach the CSM to.
-- client assets can decide which object that the LEM should be attached to.
-- Usage example: registerLem(asset, Apollo11Lem.Idenfitier)
-- ...where Apollo11Lem is the scene graph node identifier to attach the LEM to.
local assetHelper = asset.require('util/asset_helper')
local sunTransforms = asset.require('scene/solarsystem/sun/transforms')
@@ -0,0 +1,8 @@
local modelFolder = asset.syncedResource({
Name = "Apollo Lem Models",
Type = "HttpSynchronization",
Identifier = "apollo_lem_model",
Version = 2
})
asset.export('modelFolder', modelFolder)