MCPcopy Create free account
hub / github.com/NVIDIA-RTX/RTXPT / QueryVideoMemoryInfo

Method QueryVideoMemoryInfo

Rtxpt/SampleCommon/SampleBaseApp.cpp:142–156  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

140}
141
142bool SampleBaseApp::QueryVideoMemoryInfo(uint64_t& outBudget, uint64_t& outCurrentUsage, uint64_t& outAvailableForReservation, uint64_t& outCurrentReservation)
143{
144#if RTXPT_ENABLE_VIDEO_MEMORY_INFO // & DX12
145 DXGI_QUERY_VIDEO_MEMORY_INFO info;
146 if (FAILED(m_d3dAdapter->QueryVideoMemoryInfo(0, DXGI_MEMORY_SEGMENT_GROUP_LOCAL, &info)))
147 return false;
148 outBudget = info.Budget;
149 outCurrentUsage = info.CurrentUsage;
150 outAvailableForReservation = info.AvailableForReservation;
151 outCurrentReservation = info.CurrentReservation;
152 return true;
153#else
154 return false;
155#endif
156}
157
158void SampleBaseApp::End()
159{

Callers 1

buildUIMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected