Skip to content

buildHexGeometry

buildHexGeometry(cell, hex, sheetWidth, sheetHeight, orientation?): BufferGeometry

Defined in: packages/declarative-hex-worlds/src/three/textured-hex.ts:90

Build a hexagon BufferGeometry in the XZ plane (Y=0), with UVs mapping each corner + center to the given cell rect of a sheet. The hex spans hex.width on X and hex.height on Z.

CellRect

HexDims

number

number

"pointy" | "flat"

BufferGeometry