wined3d: Handle WINED3D_POOL_SYSTEM_MEM resources in ffp_blitter_use_cpu_clear().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
864bef4c19
commit
95e42a8d19
|
@ -2551,6 +2551,9 @@ static BOOL ffp_blitter_use_cpu_clear(struct wined3d_rendertarget_view *view)
|
||||||
struct wined3d_texture *texture;
|
struct wined3d_texture *texture;
|
||||||
|
|
||||||
resource = view->resource;
|
resource = view->resource;
|
||||||
|
if (resource->pool == WINED3D_POOL_SYSTEM_MEM)
|
||||||
|
return TRUE;
|
||||||
|
|
||||||
if (resource->type == WINED3D_RTYPE_BUFFER)
|
if (resource->type == WINED3D_RTYPE_BUFFER)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
|
@ -2578,9 +2581,6 @@ static void ffp_blitter_clear(struct wined3d_blitter *blitter, struct wined3d_de
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
resource = view->resource;
|
resource = view->resource;
|
||||||
if (resource->pool == WINED3D_POOL_SYSTEM_MEM)
|
|
||||||
goto next;
|
|
||||||
|
|
||||||
if (!(flags & (WINED3DCLEAR_ZBUFFER | WINED3DCLEAR_STENCIL))
|
if (!(flags & (WINED3DCLEAR_ZBUFFER | WINED3DCLEAR_STENCIL))
|
||||||
&& ffp_blitter_use_cpu_clear(view))
|
&& ffp_blitter_use_cpu_clear(view))
|
||||||
goto next;
|
goto next;
|
||||||
|
@ -2601,13 +2601,9 @@ static void ffp_blitter_clear(struct wined3d_blitter *blitter, struct wined3d_de
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (flags & (WINED3DCLEAR_ZBUFFER | WINED3DCLEAR_STENCIL))
|
if ((flags & (WINED3DCLEAR_ZBUFFER | WINED3DCLEAR_STENCIL))
|
||||||
{
|
&& (view = fb->depth_stencil) && ffp_blitter_use_cpu_clear(view))
|
||||||
view = fb->depth_stencil;
|
goto next;
|
||||||
if (view && (view->resource->pool == WINED3D_POOL_SYSTEM_MEM
|
|
||||||
|| ffp_blitter_use_cpu_clear(view)))
|
|
||||||
goto next;
|
|
||||||
}
|
|
||||||
|
|
||||||
device_clear_render_targets(device, rt_count, fb, rect_count,
|
device_clear_render_targets(device, rt_count, fb, rect_count,
|
||||||
clear_rects, draw_rect, flags, colour, depth, stencil);
|
clear_rects, draw_rect, flags, colour, depth, stencil);
|
||||||
|
|
Loading…
Reference in New Issue