Commit 95e42a8d authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

wined3d: Handle WINED3D_POOL_SYSTEM_MEM resources in ffp_blitter_use_cpu_clear().

parent 864bef4c
......@@ -2551,6 +2551,9 @@ static BOOL ffp_blitter_use_cpu_clear(struct wined3d_rendertarget_view *view)
struct wined3d_texture *texture;
resource = view->resource;
if (resource->pool == WINED3D_POOL_SYSTEM_MEM)
return TRUE;
if (resource->type == WINED3D_RTYPE_BUFFER)
return FALSE;
......@@ -2578,9 +2581,6 @@ static void ffp_blitter_clear(struct wined3d_blitter *blitter, struct wined3d_de
continue;
resource = view->resource;
if (resource->pool == WINED3D_POOL_SYSTEM_MEM)
goto next;
if (!(flags & (WINED3DCLEAR_ZBUFFER | WINED3DCLEAR_STENCIL))
&& ffp_blitter_use_cpu_clear(view))
goto next;
......@@ -2601,13 +2601,9 @@ static void ffp_blitter_clear(struct wined3d_blitter *blitter, struct wined3d_de
}
}
if (flags & (WINED3DCLEAR_ZBUFFER | WINED3DCLEAR_STENCIL))
{
view = fb->depth_stencil;
if (view && (view->resource->pool == WINED3D_POOL_SYSTEM_MEM
|| ffp_blitter_use_cpu_clear(view)))
goto next;
}
if ((flags & (WINED3DCLEAR_ZBUFFER | WINED3DCLEAR_STENCIL))
&& (view = fb->depth_stencil) && ffp_blitter_use_cpu_clear(view))
goto next;
device_clear_render_targets(device, rt_count, fb, rect_count,
clear_rects, draw_rect, flags, colour, depth, stencil);
......
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