StaticTranslation

Inherits Translation

Members

Name

Documentation

Type

Description

Optional

Position

This value is used as a static offset (in meters) that is applied to the scene graph node that this transformation is attached to relative to its parent

Vector3<double>

Value of type ‘Vector3

No

Inherited members from Translation

Name

Documentation

Type

Description

Optional

Type

The type of translation that is described in this element. The available types of translations depend on the configuration of the application and can be written to disk on application startup into the FactoryDocumentation

String

Must name a valid Translation type

No

Asset Examples

 1-- To learn how you can include your own video, see the wiki
 2-- http://wiki.openspaceproject.com/docs/builders/assets/resources.html
 3
 4local transforms = asset.require("scene/solarsystem/planets/earth/transforms")
 5
 6
 7
 8local Plane = {
 9  Identifier = "VideoPlaneExample",
10  Parent = transforms.EarthCenter.Identifier,
11  Transform = {
12    Translation = {
13      Type = "StaticTranslation",
14      Position = { 0.0, -11E7, 0.0 }
15    }
16  },
17  Renderable = {
18    Type = "RenderableVideoPlane",
19    MirrorBackside = true,
20    Size = 3E7,
21    Video = asset.resource("examplevideo.mp4"),
22  },
23  GUI = {
24    Name = "Video Plane Example",
25    Path = "/Other/Planes"
26  }
27}
28
29
30asset.onInitialize(function()
31  openspace.addSceneGraphNode(Plane)
32end)
33
34asset.onDeinitialize(function()
35  openspace.removeSceneGraphNode(Plane)
36end)
37
38asset.export(Plane)
39
40
41
42asset.meta = {
43  Name = "Video Plane Example",
44  Version = "1.0",
45  Description = "An example asset that shows how to include a video on a plane.",
46  Author = "OpenSpace Team",
47  URL = "https://openspaceproject.com",
48  License = "MIT"
49}