Jypeli 4
The simple game programming library
|
A Vector with 4 dimensions. Lisää...
Julkiset jäsenfunktiot | |
Vector4D (Scalar X, Scalar Y, Scalar Z, Scalar W) | |
Creates a New Vector4D Instance on the Stack. | |
Vector4D (Scalar[] vals) | |
Vector4D (Scalar[] vals, int index) | |
Scalar[] | ToArray () |
Copies the elements of the IAdvanceValueType to a new array of Scalar . | |
void | CopyFrom (Scalar[] array, int index) |
Copies all the elements, up to the Length of the IAdvanceValueType, of the specified one-dimensional Array to the IAdvanceValueType. | |
void | CopyTo (Scalar[] array, int index) |
Copies all the elements of the IAdvanceValueType to the specified one-dimensional Array of Scalar. | |
string | ToString (string format) |
turns the object into a string representation of itself with a special format for each Scaler in it. | |
override string | ToString () |
override int | GetHashCode () |
Provides a unique hash code based on the member variables of this class. This should be done because the equality operators (==, !=) have been overriden by this class. The standard implementation is a simple XOR operation between all local member variables. | |
override bool | Equals (object obj) |
Compares this Vector to another object. This should be done because the equality operators (==, !=) have been overriden by this class. | |
bool | Equals (Vector4D other) |
Staattiset julkiset jäsenfunktiot | |
static void | Copy (ref Vector4D vector, Scalar[] destArray) |
static void | Copy (ref Vector4D vector, Scalar[] destArray, int index) |
static void | Copy (Scalar[] sourceArray, out Vector4D result) |
static void | Copy (Scalar[] sourceArray, int index, out Vector4D result) |
static void | Copy (ref Vector3D source, ref Vector4D dest) |
static void | Copy (ref Vector2D source, ref Vector4D dest) |
static Vector4D | Clamp (Vector4D value, Vector4D min, Vector4D max) |
static void | Clamp (ref Vector4D value, ref Vector4D min, ref Vector4D max, out Vector4D result) |
static Vector4D | Lerp (Vector4D left, Vector4D right, Scalar amount) |
static void | Lerp (ref Vector4D left, ref Vector4D right, ref Scalar amount, out Vector4D result) |
static Vector4D | Lerp (Vector4D left, Vector4D right, Vector4D amount) |
static void | Lerp (ref Vector4D left, ref Vector4D right, ref Vector4D amount, out Vector4D result) |
static Scalar | Distance (Vector4D left, Vector4D right) |
static void | Distance (ref Vector4D left, ref Vector4D right, out Scalar result) |
static Scalar | DistanceSq (Vector4D left, Vector4D right) |
static void | DistanceSq (ref Vector4D left, ref Vector4D right, out Scalar result) |
static Vector4D | Add (Vector4D left, Vector4D right) |
Adds 2 Vectors2Ds. | |
static void | Add (ref Vector4D left, ref Vector4D right, out Vector4D result) |
static Vector4D | Add (Vector3D left, Vector4D right) |
static void | Add (ref Vector3D left, ref Vector4D right, out Vector4D result) |
static Vector4D | Add (Vector2D left, Vector4D right) |
static void | Add (ref Vector2D left, ref Vector4D right, out Vector4D result) |
static Vector4D | Add (Vector4D left, Vector3D right) |
static void | Add (ref Vector4D left, ref Vector3D right, out Vector4D result) |
static Vector4D | Add (Vector4D left, Vector2D right) |
static void | Add (ref Vector4D left, ref Vector2D right, out Vector4D result) |
static Vector4D | Subtract (Vector4D left, Vector4D right) |
Subtracts 2 Vector4Ds. | |
static void | Subtract (ref Vector4D left, ref Vector4D right, out Vector4D result) |
static Vector4D | Subtract (Vector3D left, Vector4D right) |
static void | Subtract (ref Vector3D left, ref Vector4D right, out Vector4D result) |
static Vector4D | Subtract (Vector2D left, Vector4D right) |
static void | Subtract (ref Vector2D left, ref Vector4D right, out Vector4D result) |
static Vector4D | Subtract (Vector4D left, Vector3D right) |
static void | Subtract (ref Vector4D left, ref Vector3D right, out Vector4D result) |
static Vector4D | Subtract (Vector4D left, Vector2D right) |
static void | Subtract (ref Vector4D left, ref Vector2D right, out Vector4D result) |
static Vector4D | Multiply (Vector4D source, Scalar scalar) |
Does Scaler Multiplication on a Vector4D. | |
static void | Multiply (ref Vector4D source, ref Scalar scalar, out Vector4D result) |
static Vector4D | Multiply (Scalar scalar, Vector4D source) |
Does Scaler Multiplication on a Vector4D. | |
static void | Multiply (ref Scalar scalar, ref Vector4D source, out Vector4D result) |
static Vector4D | Transform (Matrix4x4 matrix, Vector4D vector) |
static void | Transform (ref Matrix4x4 matrix, ref Vector4D vector, out Vector4D result) |
static Vector4D | Transform (Vector4D vector, Matrix4x4 matrix) |
static void | Transform (ref Vector4D vector, ref Matrix4x4 matrix, out Vector4D result) |
static Scalar | Dot (Vector4D left, Vector4D right) |
Does a Dot Operation Also know as an Inner Product. | |
static void | Dot (ref Vector4D left, ref Vector4D right, out Scalar result) |
static Scalar | GetMagnitudeSq (Vector4D source) |
Gets the Squared Magnitude of the Vector4D that is passed. | |
static void | GetMagnitudeSq (ref Vector4D source, out Scalar result) |
static Scalar | GetMagnitude (Vector4D source) |
Gets the Magnitude of the Vector4D that is passed. | |
static void | GetMagnitude (ref Vector4D source, out Scalar result) |
static Vector4D | SetMagnitude (Vector4D source, Scalar magnitude) |
Sets the Magnitude of a Vector4D. | |
static void | SetMagnitude (ref Vector4D source, ref Scalar magnitude, out Vector4D result) |
static Vector4D | Negate (Vector4D source) |
Negates a Vector4D. | |
static void | Negate (ref Vector4D source) |
static void | Negate (ref Vector4D source, out Vector4D result) |
static Vector4D | Normalize (Vector4D source) |
This returns the Normalized Vector4D that is passed. This is also known as a Unit Vector. | |
static void | Normalize (ref Vector4D source, out Vector4D result) |
static void | Normalize (ref Vector4D source) |
static Vector4D | Project (Vector4D left, Vector4D right) |
Thie Projects the left Vector4D onto the Right Vector4D. | |
static void | Project (ref Vector4D left, ref Vector4D right, out Vector4D result) |
static Vector4D | TripleCross (Vector4D top, Vector4D middle, Vector4D bottom) |
static Vector4D | CatmullRom (Vector4D value1, Vector4D value2, Vector4D value3, Vector4D value4, Scalar amount) |
static void | CatmullRom (ref Vector4D value1, ref Vector4D value2, ref Vector4D value3, ref Vector4D value4, Scalar amount, out Vector4D result) |
static Vector4D | Max (Vector4D value1, Vector4D value2) |
static void | Max (ref Vector4D value1, ref Vector4D value2, out Vector4D result) |
static Vector4D | Min (Vector4D value1, Vector4D value2) |
static void | Min (ref Vector4D value1, ref Vector4D value2, out Vector4D result) |
static Vector4D | Hermite (Vector4D value1, Vector4D tangent1, Vector4D value2, Vector4D tangent2, Scalar amount) |
static void | Hermite (ref Vector4D value1, ref Vector4D tangent1, ref Vector4D value2, ref Vector4D tangent2, Scalar amount, out Vector4D result) |
static Vector4D | operator+ (Vector4D left, Vector4D right) |
Adds 2 Vectors2Ds. | |
static Vector4D | operator+ (Vector3D left, Vector4D right) |
static Vector4D | operator+ (Vector2D left, Vector4D right) |
static Vector4D | operator+ (Vector4D left, Vector3D right) |
static Vector4D | operator+ (Vector4D left, Vector2D right) |
static Vector4D | operator- (Vector4D left, Vector4D right) |
Subtracts 2 Vector4Ds. | |
static Vector4D | operator- (Vector3D left, Vector4D right) |
static Vector4D | operator- (Vector2D left, Vector4D right) |
static Vector4D | operator- (Vector4D left, Vector3D right) |
static Vector4D | operator- (Vector4D left, Vector2D right) |
static Vector4D | operator* (Vector4D source, Scalar scalar) |
Does Scaler Multiplication on a Vector4D. | |
static Vector4D | operator* (Scalar scalar, Vector4D source) |
Does Scaler Multiplication on a Vector4D. | |
static Scalar | operator* (Vector4D left, Vector4D right) |
Does a Dot Operation Also know as an Inner Product. | |
static Vector4D | operator* (Matrix4x4 matrix, Vector4D vector) |
static Vector4D | operator* (Vector4D vector, Matrix4x4 matrix) |
static Vector4D | operator- (Vector4D source) |
Negates a Vector4D. | |
static bool | operator== (Vector4D left, Vector4D right) |
Specifies whether the Vector4Ds contain the same coordinates. | |
static bool | operator!= (Vector4D left, Vector4D right) |
Specifies whether the Vector4Ds do not contain the same coordinates. | |
static | operator Vector4D (Vector3D source) |
static bool | TryParse (string s, out Vector4D result) |
static Vector4D | Parse (string s) |
static bool | Equals (Vector4D left, Vector4D right) |
static bool | Equals (ref Vector4D left, ref Vector4D right) |
Julkiset attribuutit | |
const int | Count = 4 |
The number of Scalar values in the class. | |
const int | Size = sizeof(Scalar) * Count |
The Size of the class in bytes;. | |
Scalar | X |
This is the X value. | |
Scalar | Y |
This is the Y value. | |
Scalar | Z |
This is the Z value. | |
Scalar | W |
This is the W value. | |
Staattiset julkiset attribuutit | |
static readonly Vector4D | One = new Vector4D(1, 1, 1, 1) |
Vector4D(1,1,1,1) | |
static readonly Vector4D | Zero = new Vector4D() |
Vector4D(0,0,0,0) | |
static readonly Vector4D | XAxis = new Vector4D(1, 0, 0, 0) |
Vector4D(1,0,0,0) | |
static readonly Vector4D | YAxis = new Vector4D(0, 1, 0, 0) |
Vector4D(0,1,0,0) | |
static readonly Vector4D | ZAxis = new Vector4D(0, 0, 1, 0) |
Vector4D(0,0,1,0) | |
static readonly Vector4D | WAxis = new Vector4D(0, 0, 0, 1) |
Vector4D(0,0,0,1) | |
Ominaisuudet | |
Scalar | Magnitude [get, set] |
Gets or Sets the Magnitude (Length) of the Vector4D. | |
Scalar | MagnitudeSq [get] |
Gets the Squared Magnitude of the Vector4D. | |
Vector4D | Normalized [get] |
Gets the Normalized Vector4D. (Unit Vector) | |
int IAdvanceValueType. | Count [get] |
The Number of Variables accesable though the indexer. |
A Vector with 4 dimensions.
Vector4D | ( | Scalar | X, |
Scalar | Y, | ||
Scalar | Z, | ||
Scalar | W | ||
) | [inline] |
Creates a New Vector4D Instance on the Stack.
X | The X value. |
Y | The Y value. |
Z | The Z value. |
W | The W value. |
void CopyFrom | ( | Scalar[] | array, |
int | index | ||
) | [inline] |
Copies all the elements, up to the Length of the IAdvanceValueType, of the specified one-dimensional Array to the IAdvanceValueType.
array | The one-dimensional Array that is the source of the elements copied to the IAdvanceValueType. |
index | A 32-bit integer that represents the index in array at which copying begins. |
Toteuttaa luokan IAdvanceValueType.
void CopyTo | ( | Scalar[] | array, |
int | index | ||
) | [inline] |
Copies all the elements of the IAdvanceValueType to the specified one-dimensional Array of Scalar.
array | The one-dimensional Array that is the destination of the elements copied from the IAdvanceValueType. |
index | A 32-bit integer that represents the index in array at which copying begins. |
Toteuttaa luokan IAdvanceValueType.
override bool Equals | ( | object | obj | ) | [inline] |
Compares this Vector to another object. This should be done because the equality operators (==, !=) have been overriden by this class.
obj |
override int GetHashCode | ( | ) | [inline] |
Provides a unique hash code based on the member variables of this class. This should be done because the equality operators (==, !=) have been overriden by this class. The standard implementation is a simple XOR operation between all local member variables.
static Scalar GetMagnitude | ( | Vector4D | source | ) | [inline, static] |
static Scalar GetMagnitudeSq | ( | Vector4D | source | ) | [inline, static] |
Scalar [] ToArray | ( | ) | [inline] |
Copies the elements of the IAdvanceValueType to a new array of Scalar .
Toteuttaa luokan IAdvanceValueType.
string ToString | ( | string | format | ) | [inline] |
turns the object into a string representation of itself with a special format for each Scaler in it.
format | the format to be applied to each Scalar |
Toteuttaa luokan IAdvanceValueType.
const int Count = 4 |
The number of Scalar values in the class.
Toteuttaa luokan IAdvanceValueType.
Scalar W |
This is the W value.
Scalar X |
This is the X value.
Scalar Y |
This is the Y value.
Scalar Z |
This is the Z value.
int IAdvanceValueType. Count [get] |
The Number of Variables accesable though the indexer.
Toteuttaa luokan IAdvanceValueType.
Scalar Magnitude [get, set] |
Gets or Sets the Magnitude (Length) of the Vector4D.
Toteuttaa luokan IVector< V >.
Scalar MagnitudeSq [get] |
Gets the Squared Magnitude of the Vector4D.
Toteuttaa luokan IVector< V >.
Vector4D Normalized [get] |
Gets the Normalized Vector4D. (Unit Vector)
Toteuttaa luokan IVector< V >.