Harlinn.Windows 0.1
Loading...
Searching...
No Matches
Harlinn::Math::Half Class Reference

#include <Math.h>

Public Member Functions

constexpr Half () noexcept=default
 
constexpr Half (const Half &other) noexcept=default
 
constexpr Halfoperator= (const Half &other) noexcept=default
 
constexpr Half (float value) noexcept
 
constexpr Half (double value) noexcept
 
constexpr UInt16 Bits () const noexcept
 
constexpr operator float () const noexcept
 
constexpr operator double () const noexcept
 
constexpr bool operator== (const Half &other) const noexcept
 
constexpr bool operator!= (const Half &other) const noexcept
 
constexpr Half operator- () const noexcept
 
constexpr int Sign () const noexcept
 
constexpr bool IsInf () const noexcept
 
constexpr bool IsNaN () const noexcept
 
constexpr Half NextUp () const noexcept
 
constexpr Half NextDown () const noexcept
 

Static Public Member Functions

static constexpr Half FromBits (UInt16 value) noexcept
 

Static Public Attributes

static constexpr UInt16 ExponentMask = 0b0111110000000000
 
static constexpr UInt16 SignificandMask = 0b1111111111
 
static constexpr UInt16 NegativeZero = 0b1000000000000000
 
static constexpr UInt16 PositiveZero = 0
 
static constexpr UInt16 NegativeInfinity = 0b1111110000000000
 
static constexpr UInt16 PositiveInfinity = 0b0111110000000000
 

Private Member Functions

constexpr Half (UInt16 value) noexcept
 

Private Attributes

UInt16 value_ = 0
 

Constructor & Destructor Documentation

◆ Half() [1/5]

Harlinn::Math::Half::Half ( )
constexprdefaultnoexcept

◆ Half() [2/5]

Harlinn::Math::Half::Half ( const Half & other)
constexprdefaultnoexcept

◆ Half() [3/5]

Harlinn::Math::Half::Half ( UInt16 value)
inlineexplicitconstexprprivatenoexcept

◆ Half() [4/5]

Harlinn::Math::Half::Half ( float value)
inlineexplicitconstexprnoexcept

◆ Half() [5/5]

Harlinn::Math::Half::Half ( double value)
inlineexplicitconstexprnoexcept

Member Function Documentation

◆ Bits()

UInt16 Harlinn::Math::Half::Bits ( ) const
inlineconstexprnoexcept

◆ FromBits()

static constexpr Half Harlinn::Math::Half::FromBits ( UInt16 value)
inlinestaticconstexprnoexcept

◆ IsInf()

bool Harlinn::Math::Half::IsInf ( ) const
inlineconstexprnoexcept

◆ IsNaN()

bool Harlinn::Math::Half::IsNaN ( ) const
inlineconstexprnoexcept

◆ NextDown()

Half Harlinn::Math::Half::NextDown ( ) const
inlineconstexprnoexcept

◆ NextUp()

Half Harlinn::Math::Half::NextUp ( ) const
inlineconstexprnoexcept

◆ operator double()

Harlinn::Math::Half::operator double ( ) const
inlineexplicitconstexprnoexcept

◆ operator float()

Harlinn::Math::Half::operator float ( ) const
inlineexplicitconstexprnoexcept

◆ operator!=()

bool Harlinn::Math::Half::operator!= ( const Half & other) const
inlineconstexprnoexcept

◆ operator-()

Half Harlinn::Math::Half::operator- ( ) const
inlineconstexprnoexcept

◆ operator=()

Half & Harlinn::Math::Half::operator= ( const Half & other)
constexprdefaultnoexcept

◆ operator==()

bool Harlinn::Math::Half::operator== ( const Half & other) const
inlineconstexprnoexcept

◆ Sign()

int Harlinn::Math::Half::Sign ( ) const
inlineconstexprnoexcept

Member Data Documentation

◆ ExponentMask

UInt16 Harlinn::Math::Half::ExponentMask = 0b0111110000000000
staticconstexpr

◆ NegativeInfinity

UInt16 Harlinn::Math::Half::NegativeInfinity = 0b1111110000000000
staticconstexpr

◆ NegativeZero

UInt16 Harlinn::Math::Half::NegativeZero = 0b1000000000000000
staticconstexpr

◆ PositiveInfinity

UInt16 Harlinn::Math::Half::PositiveInfinity = 0b0111110000000000
staticconstexpr

◆ PositiveZero

UInt16 Harlinn::Math::Half::PositiveZero = 0
staticconstexpr

◆ SignificandMask

UInt16 Harlinn::Math::Half::SignificandMask = 0b1111111111
staticconstexpr

◆ value_

UInt16 Harlinn::Math::Half::value_ = 0
private

The documentation for this class was generated from the following file: