mirror of
https://github.com/blawar/GLideN64.git
synced 2024-07-07 03:13:49 +00:00
Add debugPrint function
This commit is contained in:
parent
1e2e2e980b
commit
aaf5a56d6a
13
Debug.h
13
Debug.h
|
@ -1,6 +1,8 @@
|
|||
#if !defined( DEBUG_H ) && defined( USE_DEBUG )
|
||||
#ifndef DEBUG_H
|
||||
#define DEBUG_H
|
||||
|
||||
#ifdef USE_DEBUG
|
||||
|
||||
#include "Types.h"
|
||||
#include <stdio.h>
|
||||
|
||||
|
@ -38,7 +40,14 @@ void DebugRSPState( u32 pci, u32 pc, u32 cmd, u32 w0, u32 w1 );
|
|||
void DebugMsg( u16 type, const char * format, ... );
|
||||
void StartDump( char *filename );
|
||||
void EndDump();
|
||||
#else
|
||||
|
||||
#else // USE_DEBUG
|
||||
|
||||
#define DebugMsg(A, ...)
|
||||
#define DebugRSPState(A, ...)
|
||||
|
||||
#endif // USE_DEBUG
|
||||
|
||||
void debugPrint(const char * format, ...);
|
||||
|
||||
#endif // DEBUG_H
|
||||
|
|
|
@ -312,3 +312,17 @@ void DebugMsg( u16 type, const char * format, ... )
|
|||
}
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef OS_WINDOWS
|
||||
#include "GLideN64_Windows.h"
|
||||
#include <stdio.h>
|
||||
|
||||
void debugPrint(const char * format, ...)
|
||||
{
|
||||
char text[256];
|
||||
va_list va;
|
||||
va_start(va, format);
|
||||
vsprintf(text, format, va);
|
||||
OutputDebugString(text);
|
||||
}
|
||||
#endif
|
Loading…
Reference in New Issue
Block a user