Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: PowerPC Numerics / Part 2 - The PowerPC Numerics C Implementation
Chapter 8 - Environmental Control Functions


Controlling the Rounding Direction

In MathLib, the following functions control the rounding direction:
fegetround Returns the current rounding direction.
fesetround Sets the rounding direction.

The four rounding direction modes are defined as the constants shown in Table 8-1.
Table 8-1 Rounding direction modes in MathLib
Rounding directionConstant
To nearestFE_TONEAREST
Toward zeroFE_TOWARDZERO
UpwardFE_UPWARD
DownwardFE_DOWNWARD


Previous Book Contents Book Index Next

© Apple Computer, Inc.
13 JUL 1996