API Docs for: 0.6.0
Show:

Sphere Class

Extends Shape

Spherical shape

Constructor

Sphere

(
  • radius
)

Parameters:

  • radius Number

Methods

calculateLocalInertia

() Vec3

Inherited from Shape: src/shapes/Shape.js:56

Calculates the inertia in the local frame for this shape.

Returns:

Vec3:

updateBoundingSphereRadius

() Number

Inherited from Shape: src/shapes/Shape.js:38

Computes the bounding sphere radius. The result is stored in the property .boundingSphereRadius

Returns:

Number:

volume

() Number

Inherited from Shape: src/shapes/Shape.js:47

Get the volume of this shape

Returns:

Number:

Properties

boundingSphereRadius

Number

Inherited from Shape: src/shapes/Shape.js:25

The local bounding sphere radius of this shape.

collisionResponse

Boolean

Inherited from Shape: src/shapes/Shape.js:31

radius

Number

type

Number

Inherited from Shape: src/shapes/Shape.js:17

The type of this shape. Must be set to an int > 0 by subclasses.