mirror of
https://github.com/libretro/ppsspp.git
synced 2025-02-05 08:36:17 +00:00
d3d9: Check actual FBO format for INTZ support.
This commit is contained in:
parent
4568affe4d
commit
49c353f40c
@ -51,8 +51,11 @@ void fbo_init(LPDIRECT3D9 d3d) {
|
||||
if (d3d) {
|
||||
D3DDISPLAYMODE displayMode;
|
||||
d3d->GetAdapterDisplayMode(D3DADAPTER_DEFAULT, &displayMode);
|
||||
HRESULT intzFormat = d3d->CheckDeviceFormat(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, displayMode.Format, D3DUSAGE_DEPTHSTENCIL, D3DRTYPE_TEXTURE, FOURCC_INTZ);
|
||||
supportsINTZ = SUCCEEDED(intzFormat);
|
||||
|
||||
// To be safe, make sure both the display format and the FBO format support INTZ.
|
||||
HRESULT displayINTZ = d3d->CheckDeviceFormat(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, displayMode.Format, D3DUSAGE_DEPTHSTENCIL, D3DRTYPE_TEXTURE, FOURCC_INTZ);
|
||||
HRESULT fboINTZ = d3d->CheckDeviceFormat(D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, D3DFMT_A8R8G8B8, D3DUSAGE_DEPTHSTENCIL, D3DRTYPE_TEXTURE, FOURCC_INTZ);
|
||||
supportsINTZ = SUCCEEDED(displayINTZ) && SUCCEEDED(fboINTZ);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user