port from perforce
This commit is contained in:
17
evoke-64k/ev10/ice/src/debug.h
Normal file
17
evoke-64k/ev10/ice/src/debug.h
Normal file
@@ -0,0 +1,17 @@
|
||||
#pragma once
|
||||
|
||||
#ifdef _DEBUG
|
||||
#define COMPILE_SHADER(entry, profile, buffer) \
|
||||
{ \
|
||||
ID3DXBuffer* errors = 0; \
|
||||
D3DXCompileShader(shaderCode, shaderSize, 0, 0, entry, profile, D3DXSHADER_DEBUG, buffer, &errors, 0); \
|
||||
if (errors != 0) \
|
||||
{ \
|
||||
OutputDebugStringA((char*)errors->GetBufferPointer()); \
|
||||
errors->Release(); \
|
||||
DebugBreak(); \
|
||||
} \
|
||||
}
|
||||
#else
|
||||
#define COMPILE_SHADER(entry, profile, buffer) D3DXCompileShader(shaderCode, shaderSize, 0, 0, entry, profile, 0, buffer, 0, 0);
|
||||
#endif
|
||||
Reference in New Issue
Block a user