source:
orxonox.OLD/orxonox/trunk/src/debug.h
@
3210
Last change on this file since 3210 was 3206, checked in by bensch, 20 years ago | |
---|---|
File size: 652 bytes |
Rev | Line | |
---|---|---|
[3204] | 1 | #ifndef _DEBUG_H |
2 | #define _DEBUG_H | |
3 | ||
4 | #ifdef DEBUG | |
[3205] | 5 | #define PRINTF(x) \ |
6 | PRINTF ## x | |
7 | ||
8 | #if DEBUG >= 1 | |
9 | #define PRINTF1 \ | |
10 | if (verbose >= 1 ) \ | |
[3206] | 11 | printf |
[3205] | 12 | #else |
[3206] | 13 | #define PRINTF1 // |
[3205] | 14 | #endif |
15 | ||
16 | #if DEBUG >= 2 | |
17 | #define PRINTF2 \ | |
18 | if (verbose >= 2 ) \ | |
[3206] | 19 | printf |
20 | ||
[3205] | 21 | #else |
[3206] | 22 | #define PRINTF2 // |
[3205] | 23 | #endif |
24 | ||
25 | #if DEBUG >= 3 | |
26 | #define PRINTF3 \ | |
27 | if (verbose >= 3 ) \ | |
[3206] | 28 | printf |
[3205] | 29 | #else |
[3206] | 30 | #define PRINTF3 // |
[3205] | 31 | #endif |
32 | ||
33 | #if DEBUG >= 4 | |
34 | #define PRINTF4 \ | |
35 | if (verbose >= 4 ) \ | |
[3206] | 36 | printf |
[3205] | 37 | #else |
[3206] | 38 | #define PRINTF4 // |
[3205] | 39 | #endif |
40 | ||
41 | ||
[3204] | 42 | #else |
[3206] | 43 | #define PRINTF(x) // |
[3204] | 44 | #endif |
45 | ||
[3206] | 46 | #define PRINTF0 \ |
47 | printf | |
[3204] | 48 | |
49 | #endif /* _DEBUG_H */ |
Note: See TracBrowser
for help on using the repository browser.