Commit f7588eb6 authored by bitplane's avatar bitplane

removed the floating point stencil buffers after complaint that they cause crashes

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@2284 dfc29bdd-3216-0410-991c-e03cc46cb475
parent a4d0e89f
...@@ -303,11 +303,6 @@ bool CD3D9Driver::initDriver(const core::dimension2d<u32>& screenSize, ...@@ -303,11 +303,6 @@ bool CD3D9Driver::initDriver(const core::dimension2d<u32>& screenSize,
// check stencil buffer compatibility // check stencil buffer compatibility
if (StencilBuffer) if (StencilBuffer)
{
present.AutoDepthStencilFormat = D3DFMT_D24FS8;
if(FAILED(pID3D->CheckDeviceFormat(adapter, devtype,
present.BackBufferFormat, D3DUSAGE_DEPTHSTENCIL,
D3DRTYPE_SURFACE, present.AutoDepthStencilFormat)))
{ {
present.AutoDepthStencilFormat = D3DFMT_D24S8; present.AutoDepthStencilFormat = D3DFMT_D24S8;
if(FAILED(pID3D->CheckDeviceFormat(adapter, devtype, if(FAILED(pID3D->CheckDeviceFormat(adapter, devtype,
...@@ -329,7 +324,6 @@ bool CD3D9Driver::initDriver(const core::dimension2d<u32>& screenSize, ...@@ -329,7 +324,6 @@ bool CD3D9Driver::initDriver(const core::dimension2d<u32>& screenSize,
} }
} }
} }
}
else else
if(FAILED(pID3D->CheckDepthStencilMatch(adapter, devtype, if(FAILED(pID3D->CheckDepthStencilMatch(adapter, devtype,
present.BackBufferFormat, present.BackBufferFormat, present.AutoDepthStencilFormat))) present.BackBufferFormat, present.BackBufferFormat, present.AutoDepthStencilFormat)))
...@@ -340,11 +334,6 @@ bool CD3D9Driver::initDriver(const core::dimension2d<u32>& screenSize, ...@@ -340,11 +334,6 @@ bool CD3D9Driver::initDriver(const core::dimension2d<u32>& screenSize,
} }
// do not use else here to cope with flag change in previous block // do not use else here to cope with flag change in previous block
if (!StencilBuffer) if (!StencilBuffer)
{
present.AutoDepthStencilFormat = D3DFMT_D32F_LOCKABLE;
if(FAILED(pID3D->CheckDeviceFormat(adapter, devtype,
present.BackBufferFormat, D3DUSAGE_DEPTHSTENCIL,
D3DRTYPE_SURFACE, present.AutoDepthStencilFormat)))
{ {
present.AutoDepthStencilFormat = D3DFMT_D32; present.AutoDepthStencilFormat = D3DFMT_D32;
if(FAILED(pID3D->CheckDeviceFormat(adapter, devtype, if(FAILED(pID3D->CheckDeviceFormat(adapter, devtype,
...@@ -367,7 +356,6 @@ bool CD3D9Driver::initDriver(const core::dimension2d<u32>& screenSize, ...@@ -367,7 +356,6 @@ bool CD3D9Driver::initDriver(const core::dimension2d<u32>& screenSize,
} }
} }
} }
}
// create device // create device
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment