Elevation tiles, encoded as RGB. The input for terrain and hillshade.
<HoloMap.Source.RasterDEM
id="dem"
tiles={["https://tiles.example.com/dem/{z}/{x}/{y}.png"]}
encoding="terrarium"
tile_size={256}
/>
<HoloMap.Terrain source="dem" exaggeration={1.5} />
<HoloMap.Layer.Hillshade id="relief" source="dem" />Encoding
encoding must match how the tiles were produced, and there is no way to
detect it. The wrong value renders a plausible-looking but entirely fictional
landscape.
"mapbox": the Mapbox Terrain-RGB scheme (the default)"terrarium": the Mapzen/AWS Terrain Tiles scheme"custom": supply your ownred_factor,green_factor,blue_factorandbase_shift
Props
| Prop | Type | Notes |
|---|---|---|
id | string | Required. Referenced by HoloMap.Terrain and hillshade layers |
url | string | TileJSON endpoint. Supply this or tiles |
tiles | list | Tile URL templates containing {z}, {x}, {y} |
encoding | string | "mapbox", "terrarium" or "custom" |
tile_size | number | Pixel size of one tile |
min_zoom / max_zoom | number | Zoom range the tiles exist at |
bounds | list | [west, south, east, north] extent of the data |
red_factor / green_factor / blue_factor / base_shift | number | Custom encoding coefficients |
attribution | string | Attribution text |
A change to tiles or url applies in place, with MapLibre's setTiles
and setUrl, and the terrain and hillshade layers drawn from the source
stay on it. Any other change rebuilds the source (see "Updating a source"
in HoloMap.Source).
Summary
Functions
Returns true to indicate that the callee module is a component module (has "use Hologram.Component" directive).
Returns the list of property definitions for the compiled component.
Functions
@spec __is_hologram_component__() :: boolean()
Returns true to indicate that the callee module is a component module (has "use Hologram.Component" directive).
Examples
iex> __is_hologram_component__()
true
Returns the list of property definitions for the compiled component.