debug.h
上传用户:center1979
上传日期:2022-07-26
资源大小:50633k
文件大小:1k
源码类别:

OpenGL

开发平台:

Visual C++

  1. // debug.h
  2. //
  3. // Copyright (C) 2001, Chris Laurel <claurel@shatters.net>
  4. //
  5. // This program is free software; you can redistribute it and/or
  6. // modify it under the terms of the GNU General Public License
  7. // as published by the Free Software Foundation; either version 2
  8. // of the License, or (at your option) any later version.
  9. #ifndef _DEBUG_H_
  10. #define _DEBUG_H_
  11. // Define the DPRINTF macro; g++ supports macros with variable
  12. // length arguments, so we'll use those when we can.
  13. #ifndef DPRINTF
  14. #ifdef __GNUC__
  15. #ifndef DEBUG
  16. #define DPRINTF(level, args...)
  17. #else
  18. #define DPRINTF(level, args...) DebugPrint(level, args)
  19. extern void DebugPrint(int level, char *format, ...);
  20. #endif
  21. #else
  22. #ifndef _DEBUG
  23. #define DPRINTF //
  24. #else
  25. #define DPRINTF DebugPrint
  26. extern void DebugPrint(int level, char *format, ...);
  27. #endif
  28. #endif // __GNUC__
  29. #endif // DPRINTF
  30. extern void SetDebugVerbosity(int);
  31. extern int GetDebugVerbosity();
  32. #endif // _DEBUG_H_