RenderableConstellationLines
Inherits Renderable
Members
Name |
Documentation |
Type |
Description |
Optional |
---|---|---|---|---|
|
The path to the SPECK file that contains constellation lines data |
|
Value of type ‘File’ |
No |
|
The defined colors for the constellations to be rendered. There can be several groups of constellaitons that can have distinct colors. |
|
Yes |
|
|
The distance unit used for the constellation lines data |
|
In list { m, Km, pc, Kpc, Mpc, Gpc, Gly } |
Yes |
Inherited members from Renderable
Name |
Documentation |
Type |
Description |
Optional |
---|---|---|---|---|
|
Enables/Disables if the object should be dimmed when the camera is in the sunny part of an atmosphere |
|
Value of type ‘Boolean’ |
Yes |
|
This setting determines whether this object will be visible or not |
|
Value of type ‘Boolean’ |
Yes |
|
This value determines the opacity of this renderable. A value of 0 means completely transparent |
|
In range: ( 0,1 ) |
Yes |
|
This value specifies if the renderable should be rendered in the Background,Opaque, Pre/PostDeferredTransparency, or Overlay rendering step |
|
In list { Background, Opaque, PreDeferredTransparent, PostDeferredTransparent, Overlay } |
Yes |
|
A single tag or a list of tags that this renderable will respond to when setting properties |
|
Value of type ‘Table’, or Value of type ‘String’ |
Yes |
|
This tells the type of the renderable |
|
Value of type ‘String’ |
Yes |
Table parameters for Colors
The defined colors for the constellations to be rendered. There can be several groups of constellaitons that can have distinct colors.
Optional: Yes
Name |
Documentation |
Type |
Description |
Optional |
---|---|---|---|---|
|
|
Value of type ‘Vector3 |
Yes |
Asset Examples
1local speck = asset.resource({
2 Name = "Big Dipper Constellation Files",
3 Type = "HttpSynchronization",
4 Identifier = "digitaluniverse_constellations_bigdipper",
5 Version = 1
6})
7
8
9local BigDipper = {
10 Identifier = "BigDipperConstellation",
11 Renderable = {
12 Type = "RenderableConstellationLines",
13 Enabled = false,
14 Labels = {
15 File = speck .. "bigdipper.label",
16 Opacity = 0.3,
17 Color = { 0.8, 0.8, 0.8 },
18 Size = 14.5,
19 MinMaxSize = { 8, 170 },
20 Unit = "pc"
21 },
22 Opacity = 0.3,
23 File = speck .. "bigdipper.speck",
24 NamesFile = speck .. "bigdipper.dat",
25 Colors = { { 0.6, 0.4, 0.4 }, { 0.8, 0.0, 0.0 }, { 0.0, 0.3, 0.8 } },
26 Unit = "pc",
27 DimInAtmosphere = true
28 },
29 Tag = { "daytime_hidden" },
30 GUI = {
31 Name = "Big Dipper",
32 Path = "/Milky Way/Constellations",
33 Description = [[This item only draws the big dipper, and not the rest of the
34 lines of the Ursa Major constellation.]]
35 }
36}
37
38
39asset.onInitialize(function()
40 openspace.addSceneGraphNode(BigDipper)
41end)
42
43asset.onDeinitialize(function()
44 openspace.removeSceneGraphNode(BigDipper)
45end)
46
47asset.export(BigDipper)
48
49
50
51asset.meta = {
52 Name = "Big Dipper",
53 Version = "1.0",
54 Description = "Constellation lines for the Big Dipper",
55 Author = "OpenSpace Team",
56 URL = "https://www.openspaceproject.com",
57 License = "MIT"
58}