voxelkloudBack to the project

DOCS / PACKAGE GUIDE

@voxelkloud/core
Neutral vocabulary and octree math

Use core when you need the shared data model or the tree math without a loader or renderer attached.

npm install @voxelkloud/corepublic

What it owns

Source, tree, node, bounds, attributes, CRS, and the octree math that every other package speaks.

  • PointCloudSourceBase and PointCloudTreeBase define the neutral contracts.
  • Bounding boxes and Morton helpers stay here so loaders and renderers do not duplicate them.
  • Use it when you need to inspect or transform cloud metadata without opening points.

Typical use

Pull the math you need, keep the data model at the edge of your app, and let the loader or renderer build on top of it.

import { childBoundingBox, mortonEncode3 } from '@voxelkloud/core'

const root = { min: [0, 0, 0], max: [512, 512, 512] }
const child = childBoundingBox(root, 6)
const key = mortonEncode3(3, 5, 2)

Related guides