ddraw: Do not request 3D-usages for DDRAW_NO3D surfaces.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
a470045506
commit
8ac639d25c
|
@ -6152,12 +6152,15 @@ HRESULT ddraw_surface_create(struct ddraw *ddraw, const DDSURFACEDESC2 *surface_
|
|||
}
|
||||
else
|
||||
{
|
||||
if (desc->ddsCaps.dwCaps & DDSCAPS_TEXTURE)
|
||||
wined3d_desc.usage |= WINED3DUSAGE_TEXTURE;
|
||||
if (desc->ddsCaps.dwCaps & DDSCAPS_ZBUFFER)
|
||||
wined3d_desc.usage |= WINED3DUSAGE_DEPTHSTENCIL;
|
||||
else if (desc->ddsCaps.dwCaps & DDSCAPS_3DDEVICE)
|
||||
wined3d_desc.usage |= WINED3DUSAGE_RENDERTARGET;
|
||||
if (!(ddraw->flags & DDRAW_NO3D))
|
||||
{
|
||||
if (desc->ddsCaps.dwCaps & DDSCAPS_TEXTURE)
|
||||
wined3d_desc.usage |= WINED3DUSAGE_TEXTURE;
|
||||
if (desc->ddsCaps.dwCaps & DDSCAPS_ZBUFFER)
|
||||
wined3d_desc.usage |= WINED3DUSAGE_DEPTHSTENCIL;
|
||||
else if (desc->ddsCaps.dwCaps & DDSCAPS_3DDEVICE)
|
||||
wined3d_desc.usage |= WINED3DUSAGE_RENDERTARGET;
|
||||
}
|
||||
|
||||
if (desc->ddsCaps.dwCaps2 & (DDSCAPS2_TEXTUREMANAGE | DDSCAPS2_D3DTEXTUREMANAGE))
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue