RenderableTrailOrbit

Inherits Renderable

Members

Name

Documentation

Type

Description

Optional

Color

This value determines the RGB main color for the lines and points of the trail

Color3

Value of type ‘Color3’

No

Period

The objects period, i.e. the length of its orbit around the parent object given in (Earth) days. In the case of Earth, this would be a sidereal year (=365.242 days). If this values is specified as multiples of the period, it is possible to show the effects of precession

Double

Value of type ‘Double’

No

Resolution

The number of samples along the orbit. This determines the resolution of the trail; the tradeoff being that a higher resolution is able to resolve more detail, but will take more resources while rendering, too. The higher, the smoother the trail, but also more memory will be used

Integer

Value of type ‘Integer’

No

Translation

This object is used to compute locations along the path. Any Translation object can be used here

Table

Translation

No

EnableFade

Toggles whether the trail should fade older points out. If this value is ‘true’, the ‘Fade’ parameter determines the speed of fading. If this value is ‘false’, the entire trail is rendered at full opacity and color

Boolean

Value of type ‘Boolean’

Yes

LineFade

The fading factor that is applied to the trail if the ‘EnableFade’ value is ‘true’. If it is ‘false’, this setting has no effect. The higher the number, the less fading is applied

Double

Value of type ‘Double’

Yes

LineWidth

This value specifies the line width of the trail if the selected rendering method includes lines. If the rendering mode is set to Points, this value is ignored

Double

Value of type ‘Double’

Yes

PointSize

This value specifies the base size of the points along the line if the selected rendering method includes points. If the rendering mode is set the Lines, this value is ignored. If a subsampling of the values is performed, the subsampled values are half this size

Integer

Value of type ‘Integer’

Yes

RenderableType

This value specifies if the orbit should be rendered in the Background,Opaque, Transparent, or Overlay rendering step. Default is Transparent

String

In list { Background, Opaque, PreDeferredTransparent, PostDeferredTransparent, Overlay }

Yes

Rendering

Determines how the trail should be rendered to the screen. If ‘Lines’ is selected, only the line part is visible, if ‘Points’ is selected, only the corresponding points (and subpoints) are shown. ‘Lines+Points’ shows both parts

String

In list { Lines, Points, Lines+Points, Lines+Points }

Yes

Inherited members from Renderable

Name

Documentation

Type

Description

Optional

DimInAtmosphere

Enables/Disables if the object should be dimmed when the camera is in the sunny part of an atmosphere

Boolean

Value of type ‘Boolean’

Yes

Enabled

This setting determines whether this object will be visible or not

Boolean

Value of type ‘Boolean’

Yes

Opacity

This value determines the opacity of this renderable. A value of 0 means completely transparent

Double

In range: ( 0,1 )

Yes

RenderBinMode

This value specifies if the renderable should be rendered in the Background,Opaque, Pre/PostDeferredTransparency, or Overlay rendering step

String

In list { Background, Opaque, PreDeferredTransparent, PostDeferredTransparent, Overlay }

Yes

Tag

A single tag or a list of tags that this renderable will respond to when setting properties

Table, or String

Value of type ‘Table’, or Value of type ‘String’

Yes

Type

This tells the type of the renderable

String

Value of type ‘String’

Yes

Asset Examples

 1local sunTransforms = asset.require("scene/solarsystem/sun/transforms")
 2local transforms = asset.require("./transforms")
 3
 4
 5
 6local Trail = {
 7  Identifier = "ErisTrail",
 8  Parent = sunTransforms.SunEclipJ2000.Identifier,
 9  Renderable = {
10    Type = "RenderableTrailOrbit",
11    Enabled = asset.enabled,
12    Translation = transforms.Translation,
13    Color = { 0.2, 0.8, 0.3 },
14    Period = 205472.1258735657,
15    Resolution = 10000,
16    Fade = 1.24
17  },
18  Tag = { "planetTrail_dwarf" },
19  GUI = {
20    Name = "Eris Trail",
21    Path = "/Solar System/Dwarf Planets/Eris",
22    Description = "Trail of Eris"
23  }
24}
25
26
27asset.onInitialize(function()
28  openspace.addSceneGraphNode(Trail)
29end)
30
31asset.onDeinitialize(function()
32  openspace.removeSceneGraphNode(Trail)
33end)
34
35asset.export("Trail", Trail)
36
37
38
39asset.meta = {
40  Name = "Eris Trail",
41  Version = "1.0",
42  Description = [[Trail of Eris]],
43  Author = "OpenSpace Team",
44  URL = "https://www.openspaceproject.com",
45  License = "MIT"
46}