Struct Vec2w
- Namespace
- OpenCvSharp
- Assembly
- OpenCvSharp.dll
2-Tuple of ushort (System.UInt16)
[Serializable]
[SuppressMessage("Design", "CA1051: Do not declare visible instance fields")]
public struct Vec2w : IVec<Vec2w, ushort>, IVec, IEquatable<Vec2w>
- Implements
- Inherited Members
Constructors
Vec2w(ushort, ushort)
Initializer
public Vec2w(ushort item0, ushort item1)
Parameters
Fields
Item0
The value of the first component of this object.
public ushort Item0
Field Value
Item1
The value of the second component of this object.
public ushort Item1
Field Value
Properties
this[int]
Indexer
public ushort this[int i] { readonly get; set; }
Parameters
iint
Property Value
Methods
Add(Vec2w)
this + other
public readonly Vec2w Add(Vec2w other)
Parameters
otherVec2w
Returns
Deconstruct(out ushort, out ushort)
Deconstructing a Vector
public readonly void Deconstruct(out ushort item0, out ushort item1)
Parameters
Divide(double)
this / alpha
public readonly Vec2w Divide(double alpha)
Parameters
alphadouble
Returns
Equals(Vec2w)
Indicates whether the current object is equal to another object of the same type.
public readonly bool Equals(Vec2w other)
Parameters
otherVec2wAn object to compare with this object.
Returns
Equals(object?)
Indicates whether this instance and a specified object are equal.
public override readonly bool Equals(object? obj)
Parameters
objobjectThe object to compare with the current instance.
Returns
- bool
true if
objand this instance are the same type and represent the same value; otherwise, false.
GetHashCode()
Returns the hash code for this instance.
public override readonly int GetHashCode()
Returns
- int
A 32-bit signed integer that is the hash code for this instance.
Multiply(double)
this * alpha
public readonly Vec2w Multiply(double alpha)
Parameters
alphadouble
Returns
Subtract(Vec2w)
this - other
public readonly Vec2w Subtract(Vec2w other)
Parameters
otherVec2w
Returns
ToString()
Returns the fully qualified type name of this instance.
public override readonly string ToString()
Returns
- string
The fully qualified type name.
ToVec2d()
public Vec2d ToVec2d()
Returns
ToVec2f()
public Vec2f ToVec2f()
Returns
ToVec2i()
public Vec2i ToVec2i()
Returns
ToVec2s()
public Vec2s ToVec2s()
Returns
Operators
operator +(Vec2w, Vec2w)
public static Vec2w operator +(Vec2w a, Vec2w b)
Parameters
Returns
operator /(Vec2w, double)
public static Vec2w operator /(Vec2w a, double alpha)
Parameters
Returns
operator ==(Vec2w, Vec2w)
public static bool operator ==(Vec2w a, Vec2w b)
Parameters
Returns
operator !=(Vec2w, Vec2w)
public static bool operator !=(Vec2w a, Vec2w b)
Parameters
Returns
operator *(Vec2w, double)
public static Vec2w operator *(Vec2w a, double alpha)
Parameters
Returns
operator -(Vec2w, Vec2w)
public static Vec2w operator -(Vec2w a, Vec2w b)