Struct Vector4F

Vector4F structure

Vector with 4 float parameters

public struct Vector4F : IEquatable<Vector4F>

Constructors

NameDescription
Vector4F(Color)Initializes a new instance of the Vector4F struct.
Vector4F(float)Initializes a new instance of the Vector4F struct.
Vector4F(Vector4F)Initializes a new instance of the Vector4F struct.
Vector4F(float, float, float, float)Initializes a new instance of the Vector4F struct.

Properties

NameDescription
A { get; set; }Alpha component
B { get; set; }Blue component
G { get; set; }Green component
Item { get; }Gets a coordinate at the specified index.
Length { get; }Length
R { get; set; }Red component
SquareLength { get; }Square length

Methods

NameDescription
static Zero()Creates vector with (0, 0, 0).
override Equals(object)Returns a boolean indicating whether the given Object is equal to this Vector4F instance.
Equals(Vector4F)Returns a boolean indicating whether the given Vector4F is equal to this Vector4F instance.
override GetHashCode()Returns the hash code for this instance.
Normalized()Creates normilized vector.
SafeNormalized()Creates normilized vector safely(returns self if length is zero).
ToVector2F()Creates Vector2F.
ToVector3F()Creates Vector3F.
operator +Adds two vectors together.
operator /Divides vector by scalar value.
operator ==Returns a boolean indicating whether the two given vectors are equal.
operator !=Returns a boolean indicating whether the two given vectors are not equal.
operator *Multiplies vector by scalar value.
operator -Subtracts the second vector from the first.

Fields

NameDescription
WW coordinate
XX coordinate
YY coordinate
ZZ coordinate

See Also