Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

Vector3 Structure

.NET Framework (current version)
 

Represents a vector with three single-precision floating-point values.

Namespace:   System.Numerics
Assembly:  System.Numerics (in System.Numerics.dll)

public struct Vector3 : IEquatable<Vector3>, IFormattable

NameDescription
System_CAPS_pubmethodVector3(Single)

Creates a new Vector3 object whose three elements have the same value.

System_CAPS_pubmethodVector3(Single, Single, Single)

Creates a vector whose elements have the specified values.

System_CAPS_pubmethodVector3(Vector2, Single)

Creates a new Vector3 object from the specified Vector2 object and the specified value.

NameDescription
System_CAPS_pubpropertySystem_CAPS_staticOne

Gets a vector whose 3 elements are equal to one.

System_CAPS_pubpropertySystem_CAPS_staticUnitX

Gets the vector (1,0,0).

System_CAPS_pubpropertySystem_CAPS_staticUnitY

Gets the vector (0,1,0).

System_CAPS_pubpropertySystem_CAPS_staticUnitZ

Gets the vector (0,0,1).

System_CAPS_pubpropertySystem_CAPS_staticZero

Gets a vector whose 3 elements are equal to zero.

NameDescription
System_CAPS_pubmethodSystem_CAPS_staticAbs(Vector3)

Returns a vector whose elements are the absolute values of each of the specified vector's elements.

System_CAPS_pubmethodSystem_CAPS_staticAdd(Vector3, Vector3)

Adds two vectors together.

System_CAPS_pubmethodSystem_CAPS_staticClamp(Vector3, Vector3, Vector3)

Restricts a vector between a minimum and a maximum value.

System_CAPS_pubmethodCopyTo(Single[])

Copies the elements of the vector to a specified array.

System_CAPS_pubmethodCopyTo(Single[], Int32)

Copies the elements of the vector to a specified array starting at a specified index position.

System_CAPS_pubmethodSystem_CAPS_staticCross(Vector3, Vector3)

Computes the cross product of two vectors.

System_CAPS_pubmethodSystem_CAPS_staticDistance(Vector3, Vector3)

Computes the Euclidean distance between the two given points.

System_CAPS_pubmethodSystem_CAPS_staticDistanceSquared(Vector3, Vector3)

Returns the Euclidean distance squared between two specified points.

System_CAPS_pubmethodSystem_CAPS_staticDivide(Vector3, Single)

Divides the specified vector by a specified scalar value.

System_CAPS_pubmethodSystem_CAPS_staticDivide(Vector3, Vector3)

Divides the first vector by the second.

System_CAPS_pubmethodSystem_CAPS_staticDot(Vector3, Vector3)

Returns the dot product of two vectors.

System_CAPS_pubmethodEquals(Object)

Returns a value that indicates whether this instance and a specified object are equal.(Overrides ValueType.Equals(Object).)

System_CAPS_pubmethodEquals(Vector3)

Returns a value that indicates whether this instance and another vector are equal.

System_CAPS_pubmethodGetHashCode()

Returns the hash code for this instance. (Overrides ValueType.GetHashCode().)

System_CAPS_pubmethodGetType()

Gets the Type of the current instance.(Inherited from Object.)

System_CAPS_pubmethodLength()

Returns the length of this vector object.

System_CAPS_pubmethodLengthSquared()

Returns the length of the vector squared.

System_CAPS_pubmethodSystem_CAPS_staticLerp(Vector3, Vector3, Single)

Performs a linear interpolation between two vectors based on the given weighting.

System_CAPS_pubmethodSystem_CAPS_staticMax(Vector3, Vector3)

Returns a vector whose elements are the maximum of each of the pairs of elements in two specified vectors.

System_CAPS_pubmethodSystem_CAPS_staticMin(Vector3, Vector3)

Returns a vector whose elements are the minimum of each of the pairs of elements in two specified vectors.

System_CAPS_pubmethodSystem_CAPS_staticMultiply(Single, Vector3)

Multiplies a scalar value by a specified vector.

System_CAPS_pubmethodSystem_CAPS_staticMultiply(Vector3, Single)

Multiplies a vector by a specified scalar.

System_CAPS_pubmethodSystem_CAPS_staticMultiply(Vector3, Vector3)

Multiplies two vectors together.

System_CAPS_pubmethodSystem_CAPS_staticNegate(Vector3)

Negates a specified vector.

System_CAPS_pubmethodSystem_CAPS_staticNormalize(Vector3)

Returns a vector with the same direction as the specified vector, but with a length of one.

System_CAPS_pubmethodSystem_CAPS_staticReflect(Vector3, Vector3)

Returns the reflection of a vector off a surface that has the specified normal.

System_CAPS_pubmethodSystem_CAPS_staticSquareRoot(Vector3)

Returns a vector whose elements are the square root of each of a specified vector's elements.

System_CAPS_pubmethodSystem_CAPS_staticSubtract(Vector3, Vector3)

Subtracts the second vector from the first.

System_CAPS_pubmethodToString()

Returns the string representation of the current instance using default formatting. (Overrides ValueType.ToString().)

System_CAPS_pubmethodToString(String)

Returns the string representation of the current instance using the specified format string to format individual elements.

System_CAPS_pubmethodToString(String, IFormatProvider)

Returns the string representation of the current instance using the specified format string to format individual elements and the specified format provider to define culture-specific formatting.

System_CAPS_pubmethodSystem_CAPS_staticTransform(Vector3, Matrix4x4)

Transforms a vector by a specified 4x4 matrix.

System_CAPS_pubmethodSystem_CAPS_staticTransform(Vector3, Quaternion)

Transforms a vector by the specified Quaternion rotation value.

System_CAPS_pubmethodSystem_CAPS_staticTransformNormal(Vector3, Matrix4x4)

Transforms a vector normal by the given 4x4 matrix.

NameDescription
System_CAPS_pubfieldX

The X component of the vector.

System_CAPS_pubfieldY

The Y component of the vector.

System_CAPS_pubfieldZ

The Z component of the vector.

NameDescription
System_CAPS_puboperatorSystem_CAPS_staticAddition(Vector3, Vector3)

Adds two vectors together.

System_CAPS_puboperatorSystem_CAPS_staticDivision(Vector3, Single)

Divides the specified vector by a specified scalar value.

System_CAPS_puboperatorSystem_CAPS_staticDivision(Vector3, Vector3)

Divides the first vector by the second.

System_CAPS_puboperatorSystem_CAPS_staticEquality(Vector3, Vector3)

Returns a value that indicates whether each pair of elements in two specified vectors is equal.

System_CAPS_puboperatorSystem_CAPS_staticInequality(Vector3, Vector3)

Returns a value that indicates whether two specified vectors are not equal.

System_CAPS_puboperatorSystem_CAPS_staticMultiply(Single, Vector3)

Multiples the scalar value by the specified vector.

System_CAPS_puboperatorSystem_CAPS_staticMultiply(Vector3, Single)

Multiples the specified vector by the specified scalar value.

System_CAPS_puboperatorSystem_CAPS_staticMultiply(Vector3, Vector3)

Multiplies two vectors together.

System_CAPS_puboperatorSystem_CAPS_staticSubtraction(Vector3, Vector3)

Subtracts the second vector from the first.

System_CAPS_puboperatorSystem_CAPS_staticUnaryNegation(Vector3)

Negates the specified vector.

The Vector3 structure provides support for hardware acceleration.

Universal Windows Platform
Available since 10
.NET Framework
Available since 4.6

Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top
Show: