Class: HeightmapGeometry

HeightmapGeometry(webglContext, heightmapImageData, optionsopt)

Heightmap geometry on the XZ plane with Y up.

Constructor

new HeightmapGeometry(webglContext, heightmapImageData, optionsopt)

Parameters:
Name Type Attributes Default Description
webglContext WebGL2RenderingContext WebGL2 rendering context.
heightmapImageData ImageData | HeightmapSource Heightmap image data (grayscale) or a wrapped source.
options HeightmapGeometryOptions <optional>
{} Geometry options.
Source:

Classes

HeightmapGeometry

Members

isWireframe

Returns the wireframe hint value from construction options.
Source:

(static) Sampling

Heightmap sampling modes.
Source:

Methods

(async, static) loadFromUrl(webglContext, url, optionsopt) → {Promise.<HeightmapGeometry>}

Loads heightmap image data from a URL and returns a new `HeightmapGeometry`.
Parameters:
Name Type Attributes Default Description
webglContext WebGL2RenderingContext WebGL2 rendering context.
url string Image URL (relative or absolute).
options HeightmapGeometryOptions <optional>
{} Geometry options.
Source:
Returns:
- Promise, that resolves with created geometry.
Type
Promise.<HeightmapGeometry>