C# Класс Axiom.Math.Sphere

A standard sphere, used mostly for bounds checking.
A sphere in math texts is normally represented by the function x^2 + y^2 + z^2 = r^2 (for sphere's centered on the origin). We store spheres simply as a center point and a radius.
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
Equals ( object obj ) : bool
GetHashCode ( ) : int
Intersects ( AxisAlignedBox box ) : bool

Returns whether or not this sphere interects a box.

Intersects ( Plane plane ) : bool

Returns whether or not this sphere interects a plane.

Intersects ( Sphere sphere ) : bool

Tests for intersection between this sphere and another sphere.

Intersects ( Vector3 vector ) : bool

Returns whether or not this sphere interects a Vector3.

Sphere ( ) : System

Creates a unit sphere centered at the origin.

Sphere ( Vector3 center, Real radius ) : System

Creates an arbitrary spehere.

operator ( ) : bool

Описание методов

Equals() публичный Метод

public Equals ( object obj ) : bool
obj object
Результат bool

GetHashCode() публичный Метод

public GetHashCode ( ) : int
Результат int

Intersects() публичный Метод

Returns whether or not this sphere interects a box.
public Intersects ( AxisAlignedBox box ) : bool
box AxisAlignedBox
Результат bool

Intersects() публичный Метод

Returns whether or not this sphere interects a plane.
public Intersects ( Plane plane ) : bool
plane Plane
Результат bool

Intersects() публичный Метод

Tests for intersection between this sphere and another sphere.
public Intersects ( Sphere sphere ) : bool
sphere Sphere Other sphere.
Результат bool

Intersects() публичный Метод

Returns whether or not this sphere interects a Vector3.
public Intersects ( Vector3 vector ) : bool
vector Vector3
Результат bool

Sphere() публичный Метод

Creates a unit sphere centered at the origin.
public Sphere ( ) : System
Результат System

Sphere() публичный Метод

Creates an arbitrary spehere.
public Sphere ( Vector3 center, Real radius ) : System
center Vector3 Center point of the sphere.
radius Real Radius of the sphere.
Результат System

operator() публичный статический Метод

public static operator ( ) : bool
Результат bool