summaryrefslogtreecommitdiff
path: root/src/win95/dxlog.h
diff options
context:
space:
mode:
authorSteven Fuller <relnev@icculus.org>2001-07-01 00:55:22 +0000
committerPatryk Obara <dreamer.tan@gmail.com>2019-08-20 02:09:04 +0200
commit2186d5f3f95cd74a070a490d899291648d58667a (patch)
tree55241a1afa3e1a22e0b6593a8dead0b703800f44 /src/win95/dxlog.h
parent218ca90543758a20ac326e444ca0643174ca7384 (diff)
Initial revision
Diffstat (limited to 'src/win95/dxlog.h')
-rw-r--r--src/win95/dxlog.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/src/win95/dxlog.h b/src/win95/dxlog.h
new file mode 100644
index 0000000..d67b57c
--- /dev/null
+++ b/src/win95/dxlog.h
@@ -0,0 +1,37 @@
+#ifndef _included_dxlog_h_
+#define _included_dxlog_h_
+
+#include "system.h"
+#include "ddraw.h"
+#include "d3d.h"
+#include "d3drm.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#if debug
+
+void dx_err_log(HRESULT error, int line, char const * file);
+void dx_str_log(char const * str, int line, char const * file);
+void dx_line_log(int line, char const * file);
+void dx_strf_log(char const * fmt, ...);
+
+#define LOGDXERR(error) dx_err_log(error,__LINE__,__FILE__)
+#define LOGDXSTR(str) dx_str_log(str,__LINE__,__FILE__)
+#define LOGDXFMT(args) (dx_line_log(__LINE__,__FILE__),dx_strf_log args)
+
+#else
+
+#define LOGDXERR(error) (void)0
+#define LOGDXSTR(str) (void)0
+#define LOGDXFMT(args) (void)0
+
+#endif
+
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* ! _included_dxlog_h_ */