From 864bef4c193276eefc8198ea2b91b5339d210db3 Mon Sep 17 00:00:00 2001 From: Henri Verbeet Date: Mon, 17 Jul 2017 14:01:36 +0200 Subject: [PATCH] wined3d: Make a FIXME in cpu_blitter_clear() slightly more accurate. The issue isn't so much stencil clears as clearing either depth or stencil on formats that contain both. Signed-off-by: Henri Verbeet Signed-off-by: Alexandre Julliard --- dlls/wined3d/surface.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index c1bb53e224c..c914e8d4690 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -3499,12 +3499,15 @@ static void cpu_blitter_clear(struct wined3d_blitter *blitter, struct wined3d_de } } - if ((flags & WINED3DCLEAR_ZBUFFER) && (view = fb->depth_stencil)) + if ((flags & (WINED3DCLEAR_ZBUFFER | WINED3DCLEAR_STENCIL)) && (view = fb->depth_stencil)) + { + if ((view->format->depth_size && !(flags & WINED3DCLEAR_ZBUFFER)) + || (view->format->stencil_size && !(flags & WINED3DCLEAR_STENCIL))) + FIXME("Clearing %#x on %s.\n", flags, debug_d3dformat(view->format->id)); + surface_cpu_blt_colour_fill(view, &box, &c); + } } - - if (flags & ~(WINED3DCLEAR_TARGET | WINED3DCLEAR_ZBUFFER)) - FIXME("flags %#x not implemented.\n", flags); } static void cpu_blitter_blit(struct wined3d_blitter *blitter, enum wined3d_blit_op op, -- 2.11.4.GIT