Browse Source

Fixed IFH debug flag.

Branimir Karadžić 9 years ago
parent
commit
14dbb67320

+ 2 - 1
examples/common/entry/entry.cpp

@@ -353,6 +353,7 @@ BX_PRAGMA_DIAGNOSTIC_POP();
 		{ entry::Key::KeyF,         entry::Modifier::RightCtrl, 1, NULL, "graphics fullscreen"               },
 		{ entry::Key::KeyF,         entry::Modifier::RightCtrl, 1, NULL, "graphics fullscreen"               },
 		{ entry::Key::Return,       entry::Modifier::RightAlt,  1, NULL, "graphics fullscreen"               },
 		{ entry::Key::Return,       entry::Modifier::RightAlt,  1, NULL, "graphics fullscreen"               },
 		{ entry::Key::F1,           entry::Modifier::None,      1, NULL, "graphics stats"                    },
 		{ entry::Key::F1,           entry::Modifier::None,      1, NULL, "graphics stats"                    },
+		{ entry::Key::F1,           entry::Modifier::LeftCtrl,  1, NULL, "graphics ifh"                      },
 		{ entry::Key::GamepadStart, entry::Modifier::None,      1, NULL, "graphics stats"                    },
 		{ entry::Key::GamepadStart, entry::Modifier::None,      1, NULL, "graphics stats"                    },
 		{ entry::Key::F1,           entry::Modifier::LeftShift, 1, NULL, "graphics stats 0\ngraphics text 0" },
 		{ entry::Key::F1,           entry::Modifier::LeftShift, 1, NULL, "graphics stats 0\ngraphics text 0" },
 		{ entry::Key::F3,           entry::Modifier::None,      1, NULL, "graphics wireframe"                },
 		{ entry::Key::F3,           entry::Modifier::None,      1, NULL, "graphics wireframe"                },
@@ -365,7 +366,7 @@ BX_PRAGMA_DIAGNOSTIC_POP();
 		{ entry::Key::F10,          entry::Modifier::None,      1, NULL, "graphics hidpi"                    },
 		{ entry::Key::F10,          entry::Modifier::None,      1, NULL, "graphics hidpi"                    },
 		{ entry::Key::Print,        entry::Modifier::None,      1, NULL, "graphics screenshot"               },
 		{ entry::Key::Print,        entry::Modifier::None,      1, NULL, "graphics screenshot"               },
 		{ entry::Key::KeyP,         entry::Modifier::LeftCtrl,  1, NULL, "graphics screenshot"               },
 		{ entry::Key::KeyP,         entry::Modifier::LeftCtrl,  1, NULL, "graphics screenshot"               },
-		
+
 		INPUT_BINDING_END
 		INPUT_BINDING_END
 	};
 	};
 
 

+ 1 - 1
examples/common/entry/entry_p.h

@@ -14,7 +14,7 @@
 #include <string.h> // memcpy
 #include <string.h> // memcpy
 
 
 #ifndef ENTRY_CONFIG_USE_NOOP
 #ifndef ENTRY_CONFIG_USE_NOOP
-#	define ENTRY_CONFIG_USE_NOOP (BX_PLATFORM_QNX || BX_PLATFORM_PS4)
+#	define ENTRY_CONFIG_USE_NOOP (BX_PLATFORM_QNX)
 #endif // ENTRY_CONFIG_USE_NOOP
 #endif // ENTRY_CONFIG_USE_NOOP
 
 
 #ifndef ENTRY_CONFIG_USE_SDL
 #ifndef ENTRY_CONFIG_USE_SDL

+ 1 - 0
src/renderer_d3d11.cpp

@@ -6195,6 +6195,7 @@ BX_PRAGMA_DIAGNOSTIC_POP();
 		{
 		{
 			PIX_BEGINEVENT(D3DCOLOR_FRAME, L"debugstats");
 			PIX_BEGINEVENT(D3DCOLOR_FRAME, L"debugstats");
 
 
+			m_needPresent = true;
 			TextVideoMem& tvm = m_textVideoMem;
 			TextVideoMem& tvm = m_textVideoMem;
 
 
 			static int64_t next = now;
 			static int64_t next = now;

+ 2 - 1
src/renderer_d3d12.cpp

@@ -5489,10 +5489,11 @@ data.NumQualityLevels = 0;
 		perfStats.numCompute    = statsKeyType[1];
 		perfStats.numCompute    = statsKeyType[1];
 		perfStats.maxGpuLatency = maxGpuLatency;
 		perfStats.maxGpuLatency = maxGpuLatency;
 
 
-		if (_render->m_debug & (BGFX_DEBUG_IFH | BGFX_DEBUG_STATS) )
+		if (_render->m_debug & (BGFX_DEBUG_IFH|BGFX_DEBUG_STATS) )
 		{
 		{
 //			PIX_BEGINEVENT(D3DCOLOR_FRAME, L"debugstats");
 //			PIX_BEGINEVENT(D3DCOLOR_FRAME, L"debugstats");
 
 
+//			m_needPresent = true;
 			TextVideoMem& tvm = m_textVideoMem;
 			TextVideoMem& tvm = m_textVideoMem;
 
 
 			static int64_t next = now;
 			static int64_t next = now;

+ 1 - 0
src/renderer_d3d9.cpp

@@ -4272,6 +4272,7 @@ namespace bgfx { namespace d3d9
 		{
 		{
 			PIX_BEGINEVENT(D3DCOLOR_FRAME, L"debugstats");
 			PIX_BEGINEVENT(D3DCOLOR_FRAME, L"debugstats");
 
 
+			m_needPresent = true;
 			TextVideoMem& tvm = m_textVideoMem;
 			TextVideoMem& tvm = m_textVideoMem;
 
 
 			static int64_t next = now;
 			static int64_t next = now;

+ 1 - 0
src/renderer_gl.cpp

@@ -7320,6 +7320,7 @@ namespace bgfx { namespace gl
 
 
 		if (_render->m_debug & (BGFX_DEBUG_IFH|BGFX_DEBUG_STATS) )
 		if (_render->m_debug & (BGFX_DEBUG_IFH|BGFX_DEBUG_STATS) )
 		{
 		{
+			m_needPresent = true;
 			TextVideoMem& tvm = m_textVideoMem;
 			TextVideoMem& tvm = m_textVideoMem;
 
 
 			static int64_t next = now;
 			static int64_t next = now;

+ 2 - 1
src/renderer_vk.cpp

@@ -4435,10 +4435,11 @@ BX_UNUSED(presentMin, presentMax);
 //		perfStats.numCompute    = statsKeyType[1];
 //		perfStats.numCompute    = statsKeyType[1];
 //		perfStats.maxGpuLatency = maxGpuLatency;
 //		perfStats.maxGpuLatency = maxGpuLatency;
 
 
-		if (_render->m_debug & (BGFX_DEBUG_IFH | BGFX_DEBUG_STATS) )
+		if (_render->m_debug & (BGFX_DEBUG_IFH|BGFX_DEBUG_STATS) )
 		{
 		{
 //			PIX_BEGINEVENT(D3DCOLOR_RGBA(0x40, 0x40, 0x40, 0xff), L"debugstats");
 //			PIX_BEGINEVENT(D3DCOLOR_RGBA(0x40, 0x40, 0x40, 0xff), L"debugstats");
 
 
+//			m_needPresent = true;
 			TextVideoMem& tvm = m_textVideoMem;
 			TextVideoMem& tvm = m_textVideoMem;
 
 
 			static int64_t next = now;
 			static int64_t next = now;