@itwin/core-common
Version:
iTwin.js components common to frontend and backend
28 lines • 1.48 kB
TypeScript
/** @packageDocumentation
* @module Geometry
*/
import { Point3d, Transform } from "@itwin/core-geometry";
/** Describes a spherical volume of space as an approximation of the shape of some more complex geometric entity fully contained within that volume.
* When performing tests for intersection or containment, the approximation can be used as a first, quick check.
* @see [[FrustumPlanes.computeContainment]], for example.
* @public
*/
export declare class BoundingSphere {
/** The point at the center of the sphere. */
center: Point3d;
/** The radius of the sphere. */
radius: number;
/** Create a new bounding sphere with the specified center and radius. */
constructor(center?: Point3d, radius?: number);
/** Change the center and radius of the sphere. */
init(center: Point3d, radius: number): void;
/** Applies the specified transformation matrix to produce a new bounding sphere.
* @param transform The transformation matrix to apply.
* @param result An optional preallocated object to hold the result, to avoid allocating a new object. May be the same object as `this`.
* @returns A bounding sphere equivalent to `this` with the specified transform applied.
*/
transformBy(transform: Transform, result?: BoundingSphere): BoundingSphere;
/** Apply the specified transform to this bounding sphere. */
transformInPlace(transform: Transform): void;
}
//# sourceMappingURL=BoundingSphere.d.ts.map