mirror of
https://github.com/doitsujin/dxvk.git
synced 2024-11-30 04:24:11 +01:00
[d3d10] Add GetD3D10ResourceFromView and GetD3D10Resource helpers
This commit is contained in:
parent
ccab8a56ee
commit
04fa062eba
@ -37,6 +37,33 @@ namespace dxvk {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void GetD3D10ResourceFromView(
|
||||||
|
ID3D11View* pSrcView,
|
||||||
|
ID3D10Resource** ppDstResource) {
|
||||||
|
Com<ID3D11Resource> d3d11Resource;
|
||||||
|
pSrcView->GetResource(&d3d11Resource);
|
||||||
|
GetD3D10Resource(d3d11Resource.ptr(), ppDstResource);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void GetD3D11ResourceFromView(
|
||||||
|
ID3D10View* pSrcView,
|
||||||
|
ID3D11Resource** ppDstResource) {
|
||||||
|
Com<ID3D10Resource> d3d10Resource;
|
||||||
|
pSrcView->GetResource(&d3d10Resource);
|
||||||
|
GetD3D11Resource(d3d10Resource.ptr(), ppDstResource);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void GetD3D10Resource(
|
||||||
|
ID3D11Resource* pSrcResource,
|
||||||
|
ID3D10Resource** ppDstResource) {
|
||||||
|
pSrcResource->QueryInterface(
|
||||||
|
__uuidof(ID3D10Resource),
|
||||||
|
reinterpret_cast<void**>(ppDstResource));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void GetD3D11Resource(
|
void GetD3D11Resource(
|
||||||
ID3D10Resource* pSrcResource,
|
ID3D10Resource* pSrcResource,
|
||||||
ID3D11Resource** ppDstResource) {
|
ID3D11Resource** ppDstResource) {
|
||||||
|
@ -15,6 +15,36 @@ namespace dxvk {
|
|||||||
UINT ConvertD3D10ResourceFlags(UINT MiscFlags);
|
UINT ConvertD3D10ResourceFlags(UINT MiscFlags);
|
||||||
UINT ConvertD3D11ResourceFlags(UINT MiscFlags);
|
UINT ConvertD3D11ResourceFlags(UINT MiscFlags);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* \brief Retrieves D3D10 resource from D3D11 view
|
||||||
|
*
|
||||||
|
* \param [in] pSrcView The D3D11 resource view
|
||||||
|
* \param [out] ppDstResource The D3D10 resource
|
||||||
|
*/
|
||||||
|
void GetD3D10ResourceFromView(
|
||||||
|
ID3D11View* pSrcView,
|
||||||
|
ID3D10Resource** ppDstResource);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* \brief Retrieves D3D11 resource from D3D10 view
|
||||||
|
*
|
||||||
|
* \param [in] pSrcView The D3D10 resource view
|
||||||
|
* \param [out] ppDstResource The D3D11 resource
|
||||||
|
*/
|
||||||
|
void GetD3D11ResourceFromView(
|
||||||
|
ID3D10View* pSrcView,
|
||||||
|
ID3D11Resource** ppDstResource);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* \brief Retrieves D3D10 resource from D3D11 resource
|
||||||
|
*
|
||||||
|
* \param [in] pSrcResource The D3D11 resource
|
||||||
|
* \param [out] ppDstResource The D3D10 resource
|
||||||
|
*/
|
||||||
|
void GetD3D10Resource(
|
||||||
|
ID3D11Resource* pSrcResource,
|
||||||
|
ID3D10Resource** ppDstResource);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief Retrieves D3D11 resource from D3D10 resource
|
* \brief Retrieves D3D11 resource from D3D10 resource
|
||||||
*
|
*
|
||||||
|
Loading…
Reference in New Issue
Block a user