MCPcopy Create free account
hub / github.com/GameTechDev/PresentMon / Map

Method Map

IntelPresentMon/FlashInjectorLibrary/Generated/API_DXGI.cpp:367–394  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

365 }
366
367 HRESULT IDXGISurface_Wrapper::Map(DXGI_MAPPED_RECT* pLockedRect, UINT MapFlags)
368 {
369 HRESULT result = {};
370 auto& ctx = Context::GetInstance();
371 auto callScope = ctx.IncrementCallScope();
372 if (callScope == 1)
373 {
374 bool skipCall = PreCall<API_IDXGISURFACE_MAP>::Run(result, this, pLockedRect, MapFlags);
375 if (skipCall)
376 {
377 ctx.DecrementCallScope();
378 return result;
379 }
380
381 result = GetWrappedObjectAs<IDXGISurface>()->Map(
382 pLockedRect,
383 MapFlags
384 );
385
386 PostCall<API_IDXGISURFACE_MAP>::Run(result, this, pLockedRect, MapFlags);
387 }
388 else
389 {
390 result = GetWrappedObjectAs<IDXGISurface>()->Map(pLockedRect, MapFlags);
391 }
392 ctx.DecrementCallScope();
393 return result;
394 }
395
396 HRESULT IDXGISurface_Wrapper::Unmap()
397 {

Callers 1

StartFrameMethod · 0.80

Calls 2

IncrementCallScopeMethod · 0.80
DecrementCallScopeMethod · 0.80

Tested by

no test coverage detected