home *** CD-ROM | disk | FTP | other *** search
- /*
- File: FixMath.h
-
- Copyright: © 1984-1993 by Apple Computer, Inc., all rights reserved.
-
- WARNING
- This file was auto generated by the interfacer tool. Modifications
- must be made to the master file.
-
- */
-
- #ifndef __FIXMATH__
- #define __FIXMATH__
-
- #ifndef __TYPES__
- #include <Types.h>
- /* #include <ConditionalMacros.h> */
- /* #include <MixedMode.h> */
- /* #include <Traps.h> */
- #endif
-
- enum {
- fixed1 = (long)0x00010000,
- fract1 = (long)0x40000000,
- positiveInfinity = (long)0x7FFFFFFF,
- negativeInfinity = (long)0x80000000
- };
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- extern pascal Fract Fix2Frac(Fixed x)
- ONEWORDINLINE(0xA841);
- extern pascal long Fix2Long(Fixed x)
- ONEWORDINLINE(0xA840);
- extern pascal Fixed Long2Fix(long x)
- ONEWORDINLINE(0xA83F);
- extern pascal Fixed Frac2Fix(Fract x)
- ONEWORDINLINE(0xA842);
- extern pascal Fract FracMul(Fract x, Fract y)
- ONEWORDINLINE(0xA84A);
- extern pascal Fixed FixDiv(Fixed x, Fixed y)
- ONEWORDINLINE(0xA84D);
- extern pascal Fract FracDiv(Fract x, Fract y)
- ONEWORDINLINE(0xA84B);
- extern pascal Fract FracSqrt(Fract x)
- ONEWORDINLINE(0xA849);
- extern pascal Fract FracSin(Fixed x)
- ONEWORDINLINE(0xA848);
- extern pascal Fract FracCos(Fixed x)
- ONEWORDINLINE(0xA847);
- extern pascal Fixed FixATan2(long x, long y)
- ONEWORDINLINE(0xA818);
- #if defined(powerc) || defined(__powerc)
- extern wide *WideAdd(wide *target, const wide *source);
- extern short WideCompare(const wide *target, const wide *source);
- extern wide *WideNegate(wide *target);
- extern wide *WideShift(wide *target, long shift);
- extern unsigned long WideSquareRoot(const wide *source);
- extern wide *WideSubtract(wide *target, const wide *source);
- extern wide *WideMultiply(long multiplicand, long multiplier, wide *target);
-
- /* returns the quotient */
-
- extern long WideDivide(const wide *dividend, long divisor, long *remainder);
-
- /* quotient replaces dividend */
-
- extern wide *WideWideDivide(wide *dividend, long divisor, long *remainder);
- extern wide *WideBitShift(wide *src, long shift);
- #endif
-
- #if defined(applec) && !defined(mc68881)
- extern pascal double_t Frac2X(Fract x)
- ONEWORDINLINE(0xA845);
- extern pascal double_t Fix2X(Fixed x)
- ONEWORDINLINE(0xA843);
- extern pascal Fixed X2Fix(double_t x)
- ONEWORDINLINE(0xA844);
- extern pascal Fract X2Frac(double_t x)
- ONEWORDINLINE(0xA846);
- #else
- #if 0
- extern pascal double_t Frac2X(Fract x);
- extern pascal double_t Fix2X(Fixed x);
- extern pascal Fixed X2Fix(double_t x);
- extern pascal Fract X2Frac(double_t x);
- #endif
- #endif
-
- #ifdef __cplusplus
- }
- #endif
-
- #endif
-
-