/// <summary> /// Copying constructor /// </summary> /// <param name="copyVector">Copying vector</param> public GlVectorR2(GlVectorR2 copyVector) : this(copyVector == null ? 0 : copyVector.dX, copyVector == null ? 0 : copyVector.dY) { }
/// <returns>If vectors are equal</returns> public static bool Equals(GlVectorR2 V1, GlVectorR2 V2) { return((V1 == null || V2 == null) ? false : (V1.dX == V2.dX && V1.dY == V2.dY)); }
/// <returns>If vectors are perpendicular</returns> public static bool isPerpendicular(GlVectorR2 V1, GlVectorR2 V2) { return((V1 == null || V2 == null) ? false : (Math.Abs(V1 * V2) < FAULT)); }
public override bool Equals(object obj) { return(obj.GetType().Equals(this.GetType()) && GlVectorR2.Equals(obj as GlVectorR2, this)); }
//////////////TRANSFORM_METHODS//////////////// /////////////////////////////////////////////// ///////////////ADDITIONAL_METHODS////////////// /// <returns>If vectors are collinear</returns> public static bool isParallel(GlVectorR2 V1, GlVectorR2 V2) { return((V1 == null || V2 == null) ? false : (Math.Abs(V1 ^ V2) < FAULT)); }