Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/orxonox/trunk/src/debug.h @ 3205

Last change on this file since 3205 was 3205, checked in by bensch, 19 years ago

orxonox/trunk: DEBUG implemented in the configure-files

File size: 839 bytes
Line 
1#ifndef _DEBUG_H
2#define _DEBUG_H
3
4#ifdef  DEBUG
5#define PRINTF(x) \
6           PRINTF ## x
7
8#if DEBUG >= 1
9#define PRINTF1 \
10    if (verbose >= 1 ) \
11     printf ("%s:%d:", __FILE__, __LINE__); \
12     if (verbose >= 1) printf
13#else
14#define PRINTF1
15#endif
16     
17#if DEBUG >= 2
18#define PRINTF2 \
19     if (verbose >= 2 ) \
20     printf ("%s:%d:", __FILE__, __LINE__); \
21     if (verbose >= 2) printf
22#else
23#define PRINTF2
24#endif
25     
26#if DEBUG >= 3
27#define PRINTF3 \
28     if (verbose >= 3 ) \
29     printf ("%s:%d:", __FILE__, __LINE__); \
30     if (verbose >= 3) printf
31#else
32#define PRINTF3
33#endif
34     
35#if DEBUG >= 4
36#define PRINTF4 \
37     if (verbose >= 4 ) \
38     printf ("%s:%d:", __FILE__, __LINE__); \
39     if (verbose >= 4) printf
40#else
41#define PRINTF4
42#endif
43     
44     
45#else 
46#define PRINTF(x)
47#endif
48
49
50#endif /* _DEBUG_H */
Note: See TracBrowser for help on using the repository browser.