MeshGeoReference
Declaration
struct MeshGeoReferenceSummary
Georeference of a mesh download's asset: the geodetic origin its chunk transforms are expressed
relative to, plus the transform into that origin's frame.
Identical on every MeshDownloaderChunk / MeshDownloaderResult of one download, because
it describes the space rather than any single node. A chunk's own geographic position is
obtained by composing this with that chunk's transform — not from anything inside MeshData,
which carries no geographic data at all.
Both the origin and the transform are required: depending on the asset, the altitude offset may
live entirely in referenceAltitude (with trackingToReference carrying no vertical
translation) or entirely in trackingToReference (with referenceAltitude zero). Applying the origin
without the transform is wrong in the general case.
Properties
| Name | Type | Summary |
|---|---|---|
| let mode | MeshGeoReferenceMode | Whether the properties below are valid. Inspect this first. |
| let referenceAltitude | Double | Altitude of that origin, in meters above the WGS84 ellipsoid. |
| let referenceLatitude | Double | WGS84 latitude of the origin trackingToReference maps into, in decimal degrees. |
| let referenceLongitude | Double | WGS84 longitude of that origin, in decimal degrees. |
| let trackingToReference | [Float] | Column-major 4x4 matrix (16 elements) mapping the asset's origin space (the space the chunk transforms are expressed in, not the device's AR tracking space) into meters relative to the reference origin, exactly as delivered by Portal — this implementation does not transpose it or convert it to ARKit axes. The frame is East-Down-North, so +Y is downward. |