1fixacos(3) Allegro manual fixacos(3)
2
3
4
6 fixacos - Fixed point inverse cosine lookup table. Allegro game pro‐
7 gramming library.
8
10 #include <allegro.h>
11
12
13 fixed fixacos(fixed x);
14
16 This function finds the inverse cosine of a value using a lookup table.
17 The input value must be a fixed point radian. The inverse cosine is
18 defined only in the domain from `-1' to `1'. Outside of this input
19 range, the function will set `errno' to EDOM and return zero. Example:
20
21 fixed result;
22
23 /* Sets `result' to binary angle 128. */
24 result = fixacos(itofix(-1));
25
27 Returns the inverse sine of a fixed point value, measured as fixed
28 point binary format angle, or zero if the input was out of range. All
29 return values of this function will be in the range `0' to `128'.
30
31
33Allegro version 4.2.3 fixacos(3)