Class Half2
Defines a two component vector, using half precision floating point coordinates.
Inheritance
Implements
Namespace: FlaxEngine
Assembly: FlaxEngine.CSharp.dll
Syntax
public sealed class Half2 : ValueType, IEquatable<Half2>
Constructors
Half2(Half)
Initializes a new instance of the Half2 structure.
Declaration
public Half2(Half value)
Parameters
Half
value
The value to set for both the X and Y components. |
Half2(Half, Half)
Initializes a new instance of the Half2 structure.
Declaration
public Half2(Half x, Half y)
Parameters
Half
x
The X component. |
Half
y
The Y component. |
Half2(Single)
Initializes a new instance of the Half2 structure.
Declaration
public Half2(float value)
Parameters
System.Single
value
The value to set for both the X and Y components. |
Half2(Single, Single)
Initializes a new instance of the Half2 structure.
Declaration
public Half2(float x, float y)
Parameters
System.Single
x
The X component. |
System.Single
y
The Y component. |
Fields
X
Gets or sets the X component of the vector.
Declaration
public Half X
Field Value
Half
The X component of the vector. |
Y
Gets or sets the Y component of the vector.
Declaration
public Half Y
Field Value
Half
The Y component of the vector. |
Methods
Equals(Half2)
Returns a value that indicates whether the current instance is equal to the specified object.
Declaration
public bool Equals(Half2 other)
Parameters
Half2
other
Object to make the comparison with. |
Returns
System.Boolean
|
Equals(ref Half2, ref Half2)
Determines whether the specified object instances are considered equal.
Declaration
public static bool Equals(ref Half2 value1, ref Half2 value2)
Parameters
Half2
value1
|
Half2
value2
|
Returns
System.Boolean
|
Equals(Object)
Returns a value that indicates whether the current instance is equal to a specified object.
Declaration
public override bool Equals(object obj)
Parameters
System.Object
obj
Object to make the comparison with. |
Returns
System.Boolean
|
GetHashCode()
Returns the hash code for this instance.
Declaration
public override int GetHashCode()
Returns
System.Int32
A 32-bit signed integer hash code. |
ToString()
Returns a System.String that represents this instance.
Declaration
public override string ToString()
Returns
System.String
A System.String that represents this instance. |
Operators
Equality(Half2, Half2)
Tests for equality between two objects.
Declaration
public static bool operator ==(Half2 left, Half2 right)
Parameters
Half2
left
The first value to compare. |
Half2
right
The second value to compare. |
Returns
System.Boolean
|
Explicit(Float2 to Half2)
Declaration
public static explicit operator Half2(Float2 value)
Parameters
Float2
value
The value. |
Returns
Half2
The result of the conversion. |
Explicit(Half2 to Float2)
Declaration
public static explicit operator Float2(Half2 value)
Parameters
Half2
value
The value. |
Returns
Float2
The result of the conversion. |
Inequality(Half2, Half2)
Tests for inequality between two objects.
Declaration
public static bool operator !=(Half2 left, Half2 right)
Parameters
Half2
left
The first value to compare. |
Half2
right
The second value to compare. |
Returns
System.Boolean
|