Logo Mibo

Stack Module

How a stack of layers stands in height. A layer that draws above another needs the height the layers below it reach at each cell, so its columns stand on them instead of replacing them.

Functions and values

Function or value Description

feet occupancies grids heightOf

Full Usage: feet occupancies grids heightOf

Parameters:
Returns: float32[][]
Type parameters: 'T

For each layer, the height the layers below it reach at each cell, flat at `x + y * Width`. Layer 0 stands on the plane, so its array is all zeroes. `occupancies` and `grids` describe the same layers, bottom first, and a spanning anchor contributes its height over its whole rectangle. Heights add, because every layer is a slab of its own. `let feet = Stack.feet occupancies grids heightOf` then `{ cell with Lift = feet[i].[x + y * width] }` per layer.

occupancies : Occupancy[]
grids : CellGrid2D<'T>[]
heightOf : 'T -> float32
Returns: float32[][]

Type something to start searching.