Converts an array of GeoTriangles back to a BufferGeometry.
Array of GeoTriangle objects
The geographic origin for coordinate conversion
A Three.js BufferGeometry
Error if triangles array is empty
import { geoTrianglesToBufferGeometry } from '@wendylabsinc/react-three-map/maplibre';const json = await fetchFromDatabase();const triangles = JSON.parse(json);const geometry = geoTrianglesToBufferGeometry(triangles, origin); Copy
import { geoTrianglesToBufferGeometry } from '@wendylabsinc/react-three-map/maplibre';const json = await fetchFromDatabase();const triangles = JSON.parse(json);const geometry = geoTrianglesToBufferGeometry(triangles, origin);
Converts an array of GeoTriangles back to a BufferGeometry.