![]()  | 
  
    GCGlib
    0.04.228
    
   GCG Graphics Engine 
   | 
 
Macros | |
| #define | MIN(a, b) ((a > b) ? (b) : (a)) | 
| A macro that returns the minimum of a and b.  More... | |
| #define | MAX(a, b) ((a < b) ? (b) : (a)) | 
| A macro that returns the maximum of a and b.  More... | |
| #define | ABS(a) (((a) < 0) ? -(a) : (a)) | 
| A macro that returns the absolute value of a.  More... | |
| #define | SWAP(a, b) {(a) ^= (b); (b) ^= (a); (a) ^= (b);} | 
| A macro that swaps the values of a and b variables.  More... | |
| #define | DEG2RAD(a) (((a) * M_PI) / 180.0) | 
| A macro that converts a degrees in radians.  More... | |
| #define | RAD2DEG(a) (((a) * 180) / M_PI) | 
| A macro that converts a radians in degrees.  More... | |
| #define | TRUE 1 | 
| Defines the boolean value for true.  More... | |
| #define | FALSE 0 | 
| Defines the boolean value for false.  More... | |
| #define | EPSILON 0.0000077 | 
| Defines the minimum accepted value for single precision real numbers.  More... | |
| #define | INF 1.0e+16 | 
| Defines the biggest value for real numbers.  More... | |
| #define | FEQUAL(a, b) (fabs((a)-(b)) < EPSILON) | 
| A macro for real numbers equality comparisons.  More... | |
| #define | M_PI 3.14159265358979323846 | 
| A macro that defines the number PI with 20 decimals.  More... | |
| #define | NULL 0 | 
| Defines the null pointer.  More... | |
| #define | ISPOWEROF2(n) (!(n & (n-1))) | 
| A macro for checking if the integer number n is a power of 2.  More... | |
Functions | |
| static int | SQR (int x) | 
| Inline function for squaring integers.  More... | |
| static short | SQR (short x) | 
| Inline function for squaring shorts.  More... | |
| static long | SQR (long x) | 
| Inline function for squaring longs.  More... | |
| static float | SQR (float x) | 
| Inline function for squaring floats.  More... | |
| static double | SQR (double x) | 
| Inline function for squaring doubles.  More... | |
General GCGlib macros.
| #define ABS | ( | a | ) | (((a) < 0) ? -(a) : (a)) | 
A macro that returns the absolute value of a.
| #define DEG2RAD | ( | a | ) | (((a) * M_PI) / 180.0) | 
A macro that converts a degrees in radians.
| #define EPSILON 0.0000077 | 
Defines the minimum accepted value for single precision real numbers.
| #define FALSE 0 | 
Defines the boolean value for false.
| #define FEQUAL | ( | a, | |
| b | |||
| ) | (fabs((a)-(b)) < EPSILON) | 
A macro for real numbers equality comparisons.
| #define INF 1.0e+16 | 
Defines the biggest value for real numbers.
| #define ISPOWEROF2 | ( | n | ) | (!(n & (n-1))) | 
A macro for checking if the integer number n is a power of 2.
| #define M_PI 3.14159265358979323846 | 
A macro that defines the number PI with 20 decimals.
| #define MAX | ( | a, | |
| b | |||
| ) | ((a < b) ? (b) : (a)) | 
A macro that returns the maximum of a and b.
| #define MIN | ( | a, | |
| b | |||
| ) | ((a > b) ? (b) : (a)) | 
A macro that returns the minimum of a and b.
| #define NULL 0 | 
Defines the null pointer.
| #define RAD2DEG | ( | a | ) | (((a) * 180) / M_PI) | 
A macro that converts a radians in degrees.
| #define SWAP | ( | a, | |
| b | |||
| ) | {(a) ^= (b); (b) ^= (a); (a) ^= (b);} | 
A macro that swaps the values of a and b variables.
| #define TRUE 1 | 
Defines the boolean value for true.
      
  | 
  inlinestatic | 
Inline function for squaring integers.
| [in] | x | int number to be squared | 
      
  | 
  inlinestatic | 
Inline function for squaring shorts.
| [in] | x | short number to be squared | 
      
  | 
  inlinestatic | 
Inline function for squaring longs.
| [in] | x | long number to be squared | 
      
  | 
  inlinestatic | 
Inline function for squaring floats.
| [in] | x | float number to be squared | 
      
  | 
  inlinestatic | 
Inline function for squaring doubles.
| [in] | x | double number to be squared |