MCPcopy Create free account
hub / github.com/crosire/reshade / QueryInterface

Method QueryInterface

source/dxgi/dxgi_adapter.cpp:73–94  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

71}
72
73HRESULT STDMETHODCALLTYPE DXGIAdapter::QueryInterface(REFIID riid, void **ppvObj)
74{
75 if (ppvObj == nullptr)
76 return E_POINTER;
77
78 if (check_and_upgrade_interface(riid))
79 {
80 AddRef();
81 *ppvObj = this;
82 return S_OK;
83 }
84
85 // Interface ID to query the original object from a proxy object
86 if (riid == IID_UnwrappedObject)
87 {
88 _orig->AddRef();
89 *ppvObj = _orig;
90 return S_OK;
91 }
92
93 return _orig->QueryInterface(riid, ppvObj);
94}
95ULONG STDMETHODCALLTYPE DXGIAdapter::AddRef()
96{
97 _orig->AddRef();

Callers 2

GetParentMethod · 0.45

Calls 1

AddRefMethod · 0.45

Tested by

no test coverage detected