Commit 293bf961 authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

wined3d: Pass a non-NULL rectangle to surface_color_fill() in…

wined3d: Pass a non-NULL rectangle to surface_color_fill() in wined3d_device_clear_rendertarget_view().
parent 7e8e7ece
...@@ -5008,6 +5008,7 @@ void CDECL wined3d_device_clear_rendertarget_view(struct wined3d_device *device, ...@@ -5008,6 +5008,7 @@ void CDECL wined3d_device_clear_rendertarget_view(struct wined3d_device *device,
{ {
struct wined3d_resource *resource; struct wined3d_resource *resource;
HRESULT hr; HRESULT hr;
RECT rect;
resource = rendertarget_view->resource; resource = rendertarget_view->resource;
if (resource->resourceType != WINED3DRTYPE_SURFACE) if (resource->resourceType != WINED3DRTYPE_SURFACE)
...@@ -5016,7 +5017,8 @@ void CDECL wined3d_device_clear_rendertarget_view(struct wined3d_device *device, ...@@ -5016,7 +5017,8 @@ void CDECL wined3d_device_clear_rendertarget_view(struct wined3d_device *device,
return; return;
} }
hr = surface_color_fill(surface_from_resource(resource), NULL, color); SetRect(&rect, 0, 0, resource->width, resource->height);
hr = surface_color_fill(surface_from_resource(resource), &rect, color);
if (FAILED(hr)) ERR("Color fill failed, hr %#x.\n", hr); if (FAILED(hr)) ERR("Color fill failed, hr %#x.\n", hr);
} }
......
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