mirror of
https://github.com/EduApps-CDG/OpenDX
synced 2024-12-30 09:45:37 +01:00
Since we are doing this for UAVs already, we should be doing this for all view classes in order to account for the minor differences between all of them.
46 lines
1.3 KiB
C++
46 lines
1.3 KiB
C++
#include "d3d11_device.h"
|
|
#include "d3d11_view_dsv.h"
|
|
|
|
namespace dxvk {
|
|
|
|
D3D11DepthStencilView::D3D11DepthStencilView(
|
|
D3D11Device* device,
|
|
ID3D11Resource* resource,
|
|
const D3D11_DEPTH_STENCIL_VIEW_DESC& desc,
|
|
const Rc<DxvkImageView>& view)
|
|
: m_device(device), m_resource(resource),
|
|
m_desc(desc), m_view(view) { }
|
|
|
|
|
|
D3D11DepthStencilView::~D3D11DepthStencilView() {
|
|
|
|
}
|
|
|
|
|
|
HRESULT STDMETHODCALLTYPE D3D11DepthStencilView::QueryInterface(REFIID riid, void** ppvObject) {
|
|
COM_QUERY_IFACE(riid, ppvObject, IUnknown);
|
|
COM_QUERY_IFACE(riid, ppvObject, ID3D11DeviceChild);
|
|
COM_QUERY_IFACE(riid, ppvObject, ID3D11View);
|
|
COM_QUERY_IFACE(riid, ppvObject, ID3D11DepthStencilView);
|
|
|
|
Logger::warn("D3D11DepthStencilView::QueryInterface: Unknown interface query");
|
|
return E_NOINTERFACE;
|
|
}
|
|
|
|
|
|
void STDMETHODCALLTYPE D3D11DepthStencilView::GetDevice(ID3D11Device** ppDevice) {
|
|
*ppDevice = m_device.ref();
|
|
}
|
|
|
|
|
|
void STDMETHODCALLTYPE D3D11DepthStencilView::GetResource(ID3D11Resource** ppResource) {
|
|
*ppResource = m_resource.ref();
|
|
}
|
|
|
|
|
|
void STDMETHODCALLTYPE D3D11DepthStencilView::GetDesc(D3D11_DEPTH_STENCIL_VIEW_DESC* pDesc) {
|
|
*pDesc = m_desc;
|
|
}
|
|
|
|
}
|