Various helper macros.  
More...
Go to the source code of this file.
| #define | CONCAT(a,  b) | 
|  | Concatenate the tokens aandb.
 | 
|  | 
| #define | CONCAT3(a,  b,  c) | 
|  | Concatenate the tokens a,b, andc.
 | 
|  | 
| #define | CONCAT4(a,  b,  c,  d) | 
|  | Concatenate the tokens a,b,c, andd.
 | 
|  | 
| #define | MAX(a,  b) | 
|  | Get the maximum of the two parameters. 
 | 
|  | 
| #define | MIN(a,  b) | 
|  | Get the minimum of the two parameters. 
 | 
|  | 
| #define | ABS(x) | 
|  | Returns the absolute value of x.
 | 
|  | 
| #define | LIMIT(val,  low,  high) | 
|  | Limit a value to an inclusive range. 
 | 
|  | 
◆ ABS
Value:
Returns the absolute value of x. 
- Note
- This is the trivial implementation that does evaluate the arguments more than once 
Definition at line 72 of file utils.h.
 
 
◆ CONCAT
Value:
Concatenate the tokens a and b. 
Definition at line 28 of file utils.h.
 
 
◆ CONCAT3
      
        
          | #define CONCAT3 | ( |  | a, | 
        
          |  |  |  | b, | 
        
          |  |  |  | c ) | 
      
 
Value:
Concatenate the tokens a , b , and c. 
Definition at line 33 of file utils.h.
 
 
◆ CONCAT4
      
        
          | #define CONCAT4 | ( |  | a, | 
        
          |  |  |  | b, | 
        
          |  |  |  | c, | 
        
          |  |  |  | d ) | 
      
 
Value:
Concatenate the tokens a , b , c , and d. 
Definition at line 38 of file utils.h.
 
 
◆ LIMIT
      
        
          | #define LIMIT | ( |  | val, | 
        
          |  |  |  | low, | 
        
          |  |  |  | high ) | 
      
 
Value:((val < low) ? low : (val > high) ? high : val)
Limit a value to an inclusive range. 
If val is > high, high is returned. If val is < low, low is returned. Otherwise, val is returned.
- Note
- This macro evaluate its arguments more than once.
- Parameters
- 
  
    | [in] | val | value to limit |  | [in] | low | minimum limit |  | [in] | high | maximum limit |  
 
- Returns
- range limited value 
Definition at line 89 of file utils.h.
 
 
◆ MAX
Value:
Get the maximum of the two parameters. 
- Note
- This is the trivial implementation that does evaluate the arguments more than once 
Definition at line 52 of file utils.h.
 
 
◆ MIN
Value:
Get the minimum of the two parameters. 
- Note
- This is the trivial implementation that does evaluate the arguments more than once 
Definition at line 62 of file utils.h.