Skip to content

Function: projectVolume() ​

ts
function projectVolume(
   volume, 
   surface, 
   options
): ProjectVolumeResult;

Defined in: projectVolume.ts:54

Project a volume along anatomical surface normals, without creating a layer or texture.

Zero is valid. Non-finite/masked/outside samples are omitted from reduction. A linear sample requires every contributor with nonzero weight to be valid; weights are never renormalized. Positions and normals must be anatomical, before inflation or viewer layout transforms. Normals must be finite and nonzero; their orientation is caller-owned.

Inputs are borrowed for this synchronous call and never mutated. Work is O(vertices × steps), with one affine inverse per call, no per-sample allocation and no volume scan. Throws for malformed inputs or results outside finite Float32 range. Arithmetic uses JavaScript doubles; numerical overflow is an error, not a missing-data sentinel.

Parameters ​

volume ​

VolumeDescriptor

surface ​

ProjectionSurface

options ​

ProjectVolumeOptions

Returns ​

ProjectVolumeResult

Released under the MIT License.