Components in Detail

Since Orbis Terrains are configured using multiple individual components, all components that are part of the asset are being documented here.

Predefined Terrain Components

The predefined Terrain components are (optionally) added to the terrain beforehand to set configuration options.

NodeSettings

The mesh generation settings for each terrain chunk. Increasing the Vertex Count properties increases the total resolution of the terrain. When genereate Skirts is enabled, a skirt around each chunk will be added, which can prevent visible seams between chunks, but increases the triangle count by a bit. The Vertex Count property should always be a multiple of 2 + 1 (e.g. 17, 33, 65, etc.). VertexDistances controls how far each vertex is placed away from the last one. VertexCount * VertexDistances is the total size of the terrain chunk. Note that with each increase in LOD level, the VertexDistances property is halfed, while all other properties remain the same.

QuadtreeSettings

Settings that are shared across the entire quadtree/terrain instance.

MaxLOD controls the maximum lod level that the terrain will go to. Witheach lod level the terrain is subdivided into 4 sub-chunks.

CollisionLOD defines which LOD mesh level is being used as collision mesh. Setting it to "-1" effectivly disabled the collision mesh.

The ID field is a reference to the modification map of the terrain, in most usecases a unique ID per terrain should be used.

LODDistanceMultiplier is a multiplier to the Lod Distances defined in the OrbisConfigurator to make this terrain instance change LOD fast/slower.

SphericalPlanetConfiguration

Sets the terrain to be part of a spherical planet. All 6 sides of the spherical terrain should use the same SphericalPlanetConfiguration. SphericalCenter sets the world-space center of the sphere, and PlanetRadius sets the radius of the planet. The MaxHeight property defined the max height of the terrain surface, and should be the same height as defined in HeightmapSettings scale field or in ProceduralHeightGeneratorSettings scale. This is required to calculate the visible chunks of a planet and skip rendering occluded sides of the sphere.

BiomeSettings

Can be optionally set to override the default biome mapping options. BiomeFalloff is used to make the edges between biomes more precise or smooth (higher values result in sharper edges). You can also offset the biome values by multiplied it with BiomeOffset. The BiomePeakRange and CliffAngleMultipler are only used when the MicroSplatVertexEncoding parameter is set. This changes the way biome data is written (instead of just simply using the “red” vertex channel). The biome data, cliff strength and peak snow data will all be packed into one channel and written to the vertex data. You can then use the Mesh Workflow of Microsplat using the “Vertex Mode”, with up to for textures (one for each biome type, one for cliffs and one for mountain tops). BiomePeakRange describes the starting and ending heights which are used for MicroSplat mountain top textures.

HeightmapSettings

Assigns a heightmap to be used for this terrain. HeightMapID is the ID of the heightmap, as assigned along the heightmap and biomemap in OrbisConfigurator. HeightScale sets the maximum height of the terrain. Either a HeightmapSettings or a ProceduralHeightGeneratorSettings component is required on a terrain to function.

ProceduralHeightGeneratorSettings

Sets the terrain to use procedurally generated height and biomes, with a generator defined by GeneratorID. The Scale property sets the height of the terrain, and Frequency the size of horizontal scale of the terrain.

HeightmapScatterSettings

Used to scatter multiple heightmaps on the terrain. They are repeated in random order mutliple times, and are overlapping and blended with each other repeatedly. This allows to create many unique combinations of heightmaps, and give large terrains detailed even when close to it, without requiring multiple high-res heightmaps. StackID defines the stack of heightmaps that has been defined in the OrbisConfigurator. Different terrains can use different heightmap stack while being in the same scene, using different heightmap stacks. Frequence defines the size of each heightmap on the terrain, higher values result in the heightmaps being scattered closer together. Scale sets the maximum height of the terrain. Please note that HeightmapScatterSettings, ProceduralHeightGeneratorSettings and HeightmapSettings are exclusive to each other, only one kind of generation method can be used for each terrain.

MaterialReference

Used by the rendering system to pick up the correct material for the terrain. The Value field is the material used to render the terrain. Is a shared component.

VegetationSettings

All foliage spawning rules are defined for each terrain at the “top-level” entity, and are not passed to children. All children terrain nodes instead reference the vegetation settings stored in this buffer of the root terrain node.

Runtime Terrain Components

The runtime Terrain components are added, removed or modified during runtime, to signal different states/properties of the terrain entites, and allow different systems to pick them up.

VegetationBuffer

A buffer component that contains all the foliage instances that have been spawned on/for this terrain entity.

RemoveRenderMeshTag

Signals that the entity no longer needs to be rendered, and the stored mesh can be removed. Assigned when a mesh is split up into four child quads.

NeedsGeneratedGridTag

Signals that a mesh for a terrain chunk needs to be generated.

HasVegetationTag

Tag that defines that a terrain chunk has vegetation on it.

DeleteQuadtreeNodeTag

Indicates that the quadtree node / terrain chunk needs to be deleted. Used when lowered the LOD level, and the child chunks are no longer needed.

FadingOutMeshTag

Used on transition meshes during lod switches.

HasMeshTag

Indicates that the chunk has a generated mesh, and needs to be rendered.

QuadtreeChildren

Stores a reference to the child nodes of a terrain chunk that has been split up.

QuadtreeLODNode

Stores the extends of the current lod level, and the uv positions to identify the node’s position relative the the root chunk.

QuadtreeLODLevel

Stores the current LOD level of a chunk.

NodeBounds

Stores the bounds of the chunk, as an AABB in local-space.

Other Components

The other components added by Orbis that are never directly added to the terrain.

CollisionInvokerTag

Used to force the nearby terrain to become more details and reach the collision LOD level. For more details, refer to collision invoker details

GravityCenter

Allows to simulate a planet’s gravity in the DOTS Physics world. Every physics body that is within range will be affected by the gravity center. RangeMax defines the maximum range at which bodies will be affected. The gravity intensity will gradually fall of between RangeMin and RangeMax. The maximum gravity strength, which well be applied to all bodies closer than RangeMin is defined by the strength property.

OrbisConfigurator

The OrbisConfigurator component is the central interface for Orbis to set properties that have will not be directly attached to entities, but rather stay on the MonoBehavior to make editor configuration easier. The different Orbis systems will load their configuration from this component at the begin. This means that modifying parameters at runtime will not work.

There should only be GameObject with a OrbisConfigurator component, any more than that and there’ll most likely be errors. When starting, the component wil convert heightmaps and all other inputs into internal formats. Since reading large heightmaps can take a bit, this is done in a Job without blocking the main thread. To check if the system is ready, and Orbis terrain can start being generated, there is a public static property available:

public static bool initializationDone;

Public Fields

Heightmap Inputs: A list of heightmap textures to be used by the terrain. This list is updated by the Orbis Bakers, so in most cases you don’t need to modify this. There can be only one heightmap per terrain, and the heightmap for a terrain is identified by the ID field of the HeightmapSettings component. Heightmaps needs to be set to single channel, channel red, read-write enabled, and format has to be set to R 16 bit.

Heightmap Stacks: A List of heightmap stacks used in the scattered heightmap mode. This list is updated by the Orbis Bakers, so in most cases you don’t need to modify this.. Each stack is identified by a unique StackID, and contains a list of IDs. Each ID represents a heightmap as defined in Heightmap Inputs, with the identifier being the assigned ID of the heightmap. A heightmap should only be used once per stack, but multiple stacks can contain the same heightmap.

LOD Distances: The distances at which a terrain chunk is subdivided. This is interpreted as a map, where the id is the current LOD level of a terrain node, and the distance is the distance between the camera and the closest point to the camera on the node’s bounds.

Floating Origin Reposition Range: The range the camera can move away from the world centre (0 0 0) before the world is being shifted and the camera is moved back to zero. All the entities that have a FloatingOriginRepositionTag are moved along, and the moved distance will be written to the component

Rendering Layer is the rendering Layer in which all terrains will be rendered

Maximum Job Lifetime describes the maximum amount of frames a job is allowed to run in the background before being forced to finish. Settings this to 4 in the editor is recommended to avoid having in-editor warnings about jobs taking too long. However, for maximum performance without stalling the main thread, higher values such as 20 or 40 can be used.