public final class NFPUnsignedDoubleInt extends Object
Conversion of unsigned normalized fixed-point values to and from floating point values.
The OpenGL 3.3 specification defines the conversion from floating point
values x (implied to be in the range [0, 1]) to unsigned
normalized fixed-point values f, with b bits of precision,
as:
f = x * (pow(2, b) - 1)
The specification defines the conversion from unsigned normalized
fixed-point values f with b bits of precision to floating
point values x as:
x = f / (pow(2, b) - 1)
This implementation provides general conversion functions that operate on
arbitrary values of b, and specialized functions that operate for
specific values of b using precomputed terms.
| Modifier and Type | Method and Description |
|---|---|
static double |
fromUnsignedNormalized(int f,
int b)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized10(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized11(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized12(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized13(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized14(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized15(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized16(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized17(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized18(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized19(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized2(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized20(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized21(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized22(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized23(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized24(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized25(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized26(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized27(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized28(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized29(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized3(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized30(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized31(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized32(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized4(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized5(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized6(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized7(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized8(int f)
Convert
f to floating point format. |
static double |
fromUnsignedNormalized9(int f)
Convert
f to floating point format. |
static int |
toUnsignedNormalized(double x,
int b)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized10(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized11(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized12(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized13(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized14(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized15(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized16(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized17(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized18(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized19(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized2(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized20(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized21(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized22(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized23(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized24(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized25(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized26(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized27(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized28(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized29(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized3(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized30(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized31(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized32(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized4(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized5(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized6(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized7(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized8(double x)
Convert
x to fixed-point format. |
static int |
toUnsignedNormalized9(double x)
Convert
x to fixed-point format. |
public static double fromUnsignedNormalized(int f,
int b)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range b - A value in the range public static int toUnsignedNormalized(double x,
int b)
x to fixed-point format.x - A value in the range [0, 1]b - A value in the range b bits of
precisionpublic static int toUnsignedNormalized2(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized3(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized4(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized5(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized6(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized7(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized8(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized9(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized10(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized11(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized12(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized13(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized14(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized15(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized16(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized17(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized18(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized19(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized20(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized21(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized22(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized23(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized24(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized25(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized26(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized27(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized28(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized29(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized30(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized31(double x)
x to fixed-point format.x - A value in the range [0, 1]public static int toUnsignedNormalized32(double x)
x to fixed-point format.x - A value in the range [0, 1]public static double fromUnsignedNormalized2(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 2) - 1][0, 1]public static double fromUnsignedNormalized3(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 3) - 1][0, 1]public static double fromUnsignedNormalized4(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 4) - 1][0, 1]public static double fromUnsignedNormalized5(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 5) - 1][0, 1]public static double fromUnsignedNormalized6(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 6) - 1][0, 1]public static double fromUnsignedNormalized7(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 7) - 1][0, 1]public static double fromUnsignedNormalized8(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 8) - 1][0, 1]public static double fromUnsignedNormalized9(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 9) - 1][0, 1]public static double fromUnsignedNormalized10(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 10) - 1][0, 1]public static double fromUnsignedNormalized11(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 11) - 1][0, 1]public static double fromUnsignedNormalized12(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 12) - 1][0, 1]public static double fromUnsignedNormalized13(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 13) - 1][0, 1]public static double fromUnsignedNormalized14(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 14) - 1][0, 1]public static double fromUnsignedNormalized15(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 15) - 1][0, 1]public static double fromUnsignedNormalized16(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 16) - 1][0, 1]public static double fromUnsignedNormalized17(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 17) - 1][0, 1]public static double fromUnsignedNormalized18(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 18) - 1][0, 1]public static double fromUnsignedNormalized19(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 19) - 1][0, 1]public static double fromUnsignedNormalized20(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 20) - 1][0, 1]public static double fromUnsignedNormalized21(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 21) - 1][0, 1]public static double fromUnsignedNormalized22(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 22) - 1][0, 1]public static double fromUnsignedNormalized23(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 23) - 1][0, 1]public static double fromUnsignedNormalized24(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 24) - 1][0, 1]public static double fromUnsignedNormalized25(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 25) - 1][0, 1]public static double fromUnsignedNormalized26(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 26) - 1][0, 1]public static double fromUnsignedNormalized27(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 27) - 1][0, 1]public static double fromUnsignedNormalized28(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 28) - 1][0, 1]public static double fromUnsignedNormalized29(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 29) - 1][0, 1]public static double fromUnsignedNormalized30(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 30) - 1][0, 1]public static double fromUnsignedNormalized31(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 31) - 1][0, 1]public static double fromUnsignedNormalized32(int f)
f to floating point format. f is assumed to be an
unsigned fixed-point value with b bits of precision.f - A value in the range [0, (2 ^ 32) - 1][0, 1]Copyright © 2016 <code@io7m.com> http://io7m.com