• Decompresses a 3D point (position) using a given 4x4 matrix (decompressMatrix). This function applies the matrix transformations to the position to restore the original values.

    Parameters

    • position: Vec3

      The compressed 3D point to be decompressed.

    • decompressMatrix: FloatArrayParam

      A 4x4 matrix used to decompress the position.

    • dest: Vec3 = position

      The destination array to store the decompressed point. Defaults to the input position.

    Returns Vec3

    • The decompressed 3D point stored in dest.
    const compressedPosition = [100, 150, 200];
    const matrix = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1];
    const decompressedPoint = decompressPoint3WithMat4(compressedPosition, matrix);