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: Operating System Utilities /
Chapter 3 - Mathematical and Logical Utilities / Mathematical and Logical Utilities Reference
Routines / Multiplying and Dividing Fixed-Point Numbers


FixMul

You can use the FixMul function to multiply a variable of type Fixed with another variable of type Fixed or with a variable of type Fract or LongInt.

FUNCTION FixMul (a, b: Fixed): Fixed;
a
The first operand, which can be a variable of type Fixed or a variable of type Fract or LongInt.
b
The second operand, which can be a variable of type Fixed or a variable of type Fract or LongInt.
DESCRIPTION
The FixMul function returns the product of the numbers specified in the a and b parameters. At least one of a and b should be a variable of type Fixed.

The returned value is in the format of a LongInt if one of a or b is a LongInt. It is a Fract number if one of a or b is Fract. It is a Fixed number if both a and b are Fixed numbers.

Overflows are set to the maximum representable value with the correct sign ($80000000 for negative results and $7FFFFFFF for positive results).

SEE ALSO
For a summary of the routines that perform operations on the Fixed and Fract data type, see Table 3-2 on page 3-26.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
6 JUL 1996