Disable autocrlf for Visual Studio project files.
[mesa.git] / src / mesa / drivers / d3d / DEBUG.H
1 /*===========================================================================*/
2 /* */
3 /* Mesa-3.0 DirectX 6 Driver */
4 /* */
5 /* By Leigh McRae */
6 /* */
7 /* http://www.altsoftware.com/ */
8 /* */
9 /* Copyright (c) 1999-1998 alt.software inc. All Rights Reserved */
10 /*===========================================================================*/
11 #ifndef _DEBUG_H
12 #define _DEBUG_H
13
14 #ifdef __cplusplus
15 extern "C" {
16 #endif
17
18 /*===========================================================================*/
19 /* Includes. */
20 /*===========================================================================*/
21 #include <stdio.h>
22 #include <string.h>
23 #include <ddraw.h>
24 #include <d3d.h>
25 #include "D3DShared.h"
26 /*===========================================================================*/
27 /* Magic numbers. */
28 /*===========================================================================*/
29 /*===========================================================================*/
30 /* Macros defines. */
31 /*===========================================================================*/
32 #define DBG_FUNC 0x00000001
33 #define DBG_STATES 0x00000002
34
35 #define DBG_CNTX_INFO 0x00000010
36 #define DBG_CNTX_WARN 0x00000020
37 #define DBG_CNTX_PROFILE 0x00000040
38 #define DBG_CNTX_ERROR 0x00000080
39 #define DBG_CNTX_ALL 0x000000F0
40
41 #define DBG_PRIM_INFO 0x00000100
42 #define DBG_PRIM_WARN 0x00000200
43 #define DBG_PRIM_PROFILE 0x00000400
44 #define DBG_PRIM_ERROR 0x00000800
45 #define DBG_PRIM_ALL 0x00000F00
46
47 #define DBG_TXT_INFO 0x00001000
48 #define DBG_TXT_WARN 0x00002000
49 #define DBG_TXT_PROFILE 0x00004000
50 #define DBG_TXT_ERROR 0x00008000
51 #define DBG_TXT_ALL 0x0000F000
52
53 #define DBG_ALL_INFO 0x11111110
54 #define DBG_ALL_WARN 0x22222220
55 #define DBG_ALL_PROFILE 0x44444440
56 #define DBG_ALL_ERROR 0x88888880
57 #define DBG_ALL 0xFFFFFFFF
58
59 #ifdef D3D_DEBUG
60 # define DPF(arg) DebugPrint arg
61 # define RIP(pH,msg,err) OutputDebugString(msg); \
62 OutputDebugString(err); \
63 OutputDebugString("\n"); \
64 FatalShutDown(pH)
65 #else
66 # define DPF(arg)
67 # define RIP(pH,msg,err) FatalShutDown(pH)
68 #endif
69 /*===========================================================================*/
70 /* Type defines. */
71 /*===========================================================================*/
72 /*===========================================================================*/
73 /* Function prototypes. */
74 /*===========================================================================*/
75 extern void ReadDBGEnv( void );
76 extern void _cdecl DebugPrint( int mask, char *pszFormat, ... );
77 extern void DebugPixelFormat( char *pszSurfaceName, DDPIXELFORMAT *pddpf );
78 /*===========================================================================*/
79 /* Global variables. */
80 /*===========================================================================*/
81 extern DWORD g_DBGMask;
82
83 #ifdef __cplusplus
84 }
85 #endif
86
87 #endif
88
89
90