Point4dArray Class

The Point4dArray class contains static methods that act on arrays of 4d points.

Methods

Name Description
constructor(): Point4dArray    
isAlmostEqual(dataA: undefined | Float64Array | Point4d[], dataB: undefined | Float64Array | Point4d[]): boolean Static Test arrays for near equality of all corresponding numeric values, treated as coordinates.  
isCloseToPlane(data: Float64Array | Point4d[], plane: Plane3dByOriginAndUnitNormal, tolerance: number = Geometry.smallMetricDistance): boolean Static return true iff all xyzw points' altitudes are within tolerance of the plane.  
multiplyInPlace(transform: Transform, xyzw: Float64Array): void Static Multiply (and replace) each block of 4 values as a Point4d.  
packPointsAndWeightsToFloat64Array(data: Float64Array | number[] | Point3d[], weights: Float64Array | number[], result?: Float64Array): undefined | Float64Array Static Copy each weighted point and its corresponding weight into a packed buffer.  
packToFloat64Array(data: Point4d[], result?: Float64Array): Float64Array Static Copy 4d points into a packed buffer.  
unpackFloat64ArrayToPointsAndWeights(data: Float64Array, points: Point3d[], weights: number[], pointFormatter: (x: number, y: number, z: number) => any = ...): void Static Unpack packed 4D data to a Point3d array and an array of weights.  
unpackToPoint4dArray(data: Float64Array): Point4d[] Static unpack from ...  

Defined in

Last Updated: 16 April, 2024