Copyright | (C) 2014-15 Edward Kmett |
---|---|
License | BSD-style (see the file LICENSE) |
Maintainer | Edward Kmett <ekmett@gmail.com> |
Stability | experimental |
Portability | non-portable |
Safe Haskell | None |
Language | Haskell98 |
Fixed precision arithmetic. This format is the same format used by
OpenGL ES 1's GLfixed
data type:
One sign bit, 15 bits to the left of the decimal place and 16 bits to the right packed into a 32-bit integer.
Documentation
A signed 2s complement 15.16 scale fixed precision number
Instances
Bounded Fixed Source # | |
Enum Fixed Source # | |
Eq Fixed Source # | |
Floating Fixed Source # | |
Fractional Fixed Source # | |
Num Fixed Source # | |
Ord Fixed Source # | |
Real Fixed Source # | |
Defined in Numeric.Fixed toRational :: Fixed -> Rational # | |
RealFloat Fixed Source # | |
Defined in Numeric.Fixed floatRadix :: Fixed -> Integer # floatDigits :: Fixed -> Int # floatRange :: Fixed -> (Int, Int) # decodeFloat :: Fixed -> (Integer, Int) # encodeFloat :: Integer -> Int -> Fixed # significand :: Fixed -> Fixed # scaleFloat :: Int -> Fixed -> Fixed # isInfinite :: Fixed -> Bool # isDenormalized :: Fixed -> Bool # isNegativeZero :: Fixed -> Bool # | |
RealFrac Fixed Source # | |
Show Fixed Source # | |
Storable Fixed Source # | |