1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2024-12-02 01:24:11 +01:00

[d3d11] Implement ID3D11Device4

This commit is contained in:
Philip Rebohle 2019-09-16 16:26:03 +02:00
parent 3ba541fde6
commit 56daf44d4c
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
2 changed files with 31 additions and 2 deletions

View File

@ -1765,6 +1765,27 @@ namespace dxvk {
}
HRESULT STDMETHODCALLTYPE D3D11Device::RegisterDeviceRemovedEvent(
HANDLE hEvent,
DWORD* pdwCookie) {
static bool s_errorShown = false;
if (!std::exchange(s_errorShown, true))
Logger::err("D3D11Device::RegisterDeviceRemovedEvent: Not implemented");
return E_NOTIMPL;
}
void STDMETHODCALLTYPE D3D11Device::UnregisterDeviceRemoved(
DWORD dwCookie) {
static bool s_errorShown = false;
if (!std::exchange(s_errorShown, true))
Logger::err("D3D11Device::UnregisterDeviceRemovedEvent: Not implemented");
}
DXGI_VK_FORMAT_INFO D3D11Device::LookupFormat(
DXGI_FORMAT Format,
DXGI_VK_FORMAT_MODE Mode) const {
@ -2356,7 +2377,8 @@ namespace dxvk {
if (riid == __uuidof(ID3D11Device)
|| riid == __uuidof(ID3D11Device1)
|| riid == __uuidof(ID3D11Device2)
|| riid == __uuidof(ID3D11Device3)) {
|| riid == __uuidof(ID3D11Device3)
|| riid == __uuidof(ID3D11Device4)) {
*ppvObject = ref(&m_d3d11Device);
return S_OK;
}

View File

@ -45,7 +45,7 @@ namespace dxvk {
* Implements the ID3D11Device interfaces
* as part of a \ref D3D11DeviceContainer.
*/
class D3D11Device final : public ID3D11Device3 {
class D3D11Device final : public ID3D11Device4 {
/// Maximum number of resource init commands per command buffer
constexpr static uint64_t InitCommandThreshold = 50;
public:
@ -367,6 +367,13 @@ namespace dxvk {
UINT FirstSubresourceTilingToGet,
D3D11_SUBRESOURCE_TILING* pSubresourceTilingsForNonPackedMips);
HRESULT STDMETHODCALLTYPE RegisterDeviceRemovedEvent(
HANDLE hEvent,
DWORD* pdwCookie);
void STDMETHODCALLTYPE UnregisterDeviceRemoved(
DWORD dwCookie);
Rc<DxvkDevice> GetDXVKDevice() {
return m_dxvkDevice;
}