diff options
Diffstat (limited to 'libraries/irrlicht-1.8/source/Irrlicht/libpng/pngdebug.h')
-rw-r--r-- | libraries/irrlicht-1.8/source/Irrlicht/libpng/pngdebug.h | 314 |
1 files changed, 157 insertions, 157 deletions
diff --git a/libraries/irrlicht-1.8/source/Irrlicht/libpng/pngdebug.h b/libraries/irrlicht-1.8/source/Irrlicht/libpng/pngdebug.h index 96c1ea4..16f81fd 100644 --- a/libraries/irrlicht-1.8/source/Irrlicht/libpng/pngdebug.h +++ b/libraries/irrlicht-1.8/source/Irrlicht/libpng/pngdebug.h | |||
@@ -1,157 +1,157 @@ | |||
1 | 1 | ||
2 | /* pngdebug.h - Debugging macros for libpng, also used in pngtest.c | 2 | /* pngdebug.h - Debugging macros for libpng, also used in pngtest.c |
3 | * | 3 | * |
4 | * Copyright (c) 1998-2011 Glenn Randers-Pehrson | 4 | * Copyright (c) 1998-2011 Glenn Randers-Pehrson |
5 | * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) | 5 | * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) |
6 | * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) | 6 | * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) |
7 | * | 7 | * |
8 | * Last changed in libpng 1.5.0 [January 6, 2011] | 8 | * Last changed in libpng 1.5.0 [January 6, 2011] |
9 | * | 9 | * |
10 | * This code is released under the libpng license. | 10 | * This code is released under the libpng license. |
11 | * For conditions of distribution and use, see the disclaimer | 11 | * For conditions of distribution and use, see the disclaimer |
12 | * and license in png.h | 12 | * and license in png.h |
13 | */ | 13 | */ |
14 | 14 | ||
15 | /* Define PNG_DEBUG at compile time for debugging information. Higher | 15 | /* Define PNG_DEBUG at compile time for debugging information. Higher |
16 | * numbers for PNG_DEBUG mean more debugging information. This has | 16 | * numbers for PNG_DEBUG mean more debugging information. This has |
17 | * only been added since version 0.95 so it is not implemented throughout | 17 | * only been added since version 0.95 so it is not implemented throughout |
18 | * libpng yet, but more support will be added as needed. | 18 | * libpng yet, but more support will be added as needed. |
19 | * | 19 | * |
20 | * png_debug[1-2]?(level, message ,arg{0-2}) | 20 | * png_debug[1-2]?(level, message ,arg{0-2}) |
21 | * Expands to a statement (either a simple expression or a compound | 21 | * Expands to a statement (either a simple expression or a compound |
22 | * do..while(0) statement) that outputs a message with parameter | 22 | * do..while(0) statement) that outputs a message with parameter |
23 | * substitution if PNG_DEBUG is defined to 2 or more. If PNG_DEBUG | 23 | * substitution if PNG_DEBUG is defined to 2 or more. If PNG_DEBUG |
24 | * is undefined, 0 or 1 every png_debug expands to a simple expression | 24 | * is undefined, 0 or 1 every png_debug expands to a simple expression |
25 | * (actually ((void)0)). | 25 | * (actually ((void)0)). |
26 | * | 26 | * |
27 | * level: level of detail of message, starting at 0. A level 'n' | 27 | * level: level of detail of message, starting at 0. A level 'n' |
28 | * message is preceded by 'n' tab characters (not implemented | 28 | * message is preceded by 'n' tab characters (not implemented |
29 | * on Microsoft compilers unless PNG_DEBUG_FILE is also | 29 | * on Microsoft compilers unless PNG_DEBUG_FILE is also |
30 | * defined, to allow debug DLL compilation with no standard IO). | 30 | * defined, to allow debug DLL compilation with no standard IO). |
31 | * message: a printf(3) style text string. A trailing '\n' is added | 31 | * message: a printf(3) style text string. A trailing '\n' is added |
32 | * to the message. | 32 | * to the message. |
33 | * arg: 0 to 2 arguments for printf(3) style substitution in message. | 33 | * arg: 0 to 2 arguments for printf(3) style substitution in message. |
34 | */ | 34 | */ |
35 | #ifndef PNGDEBUG_H | 35 | #ifndef PNGDEBUG_H |
36 | #define PNGDEBUG_H | 36 | #define PNGDEBUG_H |
37 | /* These settings control the formatting of messages in png.c and pngerror.c */ | 37 | /* These settings control the formatting of messages in png.c and pngerror.c */ |
38 | /* Moved to pngdebug.h at 1.5.0 */ | 38 | /* Moved to pngdebug.h at 1.5.0 */ |
39 | # ifndef PNG_LITERAL_SHARP | 39 | # ifndef PNG_LITERAL_SHARP |
40 | # define PNG_LITERAL_SHARP 0x23 | 40 | # define PNG_LITERAL_SHARP 0x23 |
41 | # endif | 41 | # endif |
42 | # ifndef PNG_LITERAL_LEFT_SQUARE_BRACKET | 42 | # ifndef PNG_LITERAL_LEFT_SQUARE_BRACKET |
43 | # define PNG_LITERAL_LEFT_SQUARE_BRACKET 0x5b | 43 | # define PNG_LITERAL_LEFT_SQUARE_BRACKET 0x5b |
44 | # endif | 44 | # endif |
45 | # ifndef PNG_LITERAL_RIGHT_SQUARE_BRACKET | 45 | # ifndef PNG_LITERAL_RIGHT_SQUARE_BRACKET |
46 | # define PNG_LITERAL_RIGHT_SQUARE_BRACKET 0x5d | 46 | # define PNG_LITERAL_RIGHT_SQUARE_BRACKET 0x5d |
47 | # endif | 47 | # endif |
48 | # ifndef PNG_STRING_NEWLINE | 48 | # ifndef PNG_STRING_NEWLINE |
49 | # define PNG_STRING_NEWLINE "\n" | 49 | # define PNG_STRING_NEWLINE "\n" |
50 | # endif | 50 | # endif |
51 | 51 | ||
52 | #ifdef PNG_DEBUG | 52 | #ifdef PNG_DEBUG |
53 | # if (PNG_DEBUG > 0) | 53 | # if (PNG_DEBUG > 0) |
54 | # if !defined(PNG_DEBUG_FILE) && defined(_MSC_VER) | 54 | # if !defined(PNG_DEBUG_FILE) && defined(_MSC_VER) |
55 | # include <crtdbg.h> | 55 | # include <crtdbg.h> |
56 | # if (PNG_DEBUG > 1) | 56 | # if (PNG_DEBUG > 1) |
57 | # ifndef _DEBUG | 57 | # ifndef _DEBUG |
58 | # define _DEBUG | 58 | # define _DEBUG |
59 | # endif | 59 | # endif |
60 | # ifndef png_debug | 60 | # ifndef png_debug |
61 | # define png_debug(l,m) _RPT0(_CRT_WARN,m PNG_STRING_NEWLINE) | 61 | # define png_debug(l,m) _RPT0(_CRT_WARN,m PNG_STRING_NEWLINE) |
62 | # endif | 62 | # endif |
63 | # ifndef png_debug1 | 63 | # ifndef png_debug1 |
64 | # define png_debug1(l,m,p1) _RPT1(_CRT_WARN,m PNG_STRING_NEWLINE,p1) | 64 | # define png_debug1(l,m,p1) _RPT1(_CRT_WARN,m PNG_STRING_NEWLINE,p1) |
65 | # endif | 65 | # endif |
66 | # ifndef png_debug2 | 66 | # ifndef png_debug2 |
67 | # define png_debug2(l,m,p1,p2) \ | 67 | # define png_debug2(l,m,p1,p2) \ |
68 | _RPT2(_CRT_WARN,m PNG_STRING_NEWLINE,p1,p2) | 68 | _RPT2(_CRT_WARN,m PNG_STRING_NEWLINE,p1,p2) |
69 | # endif | 69 | # endif |
70 | # endif | 70 | # endif |
71 | # else /* PNG_DEBUG_FILE || !_MSC_VER */ | 71 | # else /* PNG_DEBUG_FILE || !_MSC_VER */ |
72 | # ifndef PNG_STDIO_SUPPORTED | 72 | # ifndef PNG_STDIO_SUPPORTED |
73 | # include <stdio.h> /* not included yet */ | 73 | # include <stdio.h> /* not included yet */ |
74 | # endif | 74 | # endif |
75 | # ifndef PNG_DEBUG_FILE | 75 | # ifndef PNG_DEBUG_FILE |
76 | # define PNG_DEBUG_FILE stderr | 76 | # define PNG_DEBUG_FILE stderr |
77 | # endif /* PNG_DEBUG_FILE */ | 77 | # endif /* PNG_DEBUG_FILE */ |
78 | 78 | ||
79 | # if (PNG_DEBUG > 1) | 79 | # if (PNG_DEBUG > 1) |
80 | /* Note: ["%s"m PNG_STRING_NEWLINE] probably does not work on | 80 | /* Note: ["%s"m PNG_STRING_NEWLINE] probably does not work on |
81 | * non-ISO compilers | 81 | * non-ISO compilers |
82 | */ | 82 | */ |
83 | # ifdef __STDC__ | 83 | # ifdef __STDC__ |
84 | # ifndef png_debug | 84 | # ifndef png_debug |
85 | # define png_debug(l,m) \ | 85 | # define png_debug(l,m) \ |
86 | do { \ | 86 | do { \ |
87 | int num_tabs=l; \ | 87 | int num_tabs=l; \ |
88 | fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ | 88 | fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ |
89 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":"")))); \ | 89 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":"")))); \ |
90 | } while (0) | 90 | } while (0) |
91 | # endif | 91 | # endif |
92 | # ifndef png_debug1 | 92 | # ifndef png_debug1 |
93 | # define png_debug1(l,m,p1) \ | 93 | # define png_debug1(l,m,p1) \ |
94 | do { \ | 94 | do { \ |
95 | int num_tabs=l; \ | 95 | int num_tabs=l; \ |
96 | fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ | 96 | fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ |
97 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))),p1); \ | 97 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))),p1); \ |
98 | } while (0) | 98 | } while (0) |
99 | # endif | 99 | # endif |
100 | # ifndef png_debug2 | 100 | # ifndef png_debug2 |
101 | # define png_debug2(l,m,p1,p2) \ | 101 | # define png_debug2(l,m,p1,p2) \ |
102 | do { \ | 102 | do { \ |
103 | int num_tabs=l; \ | 103 | int num_tabs=l; \ |
104 | fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ | 104 | fprintf(PNG_DEBUG_FILE,"%s"m PNG_STRING_NEWLINE,(num_tabs==1 ? "\t" : \ |
105 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))),p1,p2); \ | 105 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))),p1,p2); \ |
106 | } while (0) | 106 | } while (0) |
107 | # endif | 107 | # endif |
108 | # else /* __STDC __ */ | 108 | # else /* __STDC __ */ |
109 | # ifndef png_debug | 109 | # ifndef png_debug |
110 | # define png_debug(l,m) \ | 110 | # define png_debug(l,m) \ |
111 | do { \ | 111 | do { \ |
112 | int num_tabs=l; \ | 112 | int num_tabs=l; \ |
113 | char format[256]; \ | 113 | char format[256]; \ |
114 | snprintf(format,256,"%s%s%s",(num_tabs==1 ? "\t" : \ | 114 | snprintf(format,256,"%s%s%s",(num_tabs==1 ? "\t" : \ |
115 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))), \ | 115 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))), \ |
116 | m,PNG_STRING_NEWLINE); \ | 116 | m,PNG_STRING_NEWLINE); \ |
117 | fprintf(PNG_DEBUG_FILE,format); \ | 117 | fprintf(PNG_DEBUG_FILE,format); \ |
118 | } while (0) | 118 | } while (0) |
119 | # endif | 119 | # endif |
120 | # ifndef png_debug1 | 120 | # ifndef png_debug1 |
121 | # define png_debug1(l,m,p1) \ | 121 | # define png_debug1(l,m,p1) \ |
122 | do { \ | 122 | do { \ |
123 | int num_tabs=l; \ | 123 | int num_tabs=l; \ |
124 | char format[256]; \ | 124 | char format[256]; \ |
125 | snprintf(format,256,"%s%s%s",(num_tabs==1 ? "\t" : \ | 125 | snprintf(format,256,"%s%s%s",(num_tabs==1 ? "\t" : \ |
126 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))), \ | 126 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))), \ |
127 | m,PNG_STRING_NEWLINE); \ | 127 | m,PNG_STRING_NEWLINE); \ |
128 | fprintf(PNG_DEBUG_FILE,format,p1); \ | 128 | fprintf(PNG_DEBUG_FILE,format,p1); \ |
129 | } while (0) | 129 | } while (0) |
130 | # endif | 130 | # endif |
131 | # ifndef png_debug2 | 131 | # ifndef png_debug2 |
132 | # define png_debug2(l,m,p1,p2) \ | 132 | # define png_debug2(l,m,p1,p2) \ |
133 | do { \ | 133 | do { \ |
134 | int num_tabs=l; \ | 134 | int num_tabs=l; \ |
135 | char format[256]; \ | 135 | char format[256]; \ |
136 | snprintf(format,256,"%s%s%s",(num_tabs==1 ? "\t" : \ | 136 | snprintf(format,256,"%s%s%s",(num_tabs==1 ? "\t" : \ |
137 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))), \ | 137 | (num_tabs==2 ? "\t\t":(num_tabs>2 ? "\t\t\t":""))), \ |
138 | m,PNG_STRING_NEWLINE); \ | 138 | m,PNG_STRING_NEWLINE); \ |
139 | fprintf(PNG_DEBUG_FILE,format,p1,p2); \ | 139 | fprintf(PNG_DEBUG_FILE,format,p1,p2); \ |
140 | } while (0) | 140 | } while (0) |
141 | # endif | 141 | # endif |
142 | # endif /* __STDC __ */ | 142 | # endif /* __STDC __ */ |
143 | # endif /* (PNG_DEBUG > 1) */ | 143 | # endif /* (PNG_DEBUG > 1) */ |
144 | 144 | ||
145 | # endif /* _MSC_VER */ | 145 | # endif /* _MSC_VER */ |
146 | # endif /* (PNG_DEBUG > 0) */ | 146 | # endif /* (PNG_DEBUG > 0) */ |
147 | #endif /* PNG_DEBUG */ | 147 | #endif /* PNG_DEBUG */ |
148 | #ifndef png_debug | 148 | #ifndef png_debug |
149 | # define png_debug(l, m) ((void)0) | 149 | # define png_debug(l, m) ((void)0) |
150 | #endif | 150 | #endif |
151 | #ifndef png_debug1 | 151 | #ifndef png_debug1 |
152 | # define png_debug1(l, m, p1) ((void)0) | 152 | # define png_debug1(l, m, p1) ((void)0) |
153 | #endif | 153 | #endif |
154 | #ifndef png_debug2 | 154 | #ifndef png_debug2 |
155 | # define png_debug2(l, m, p1, p2) ((void)0) | 155 | # define png_debug2(l, m, p1, p2) ((void)0) |
156 | #endif | 156 | #endif |
157 | #endif /* PNGDEBUG_H */ | 157 | #endif /* PNGDEBUG_H */ |