wined3d: Only check rtv and dsv bindings in device_resource_released() when D3D is initialised.
This fixes a regression introduced by commit
4a9304305a
.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
c7c0415689
commit
9a789feb81
|
@ -4958,6 +4958,8 @@ void device_resource_released(struct wined3d_device *device, struct wined3d_reso
|
||||||
|
|
||||||
TRACE("device %p, resource %p, type %s.\n", device, resource, debug_d3dresourcetype(type));
|
TRACE("device %p, resource %p, type %s.\n", device, resource, debug_d3dresourcetype(type));
|
||||||
|
|
||||||
|
if (device->d3d_initialized)
|
||||||
|
{
|
||||||
for (i = 0; i < device->adapter->gl_info.limits.buffers; ++i)
|
for (i = 0; i < device->adapter->gl_info.limits.buffers; ++i)
|
||||||
{
|
{
|
||||||
if ((rtv = device->fb.render_targets[i]) && rtv->resource == resource)
|
if ((rtv = device->fb.render_targets[i]) && rtv->resource == resource)
|
||||||
|
@ -4966,6 +4968,7 @@ void device_resource_released(struct wined3d_device *device, struct wined3d_reso
|
||||||
|
|
||||||
if ((rtv = device->fb.depth_stencil) && rtv->resource == resource)
|
if ((rtv = device->fb.depth_stencil) && rtv->resource == resource)
|
||||||
ERR("Resource %p is still in use as depth/stencil buffer.\n", resource);
|
ERR("Resource %p is still in use as depth/stencil buffer.\n", resource);
|
||||||
|
}
|
||||||
|
|
||||||
switch (type)
|
switch (type)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue