mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-05-07 20:09:58 -05:00
Add documentation and example for RenderableSphereImageOnline (#3185)
* Add a simple online sphere image example * Add documentation for RenderableSphereImageOnline * Address pull request comments --------- Co-authored-by: Alexander Bock <alexander.bock@liu.se>
This commit is contained in:
+27
@@ -0,0 +1,27 @@
|
||||
-- Basic
|
||||
-- This example will show a sphere that is covered with an image which is retrieved from
|
||||
-- an online URL. The image will be stretched over the entire sphere as an equirectangular
|
||||
-- projection
|
||||
|
||||
local Node = {
|
||||
Identifier = "RenderableSphereImageOnline_Example",
|
||||
Renderable = {
|
||||
Type = "RenderableSphereImageOnline",
|
||||
URL = "http://data.openspaceproject.com/examples/renderableplaneimageonline.jpg",
|
||||
|
||||
-- Parameters from the parent class `RenderableSphere`
|
||||
Segments = 16
|
||||
},
|
||||
GUI = {
|
||||
Name = "Basic",
|
||||
Path = "/Examples/RenderableSphereImageOnline"
|
||||
}
|
||||
}
|
||||
|
||||
asset.onInitialize(function()
|
||||
openspace.addSceneGraphNode(Node)
|
||||
end)
|
||||
|
||||
asset.onDeinitialize(function()
|
||||
openspace.removeSceneGraphNode(Node)
|
||||
end)
|
||||
Reference in New Issue
Block a user