mirror of
https://git.rip/DMCA_FUCKER/re3.git
synced 2024-12-23 03:40:01 +00:00
make debug render groups optional
This commit is contained in:
parent
111ccf5d34
commit
b88cf7b939
|
@ -1072,6 +1072,7 @@ extern bool gbRenderWorld2;
|
||||||
DebugMenuAddVarBool8("Debug", "Show Timebars", &gbShowTimebars, nil);
|
DebugMenuAddVarBool8("Debug", "Show Timebars", &gbShowTimebars, nil);
|
||||||
#endif
|
#endif
|
||||||
#ifndef FINAL
|
#ifndef FINAL
|
||||||
|
DebugMenuAddVarBool8("Debug", "Use debug render groups", &bDebugRenderGroups, nil);
|
||||||
DebugMenuAddVarBool8("Debug", "Print Memory Usage", &gbPrintMemoryUsage, nil);
|
DebugMenuAddVarBool8("Debug", "Print Memory Usage", &gbPrintMemoryUsage, nil);
|
||||||
#ifdef USE_CUSTOM_ALLOCATOR
|
#ifdef USE_CUSTOM_ALLOCATOR
|
||||||
DebugMenuAddCmd("Debug", "Parse Heap", ParseHeap);
|
DebugMenuAddCmd("Debug", "Parse Heap", ParseHeap);
|
||||||
|
|
|
@ -9,6 +9,7 @@
|
||||||
#endif
|
#endif
|
||||||
#ifndef FINAL
|
#ifndef FINAL
|
||||||
RtCharset *debugCharset;
|
RtCharset *debugCharset;
|
||||||
|
bool bDebugRenderGroups;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef PS2_ALPHA_TEST
|
#ifdef PS2_ALPHA_TEST
|
||||||
|
@ -106,6 +107,8 @@ SetCullMode(uint32 mode)
|
||||||
void
|
void
|
||||||
PushRendergroup(const char *name)
|
PushRendergroup(const char *name)
|
||||||
{
|
{
|
||||||
|
if(!bDebugRenderGroups)
|
||||||
|
return;
|
||||||
#if defined(RW_OPENGL)
|
#if defined(RW_OPENGL)
|
||||||
if(GLAD_GL_KHR_debug)
|
if(GLAD_GL_KHR_debug)
|
||||||
glPushDebugGroup(GL_DEBUG_SOURCE_APPLICATION, 0, -1, name);
|
glPushDebugGroup(GL_DEBUG_SOURCE_APPLICATION, 0, -1, name);
|
||||||
|
@ -119,6 +122,8 @@ PushRendergroup(const char *name)
|
||||||
void
|
void
|
||||||
PopRendergroup(void)
|
PopRendergroup(void)
|
||||||
{
|
{
|
||||||
|
if(!bDebugRenderGroups)
|
||||||
|
return;
|
||||||
#if defined(RW_OPENGL)
|
#if defined(RW_OPENGL)
|
||||||
if(GLAD_GL_KHR_debug)
|
if(GLAD_GL_KHR_debug)
|
||||||
glPopDebugGroup();
|
glPopDebugGroup();
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
extern bool bDebugRenderGroups;
|
||||||
extern bool gPS2alphaTest;
|
extern bool gPS2alphaTest;
|
||||||
extern bool gBackfaceCulling;
|
extern bool gBackfaceCulling;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue