mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-08-09 01:28:57 +00:00
Dependency cleanup in DX9.
Dynamically load a d3dx9 dll at runtime (I tested Dolphin with the first d3dx9 dll and it even worked fine there). Should fix the flood of users asking why they can't select the DX9 plugin :P Compilers should be able to stop bundling cgD3D9.dll now. Minor changes in DX11. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5890 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
25efe443ea
commit
5abed9d5a4
9 changed files with 127 additions and 43 deletions
|
@ -66,7 +66,7 @@ D3DTexture2D* D3DTexture2D::Create(unsigned int width, unsigned int height, D3D1
|
|||
}
|
||||
|
||||
D3DTexture2D* ret = new D3DTexture2D(pTexture, bind);
|
||||
pTexture->Release();
|
||||
SAFE_RELEASE(pTexture);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -77,7 +77,7 @@ void D3DTexture2D::AddRef()
|
|||
|
||||
UINT D3DTexture2D::Release()
|
||||
{
|
||||
ref--;
|
||||
--ref;
|
||||
if (ref == 0)
|
||||
{
|
||||
delete this;
|
||||
|
@ -106,8 +106,8 @@ D3DTexture2D::D3DTexture2D(ID3D11Texture2D* texptr, D3D11_BIND_FLAG bind,
|
|||
|
||||
D3DTexture2D::~D3DTexture2D()
|
||||
{
|
||||
if (srv) srv->Release();
|
||||
if (rtv) rtv->Release();
|
||||
if (dsv) dsv->Release();
|
||||
tex->Release();
|
||||
SAFE_RELEASE(srv);
|
||||
SAFE_RELEASE(rtv);
|
||||
SAFE_RELEASE(dsv);
|
||||
SAFE_RELEASE(tex);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue