Module: wine Branch: master Commit: 5895f77474d39ab0506323bf038837b7d07b6c4b URL: http://source.winehq.org/git/wine.git/?a=commit;h=5895f77474d39ab0506323bf03...
Author: Henri Verbeet hverbeet@codeweavers.com Date: Fri Feb 24 08:10:29 2017 +0100
wined3d: Support downloading depth textures in surface_load_sysmem().
Signed-off-by: Henri Verbeet hverbeet@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/wined3d/surface.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-)
diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 399f436..8b5f5ce 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -2475,13 +2475,6 @@ static BOOL surface_load_sysmem(struct wined3d_surface *surface, struct wined3d_texture_sub_resource *sub_resource;
sub_resource = &texture->sub_resources[sub_resource_idx]; - if (texture->resource.usage & WINED3DUSAGE_DEPTHSTENCIL) - { - FIXME("Unimplemented copy from %s for depth/stencil buffers.\n", - wined3d_debug_location(sub_resource->locations)); - return FALSE; - } - wined3d_texture_prepare_location(texture, sub_resource_idx, context, dst_location);
if (sub_resource->locations & (WINED3D_LOCATION_RB_MULTISAMPLE | WINED3D_LOCATION_RB_RESOLVED)) @@ -2498,7 +2491,8 @@ static BOOL surface_load_sysmem(struct wined3d_surface *surface, return TRUE; }
- if (sub_resource->locations & WINED3D_LOCATION_DRAWABLE) + if (!(texture->resource.usage & WINED3DUSAGE_DEPTHSTENCIL) + && (sub_resource->locations & WINED3D_LOCATION_DRAWABLE)) { read_from_framebuffer(surface, context, dst_location); return TRUE;