NOTICE: Google Maps Platform gaming services is deprecated as of October 18, 2021. Current users will have continued access until December 31, 2022. During this time, we will continue to provide support and fixes to major bugs and outages. See the Gaming Services Transition Guide for resources to help you plan the next steps for your projects.
Stay organized with collections Save and categorize content based on your preferences.

Google.Maps.Terrain.TerrainStyle.Builder

The TerrainStyle builder.

Summary

Inheritance

Inherits from: Google.Maps.GameObjectStyle.GameObjectStyleBuilder

Constructors and Destructors

Builder()
The Builder class default constructor.
Builder(TerrainStyle style)
A Builder copy constructor that shallow-copies style values into the builder. Use this copy constructor when you want to create a new style object based on an existing TerrainStyle.

Public attributes

AlphaMapResolutionMetersPerPixel
float
The target resolution of the alpha map in meters per pixel, used to draw TerrainLayer masks.
BaseMapDistance
float
The maximum distance at which terrain textures will be displayed at full resolution. Beyond this distance, a lower resolution composite map will be used for efficiency.
BaseMapResolutionMetersPerPixel
float
The target resolution in meters per pixel of the composite texture used on the terrain when viewed from a distance greater than the Basemap distance.
TerrainLayers
List< TerrainLayer >
The TerrainLayers applied to each Terrain tile during styling.
TerrainPaintingLayer
int
The rendering layer used to capture Feature Groups for TerrainPainting. Defaults to layer 10.

Public functions

Build()
Builds a new TerrainStyle object from the values set on the builder.

Public attributes

AlphaMapResolutionMetersPerPixel

float AlphaMapResolutionMetersPerPixel

The target resolution of the alpha map in meters per pixel, used to draw TerrainLayer masks.

The actual resolution of the alpha maps may differ from the provided value. Unity UnityEngine.Terrain tiles must have square alpha maps with a power of two resolution. The MapsUnity SDK will round the provided value to the nearest power of two to meet this requirement.

When used with Mixed Zoom, this value is automatically doubled for each increment the zoom level is lowered.

BaseMapDistance

float BaseMapDistance

The maximum distance at which terrain textures will be displayed at full resolution. Beyond this distance, a lower resolution composite map will be used for efficiency.

BaseMapResolutionMetersPerPixel

float BaseMapResolutionMetersPerPixel

The target resolution in meters per pixel of the composite texture used on the terrain when viewed from a distance greater than the Basemap distance.

The actual resolution of the base map may differ from the provided value. Unity UnityEngine.Terrain tiles must have square base maps with a power of two resolution. The MapsUnity SDK will round the provided value to the nearest power of two to meet this requirement.

When used with Mixed Zoom, this value is automatically doubled for each increment the zoom level is lowered.

TerrainLayers

List< TerrainLayer > TerrainLayers

The TerrainLayers applied to each Terrain tile during styling.

TerrainPaintingLayer

int TerrainPaintingLayer

The rendering layer used to capture Feature Groups for TerrainPainting. Defaults to layer 10.

To prevent feature group rendering from being visible in-game, please exclude this layer from the culling masks of any other cameras in the scene.

Public functions

Build

TerrainStyle Build()

Builds a new TerrainStyle object from the values set on the builder.

Builder

 Builder()

The Builder class default constructor.

Builder

 Builder(
  TerrainStyle style
)

A Builder copy constructor that shallow-copies style values into the builder. Use this copy constructor when you want to create a new style object based on an existing TerrainStyle.

Details
Parameters
style
A Style object.