gis-tools-ts
Version:
A collection of geospatial tools primarily designed for WGS84, Web Mercator, and S2.
96 lines • 4.14 kB
TypeScript
/** Constants for insphere */
export interface InSphereConstants {
ab: Float64Array;
bc: Float64Array;
cd: Float64Array;
de: Float64Array;
ea: Float64Array;
ac: Float64Array;
bd: Float64Array;
ce: Float64Array;
da: Float64Array;
eb: Float64Array;
abc: Float64Array;
bcd: Float64Array;
cde: Float64Array;
dea: Float64Array;
eab: Float64Array;
abd: Float64Array;
bce: Float64Array;
cda: Float64Array;
deb: Float64Array;
eac: Float64Array;
adet: Float64Array;
bdet: Float64Array;
cdet: Float64Array;
ddet: Float64Array;
edet: Float64Array;
abdet: Float64Array;
cddet: Float64Array;
cdedet: Float64Array;
deter: Float64Array;
_8: Float64Array;
_8b: Float64Array;
_8c: Float64Array;
_16: Float64Array;
_24: Float64Array;
_48: Float64Array;
_48b: Float64Array;
_96: Float64Array;
_192: Float64Array;
_384x: Float64Array;
_384y: Float64Array;
_384z: Float64Array;
_768: Float64Array;
xdet: Float64Array;
ydet: Float64Array;
zdet: Float64Array;
fin: Float64Array;
}
/**
* Get the orientation of a tetrahedron querying against a sphere
* @param ax - x coordinate of first point
* @param ay - y coordinate of first point
* @param az - z coordinate of first point
* @param bx - x coordinate of second point
* @param by - y coordinate of second point
* @param bz - z coordinate of second point
* @param cx - x coordinate of origin point to create the abcd plane
* @param cy - y coordinate of origin point to create the abcd plane
* @param cz - z coordinate of origin point to create the abcd plane
* @param dx - x coordinate of second origin point to create the abcd plane
* @param dy - y coordinate of second origin point to create the abcd plane
* @param dz - z coordinate of second origin point to create the abcd plane
* @param ex - x coordinate of compare point
* @param ey - y coordinate of compare point
* @param ez - z coordinate of compare point
* @returns - a positive value if the point-plane of a-b-c-d via e occur in counterclockwise order
* (d lies to the left of the directed line defined by points a and b).
* - Returns a negative value if they occur in clockwise order (d lies to the right of the directed line ab).
* - Returns zero if they are collinear.
*/
export declare function insphere(ax: number, ay: number, az: number, bx: number, by: number, bz: number, cx: number, cy: number, cz: number, dx: number, dy: number, dz: number, ex: number, ey: number, ez: number): number;
/**
* Get the orientation of a tetrahedron using a fast method that uses the volume of the tetrahedron
* @param pax - x coordinate of first point
* @param pay - y coordinate of first point
* @param paz - z coordinate of first point
* @param pbx - x coordinate of second point
* @param pby - y coordinate of second point
* @param pbz - z coordinate of second point
* @param pcx - x coordinate of origin point to create the abcd plane
* @param pcy - y coordinate of origin point to create the abcd plane
* @param pcz - z coordinate of origin point to create the abcd plane
* @param pdx - x coordinate of second origin point to create the abcd plane
* @param pdy - y coordinate of second origin point to create the abcd plane
* @param pdz - z coordinate of second origin point to create the abcd plane
* @param pex - x coordinate of compare point
* @param pey - y coordinate of compare point
* @param pez - z coordinate of compare point
* @returns - a positive value if the point-plane of a-b-c via d occur in counterclockwise order
* (c lies to the left of the directed line defined by points a and b).
* - Returns a negative value if they occur in clockwise order (c lies to the right of the directed line ab).
* - Returns zero if they are collinear.
*/
export declare function inspherefast(pax: number, pay: number, paz: number, pbx: number, pby: number, pbz: number, pcx: number, pcy: number, pcz: number, pdx: number, pdy: number, pdz: number, pex: number, pey: number, pez: number): number;
//# sourceMappingURL=insphere.d.ts.map