TemporalTileProvider
Inherits TileProvider
Members
Name |
Documentation |
Type |
Description |
Optional |
---|---|---|---|---|
|
The mode that his temporal tile provider operates in. In the |
|
In list { Prototyped, Folder } |
No |
|
If provided, the tile provider will use this color map to convert a greyscale image to color |
|
Value of type ‘String’ |
Yes |
|
If the ‘UseFixedTime’ is enabled, this time will be used instead of the actual time taken from OpenSpace for the displayed tiles. |
|
Value of type ‘String’ |
Yes |
|
|
Yes |
||
|
Determines whether this tile provider should interpolate between two adjacent layers |
|
Value of type ‘Boolean’ |
Yes |
|
|
Yes |
||
|
If this value is enabled, the time-varying timevarying dataset will always use the time that is specified in the ‘FixedTime’ property, rather than using the actual time from OpenSpace. |
|
Value of type ‘Boolean’ |
Yes |
Table parameters for Folder
Optional: Yes
Name |
Documentation |
Type |
Description |
Optional |
---|---|---|---|---|
|
The folder that is parsed for files. Every file in the provided directory is checked against the provided format and added if it adheres to said format |
|
Value of type ‘Directory’ |
No |
|
The format of files that is pared in the provided folder. The format string has to be compatible to the C++ function get_time. https://en.cppreference.com/w/cpp/io/manip/get_time |
|
Value of type ‘String’ |
No |
Table parameters for Prototyped
Optional: Yes
Name |
Documentation |
Type |
Description |
Optional |
---|---|---|---|---|
|
The text that will be used as the prototype to generate the data to load the image layer. Any occurance of |
|
Value of type ‘String’ |
No |
|
The temporal resolution between each image |
|
Value of type ‘String’ |
No |
|
The starting and ending times for the range of values |
|
No |
|
|
The specification of the date format that is used in the tile provider. The time format must be specified in a manner appropriate for the SPICE function |
|
Value of type ‘String’ |
No |
Table parameters for Time
The starting and ending times for the range of values
Optional: No
Name |
Documentation |
Type |
Description |
Optional |
---|---|---|---|---|
|
The (inclusive) ending time of the temporal image range |
|
Value of type ‘String’ |
No |
|
The (inclusive) starting time of the temporal image range |
|
Value of type ‘String’ |
No |
Asset Examples
1local globe = asset.require("scene/solarsystem/planets/earth/earth")
2
3
4
5local path = asset.resource({
6 Name = "Earth Textures Climate",
7 Type = "HttpSynchronization",
8 Identifier = "earth_textures_climate",
9 Version = 1
10})
11
12
13local LayerPrototype = {
14 Identifier = "ERA5_Land_HighRes_Monthly_2M_Temperature_Temporal_prototype",
15 Name = "ERA5 Land HighRes Monthly 2M Temperature (Temporal) [Prototype]",
16 Type = "TemporalTileProvider",
17 Mode = "Prototyped",
18 Prototyped = {
19 Time = {
20 Start = "1981-01-01",
21 End = "1990-10-01"
22 },
23 TemporalResolution = "1M",
24 TimeFormat = "YYYY-MM-DD",
25 Prototype = path .. "${OpenSpaceTimeId}-land.png"
26 },
27 Interpolation = true,
28 Colormap = path .. "rainbow.png",
29 Description = "Temporal coverage: 01 Jan 1981 - 31 Dec 2020"
30}
31
32local LayerFolder = {
33 Identifier = "ERA5_Land_HighRes_Monthly_2M_Temperature_Temporal_folder",
34 Name = "ERA5 Land HighRes Monthly 2M Temperature (Temporal) [Folder]",
35 Type = "TemporalTileProvider",
36 Mode = "Folder",
37 Folder = {
38 Folder = path,
39 Format = "%Y-%m-%d-land.png"
40 },
41 Interpolation = true,
42 Colormap = path .. "rainbow.png",
43 Description = "Temporal coverage: 01 Jan 1981 - 31 Dec 2020"
44}
45
46
47asset.onInitialize(function()
48 openspace.globebrowsing.addLayer(globe.Earth.Identifier, "ColorLayers", LayerPrototype)
49 openspace.globebrowsing.addLayer(globe.Earth.Identifier, "ColorLayers", LayerFolder)
50end)
51
52asset.onDeinitialize(function()
53 openspace.globebrowsing.deleteLayer(globe.Earth.Identifier, "ColorLayers", LayerFolder)
54 openspace.globebrowsing.deleteLayer(globe.Earth.Identifier, "ColorLayers", LayerPrototype)
55end)
56
57asset.export("Prototype", LayerPrototype)
58asset.export("Folder", LayerFolder)
59
60
61
62asset.meta = {
63 Name = "Climate Earth Layers",
64 Description = "ERA5 data",
65 Author = "OpenSpace Team",
66 URL = "http://openspaceproject.com",
67 License = "MIT license"
68}