Sphere

Bounding sphere class.

Constructor

new Sphere(radiusopt, centeropt)

Parameters:
NameTypeAttributesDescription
radiusNumber<optional>

Bounding sphere radius.

centerVec3<optional>

Bounding sphere coordinates.

Methods

setFromBounds(bounds)

Sets bounding sphere coordinates by the bounds array.

Parameters:
NameTypeDescription
boundsArray.<number>

Bounds is an array where [minX, minY, minZ, maxX, maxY, maxZ]

setFromExtent(ellipsoid, extent)

Sets bounding sphere coordinates by ellipsoid geodetic extend.

Parameters:
NameTypeDescription
ellipsoidEllipsoid

Ellipsoid.

extentExtent

Geodetic extent.