/// <summary> /// from-vector constructor /// </summary> public gvec4(gvec4 <T> v) { this.x = v.x; this.y = v.y; this.z = v.z; this.w = v.w; }
/// <summary> /// Constructs this matrix from a series of column vectors. Non-overwritten fields are from an Identity matrix. /// </summary> public gmat2x4(gvec4 <T> c0, gvec4 <T> c1) { this.m00 = c0.x; this.m01 = c0.y; this.m02 = c0.z; this.m03 = c0.w; this.m10 = c1.x; this.m11 = c1.y; this.m12 = c1.z; this.m13 = c1.w; }
/// <summary> /// Constructs this matrix from a series of column vectors. Non-overwritten fields are from an Identity matrix. /// </summary> public gmat3x4(gvec4 <T> c0, gvec4 <T> c1, gvec4 <T> c2) { this.m00 = c0.x; this.m01 = c0.y; this.m02 = c0.z; this.m03 = c0.w; this.m10 = c1.x; this.m11 = c1.y; this.m12 = c1.z; this.m13 = c1.w; this.m20 = c2.x; this.m21 = c2.y; this.m22 = c2.z; this.m23 = c2.w; }
/// <summary> /// Constructs this matrix from a series of column vectors. Non-overwritten fields are from an Identity matrix. /// </summary> public gmat3x4(gvec4 <T> c0, gvec4 <T> c1) { this.m00 = c0.x; this.m01 = c0.y; this.m02 = c0.z; this.m03 = c0.w; this.m10 = c1.x; this.m11 = c1.y; this.m12 = c1.z; this.m13 = c1.w; this.m20 = default(T); this.m21 = default(T); this.m22 = default(T); this.m23 = default(T); }
/// <summary> /// Constructs this matrix from a series of column vectors. Non-overwritten fields are from an Identity matrix. /// </summary> public gmat4(gvec4 <T> c0, gvec4 <T> c1, gvec4 <T> c2) { this.m00 = c0.x; this.m01 = c0.y; this.m02 = c0.z; this.m03 = c0.w; this.m10 = c1.x; this.m11 = c1.y; this.m12 = c1.z; this.m13 = c1.w; this.m20 = c2.x; this.m21 = c2.y; this.m22 = c2.z; this.m23 = c2.w; this.m30 = default(T); this.m31 = default(T); this.m32 = default(T); this.m33 = default(T); }
/// <summary> /// Constructs this matrix from a series of column vectors. Non-overwritten fields are from an Identity matrix. /// </summary> public gmat4(gvec4 <T> c0, gvec4 <T> c1, gvec4 <T> c2, gvec4 <T> c3) { this.m00 = c0.x; this.m01 = c0.y; this.m02 = c0.z; this.m03 = c0.w; this.m10 = c1.x; this.m11 = c1.y; this.m12 = c1.z; this.m13 = c1.w; this.m20 = c2.x; this.m21 = c2.y; this.m22 = c2.z; this.m23 = c2.w; this.m30 = c3.x; this.m31 = c3.y; this.m32 = c3.z; this.m33 = c3.w; }
/// <summary> /// Returns a bvec4 from component-wise application of NotEqual (!EqualityComparer<T>.Default.Equals(lhs, rhs)). /// </summary> public static bvec4 NotEqual(T lhs, gvec4 <T> rhs) => new bvec4(!EqualityComparer <T> .Default.Equals(lhs, rhs.x), !EqualityComparer <T> .Default.Equals(lhs, rhs.y), !EqualityComparer <T> .Default.Equals(lhs, rhs.z), !EqualityComparer <T> .Default.Equals(lhs, rhs.w));
/// <summary> /// Returns a bvec4 from component-wise application of NotEqual (!EqualityComparer<T>.Default.Equals(lhs, rhs)). /// </summary> public static bvec4 NotEqual(gvec4 <T> lhs, T rhs) => new bvec4(!EqualityComparer <T> .Default.Equals(lhs.x, rhs), !EqualityComparer <T> .Default.Equals(lhs.y, rhs), !EqualityComparer <T> .Default.Equals(lhs.z, rhs), !EqualityComparer <T> .Default.Equals(lhs.w, rhs));
/// <summary> /// Returns a bvec4 from component-wise application of Equal (EqualityComparer<T>.Default.Equals(lhs, rhs)). /// </summary> public static bvec4 Equal(gvec4 <T> lhs, gvec4 <T> rhs) => new bvec4(EqualityComparer <T> .Default.Equals(lhs.x, rhs.x), EqualityComparer <T> .Default.Equals(lhs.y, rhs.y), EqualityComparer <T> .Default.Equals(lhs.z, rhs.z), EqualityComparer <T> .Default.Equals(lhs.w, rhs.w));
/// <summary> /// Returns true iff this equals rhs component-wise. /// </summary> public bool Equals(gvec4 <T> rhs) => ((EqualityComparer <T> .Default.Equals(x, rhs.x) && EqualityComparer <T> .Default.Equals(y, rhs.y)) && (EqualityComparer <T> .Default.Equals(z, rhs.z) && EqualityComparer <T> .Default.Equals(w, rhs.w)));
/// <summary> /// from-vector constructor (additional fields are truncated) /// </summary> public gvec3(gvec4 <T> v) { this.x = v.x; this.y = v.y; this.z = v.z; }
/// <summary> /// Returns an object that can be used for arbitrary swizzling (e.g. swizzle.zy) /// </summary> public static swizzle_gvec4 <T> swizzle <T>(gvec4 <T> v) => v.swizzle;
/// <summary> /// Returns a string representation of this vector using ', ' as a seperator. /// </summary> public static string ToString <T>(gvec4 <T> v) => v.ToString();
/// <summary> /// Returns a bvec4 from component-wise application of NotEqual (!EqualityComparer<T>.Default.Equals(lhs, rhs)). /// </summary> public static bvec4 NotEqual <T>(gvec4 <T> lhs, gvec4 <T> rhs) => gvec4 <T> .NotEqual(lhs, rhs);
/// <summary> /// Returns true iff this equals rhs type- and component-wise. /// </summary> public static bool Equals <T>(gvec4 <T> v, object obj) => v.Equals(obj);
/// <summary> /// Returns true iff this equals rhs component-wise. /// </summary> public static bool Equals <T>(gvec4 <T> v, gvec4 <T> rhs) => v.Equals(rhs);
/// <summary> /// Returns the number of components (4). /// </summary> public static int Count <T>(gvec4 <T> v) => v.Count;
/// <summary> /// Returns a string representation of this vector using a provided seperator. /// </summary> public static string ToString <T>(gvec4 <T> v, string sep) => v.ToString(sep);
/// <summary> /// from-vector constructor (additional fields are truncated) /// </summary> public gvec2(gvec4 <T> v) { this.x = v.x; this.y = v.y; }
/// <summary> /// Returns an array with all values /// </summary> public static T[] Values <T>(gvec4 <T> v) => v.Values;
/// <summary> /// Returns a hash code for this instance. /// </summary> public static int GetHashCode <T>(gvec4 <T> v) => v.GetHashCode();
/// <summary> /// Returns an enumerator that iterates through all components. /// </summary> public static IEnumerator <T> GetEnumerator <T>(gvec4 <T> v) => v.GetEnumerator();