84 union { uint32_t i;
float f; } u;
92 union { uint32_t i;
float f; } u;
95 if (e)
return (uint16_t)(e + (((u.i&0x7fffff) + 0x1000) >> 13));
Definitions related to exported Ptex API symbol visibility.
Portable fixed-width integer types.
#define PTEX_NAMESPACE_END
Half-precision (16-bit) floating-point type.
PtexHalf & operator=(float val)
PtexHalf()
Default constructor, value is undefined.
static uint16_t fromFloat(float val)
static uint32_t h2fTable[65536]
static uint16_t fromFloat_except(uint32_t val)
Handle exceptional cases for half-to-float conversion.
static uint16_t f2hTable[512]
static float toFloat(uint16_t h)