Half Struct Reference

a scalar half More...

List of all members.

Public Member Functions

 Half (float f)
 constructor taking a float to convert to half
float ToFloat ()
 return the float value of this
bool Equals (Half h)
 equality test
override bool Equals (Object o)
 equality test
override string ToString ()
 get the string representation of float value
override int GetHashCode ()
 gets the hash code for this

Static Public Member Functions

static bool operator== (Half h1, Half h2)
 equality operator
static bool operator!= (Half h1, Half h2)
 not equals operator
static implicit operator float (Half h)
 float casting operator
static operator Half (float f)
 half casting operator

Public Attributes

ushort Bits
 the half data

Detailed Description

a scalar half


Constructor & Destructor Documentation

Half ( float  f)

constructor taking a float to convert to half

Parameters:
fthe float to convert

Member Function Documentation

bool Equals ( Half  h)

equality test

Parameters:
hthe half to compare this to
Returns:
true if this == h, false otherwise
override bool Equals ( Object  o)

equality test

Parameters:
othe object to compare this to
Returns:
true if this == o, false otherwise
override int GetHashCode ( )

gets the hash code for this

Returns:
integer hash code
static implicit operator float ( Half  h) [static]

float casting operator

Parameters:
hthe half to convert to float
Returns:
the float value of the half
static operator Half ( float  f) [explicit, static]

half casting operator

Parameters:
fthe float to convert to half
Returns:
the half value of the float
static bool operator!= ( Half  h1,
Half  h2 
) [static]

not equals operator

Parameters:
h1half 1
h2half 2
Returns:
true if half 1 != half 2, false otherwise
static bool operator== ( Half  h1,
Half  h2 
) [static]

equality operator

Parameters:
h1half 1
h2half 2
Returns:
true if half 1 == half 2, false otherwise
float ToFloat ( )

return the float value of this

Returns:
the float value of this
override string ToString ( )

get the string representation of float value

Returns:
the string representation of float value

Member Data Documentation

ushort Bits

the half data