mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2024-11-25 00:58:30 -05:00
Added process memory usage info.
This commit is contained in:
parent
3301da6ea3
commit
58f7676f7b
4 changed files with 18 additions and 2 deletions
|
@ -5053,10 +5053,14 @@ BX_PRAGMA_DIAGNOSTIC_POP();
|
||||||
char sharedSystem[16];
|
char sharedSystem[16];
|
||||||
bx::prettify(sharedSystem, BX_COUNTOF(sharedSystem), desc.SharedSystemMemory);
|
bx::prettify(sharedSystem, BX_COUNTOF(sharedSystem), desc.SharedSystemMemory);
|
||||||
|
|
||||||
tvm.printf(0, pos++, 0x8f, " Memory: %s (video), %s (system), %s (shared)"
|
char processMemoryUsed[16];
|
||||||
|
bx::prettify(processMemoryUsed, BX_COUNTOF(processMemoryUsed), bx::getProcessMemoryUsed() );
|
||||||
|
|
||||||
|
tvm.printf(0, pos++, 0x8f, " Memory: %s (video), %s (system), %s (shared), %s (process) "
|
||||||
, dedicatedVideo
|
, dedicatedVideo
|
||||||
, dedicatedSystem
|
, dedicatedSystem
|
||||||
, sharedSystem
|
, sharedSystem
|
||||||
|
, processMemoryUsed
|
||||||
);
|
);
|
||||||
|
|
||||||
pos = 10;
|
pos = 10;
|
||||||
|
|
|
@ -4805,10 +4805,14 @@ data.NumQualityLevels = 0;
|
||||||
char sharedSystem[16];
|
char sharedSystem[16];
|
||||||
bx::prettify(sharedSystem, BX_COUNTOF(sharedSystem), desc.SharedSystemMemory);
|
bx::prettify(sharedSystem, BX_COUNTOF(sharedSystem), desc.SharedSystemMemory);
|
||||||
|
|
||||||
tvm.printf(0, pos++, 0x8f, " Memory: %s (video), %s (system), %s (shared)"
|
char processMemoryUsed[16];
|
||||||
|
bx::prettify(processMemoryUsed, BX_COUNTOF(processMemoryUsed), bx::getProcessMemoryUsed() );
|
||||||
|
|
||||||
|
tvm.printf(0, pos++, 0x8f, " Memory: %s (video), %s (system), %s (shared), %s (process) "
|
||||||
, dedicatedVideo
|
, dedicatedVideo
|
||||||
, dedicatedSystem
|
, dedicatedSystem
|
||||||
, sharedSystem
|
, sharedSystem
|
||||||
|
, processMemoryUsed
|
||||||
);
|
);
|
||||||
|
|
||||||
DXGI_QUERY_VIDEO_MEMORY_INFO memInfo;
|
DXGI_QUERY_VIDEO_MEMORY_INFO memInfo;
|
||||||
|
|
|
@ -3750,6 +3750,10 @@ namespace bgfx { namespace d3d9
|
||||||
const D3DADAPTER_IDENTIFIER9& identifier = m_identifier;
|
const D3DADAPTER_IDENTIFIER9& identifier = m_identifier;
|
||||||
tvm.printf(0, pos++, 0x8f, " Device: %s (%s)", identifier.Description, identifier.Driver);
|
tvm.printf(0, pos++, 0x8f, " Device: %s (%s)", identifier.Description, identifier.Driver);
|
||||||
|
|
||||||
|
char processMemoryUsed[16];
|
||||||
|
bx::prettify(processMemoryUsed, BX_COUNTOF(processMemoryUsed), bx::getProcessMemoryUsed() );
|
||||||
|
tvm.printf(0, pos++, 0x8f, " Memory: %s (process) ", processMemoryUsed);
|
||||||
|
|
||||||
pos = 10;
|
pos = 10;
|
||||||
tvm.printf(10, pos++, 0x8e, " Frame: %7.3f, % 7.3f \x1f, % 7.3f \x1e [ms] / % 6.2f FPS "
|
tvm.printf(10, pos++, 0x8e, " Frame: %7.3f, % 7.3f \x1f, % 7.3f \x1e [ms] / % 6.2f FPS "
|
||||||
, double(frameTime)*toMs
|
, double(frameTime)*toMs
|
||||||
|
|
|
@ -6001,6 +6001,10 @@ namespace bgfx { namespace gl
|
||||||
tvm.printf(0, pos++, 0x8f, " Version: %s ", m_version);
|
tvm.printf(0, pos++, 0x8f, " Version: %s ", m_version);
|
||||||
tvm.printf(0, pos++, 0x8f, " GLSL version: %s ", m_glslVersion);
|
tvm.printf(0, pos++, 0x8f, " GLSL version: %s ", m_glslVersion);
|
||||||
|
|
||||||
|
char processMemoryUsed[16];
|
||||||
|
bx::prettify(processMemoryUsed, BX_COUNTOF(processMemoryUsed), bx::getProcessMemoryUsed() );
|
||||||
|
tvm.printf(0, pos++, 0x8f, " Memory: %s (process) ", processMemoryUsed);
|
||||||
|
|
||||||
pos = 10;
|
pos = 10;
|
||||||
tvm.printf(10, pos++, 0x8e, " Frame CPU: %7.3f, % 7.3f \x1f, % 7.3f \x1e [ms] / % 6.2f FPS "
|
tvm.printf(10, pos++, 0x8e, " Frame CPU: %7.3f, % 7.3f \x1f, % 7.3f \x1e [ms] / % 6.2f FPS "
|
||||||
, double(frameTime)*toMs
|
, double(frameTime)*toMs
|
||||||
|
|
Loading…
Reference in a new issue