This repository was archived by the owner on Dec 13, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 123
VRageMath.Vector2D
Malware edited this page Jan 26, 2019
·
52 revisions
← Index ← Namespace Index
public struct Vector2D: IEquatable<T>Defines a vector with two components.
Namespace: VRageMath
Assembly: VRage.Math.dll
Implements:
| Member | Description |
|---|---|
| X | Gets or sets the x-component of the vector. |
| Y | Gets or sets the y-component of the vector. |
| Zero | |
| One | |
| UnitX | |
| UnitY | |
| PositiveInfinity |
| Member | Description |
|---|---|
| Item |
| Member | Description |
|---|---|
| Vector2D(double, double) | |
| Vector2D(double) |
| Member | Description |
|---|---|
| ToString() | Retrieves a string representation of the current object. |
| Equals(Vector2D) | Determines whether the specified Object is equal to the Vector2D. |
| Equals(object) | Returns a value that indicates whether the current instance is equal to a specified object. |
| GetHashCode() | Gets the hash code of the vector object. |
| IsValid() | |
| AssertIsValid() | |
| Length() | Calculates the length of the vector. |
| LengthSquared() | Calculates the length of the vector squared. |
| Distance(Vector2D, Vector2D) | Calculates the distance between two vectors. |
| Distance(ref Vector2D, ref Vector2D, out double) | Calculates the distance between two vectors. |
| DistanceSquared(Vector2D, Vector2D) | Calculates the distance between two vectors squared. |
| DistanceSquared(ref Vector2D, ref Vector2D, out double) | Calculates the distance between two vectors squared. |
| Dot(Vector2D, Vector2D) | Calculates the dot product of two vectors. If the two vectors are unit vectors, the dot product returns a doubleing point value between -1 and 1 that can be used to determine some properties of the angle between two vectors. For example, it can show whether the vectors are orthogonal, parallel, or have an acute or obtuse angle between them. |
| Dot(ref Vector2D, ref Vector2D, out double) | Calculates the dot product of two vectors and writes the result to a user-specified variable. If the two vectors are unit vectors, the dot product returns a doubleing point value between -1 and 1 that can be used to determine some properties of the angle between two vectors. For example, it can show whether the vectors are orthogonal, parallel, or have an acute or obtuse angle between them. |
| Normalize() | Turns the current vector into a unit vector. The result is a vector one unit in length pointing in the same direction as the original vector. |
| Normalize(Vector2D) | Creates a unit vector from the specified vector. The result is a vector one unit in length pointing in the same direction as the original vector. |
| Normalize(ref Vector2D, out Vector2D) | Creates a unit vector from the specified vector, writing the result to a user-specified variable. The result is a vector one unit in length pointing in the same direction as the original vector. |
| Reflect(Vector2D, Vector2D) | Determines the reflect vector of the given vector and normal. |
| Reflect(ref Vector2D, ref Vector2D, out Vector2D) | Determines the reflect vector of the given vector and normal. |
| Min(Vector2D, Vector2D) | Returns a vector that contains the lowest value from each matching pair of components. |
| Min(ref Vector2D, ref Vector2D, out Vector2D) | Returns a vector that contains the lowest value from each matching pair of components. |
| Max(Vector2D, Vector2D) | Returns a vector that contains the highest value from each matching pair of components. |
| Max(ref Vector2D, ref Vector2D, out Vector2D) | Returns a vector that contains the highest value from each matching pair of components. |
| Clamp(Vector2D, Vector2D, Vector2D) | Restricts a value to be within a specified range. |
| Clamp(ref Vector2D, ref Vector2D, ref Vector2D, out Vector2D) | Restricts a value to be within a specified range. |
| ClampToSphere(Vector2D, double) | |
| ClampToSphere(ref Vector2D, double) | |
| Lerp(Vector2D, Vector2D, double) | Performs a linear interpolation between two vectors. |
| Lerp(ref Vector2D, ref Vector2D, double, out Vector2D) | Performs a linear interpolation between two vectors. |
| Barycentric(Vector2D, Vector2D, Vector2D, double, double) | Returns a Vector2D containing the 2D Cartesian coordinates of a point specified in barycentric (areal) coordinates relative to a 2D triangle. |
| Barycentric(ref Vector2D, ref Vector2D, ref Vector2D, double, double, out Vector2D) | Returns a Vector2D containing the 2D Cartesian coordinates of a point specified in barycentric (areal) coordinates relative to a 2D triangle. |
| SmoothStep(Vector2D, Vector2D, double) | Interpolates between two values using a cubic equation. |
| SmoothStep(ref Vector2D, ref Vector2D, double, out Vector2D) | Interpolates between two values using a cubic equation. |
| CatmullRom(Vector2D, Vector2D, Vector2D, Vector2D, double) | Performs a Catmull-Rom interpolation using the specified positions. |
| CatmullRom(ref Vector2D, ref Vector2D, ref Vector2D, ref Vector2D, double, out Vector2D) | Performs a Catmull-Rom interpolation using the specified positions. |
| Hermite(Vector2D, Vector2D, Vector2D, Vector2D, double) | Performs a Hermite spline interpolation. |
| Hermite(ref Vector2D, ref Vector2D, ref Vector2D, ref Vector2D, double, out Vector2D) | Performs a Hermite spline interpolation. |
| Transform(Vector2D, Matrix) | Transforms the vector (x, y, 0, 1) by the specified matrix. |
| Transform(ref Vector2D, ref Matrix, out Vector2D) | Transforms a Vector2D by the given Matrix. |
| TransformNormal(Vector2D, Matrix) | Transforms a 2D vector normal by a matrix. |
| TransformNormal(ref Vector2D, ref Matrix, out Vector2D) | Transforms a vector normal by a matrix. |
| Transform(Vector2D, Quaternion) | Transforms a single Vector2D, or the vector normal (x, y, 0, 0), by a specified Quaternion rotation. |
| Transform(ref Vector2D, ref Quaternion, out Vector2D) | Transforms a Vector2D, or the vector normal (x, y, 0, 0), by a specified Quaternion rotation. |
| Transform(Vector2D[], ref Matrix, Vector2D[]) | Transforms an array of Vector2s by a specified Matrix. |
| Transform(Vector2D[], int, ref Matrix, Vector2D[], int, int) | Transforms a specified range in an array of Vector2s by a specified Matrix and places the results in a specified range in a destination array. |
| TransformNormal(Vector2D[], ref Matrix, Vector2D[]) | Transforms an array of Vector2D vector normals by a specified Matrix. |
| TransformNormal(Vector2D[], int, ref Matrix, Vector2D[], int, int) | Transforms a specified range in an array of Vector2D vector normals by a specified Matrix and places the results in a specified range in a destination array. |
| Transform(Vector2D[], ref Quaternion, Vector2D[]) | Transforms an array of Vector2s by a specified Quaternion. |
| Transform(Vector2D[], int, ref Quaternion, Vector2D[], int, int) | Transforms a specified range in an array of Vector2s by a specified Quaternion and places the results in a specified range in a destination array. |
| Negate(Vector2D) | Returns a vector pointing in the opposite direction. |
| Negate(ref Vector2D, out Vector2D) | Returns a vector pointing in the opposite direction. |
| Add(Vector2D, Vector2D) | Adds two vectors. |
| Add(ref Vector2D, ref Vector2D, out Vector2D) | Adds two vectors. |
| Subtract(Vector2D, Vector2D) | Subtracts a vector from a vector. |
| Subtract(ref Vector2D, ref Vector2D, out Vector2D) | Subtracts a vector from a vector. |
| Multiply(Vector2D, Vector2D) | Multiplies the components of two vectors by each other. |
| Multiply(ref Vector2D, ref Vector2D, out Vector2D) | Multiplies the components of two vectors by each other. |
| Multiply(Vector2D, double) | Multiplies a vector by a scalar value. |
| Multiply(ref Vector2D, double, out Vector2D) | Multiplies a vector by a scalar value. |
| Divide(Vector2D, Vector2D) | Divides the components of a vector by the components of another vector. |
| Divide(ref Vector2D, ref Vector2D, out Vector2D) | Divides the components of a vector by the components of another vector. |
| Divide(Vector2D, double) | Divides a vector by a scalar value. |
| Divide(ref Vector2D, double, out Vector2D) | Divides a vector by a scalar value. |
| Between(ref Vector2D, ref Vector2D) | |
| Floor(Vector2D) | |
| Rotate(double) |
Do you have questions, comments, suggestions for improvements? Is there something I can do better? Did I make a mistake? Please add an issue here, and prefix your issue title with Wiki. Thank you, your help will be very appreciated!