=?UTF-8?Q?Stefan=20D=C3=B6singer=20?=: wined3d: Load surfaces into map binding memory on unload.
Alexandre Julliard
julliard at winehq.org
Fri Jan 10 13:22:47 CST 2014
Module: wine
Branch: master
Commit: badf3d8db77aa3db21d2bd41b05b730dd31c65ec
URL: http://source.winehq.org/git/wine.git/?a=commit;h=badf3d8db77aa3db21d2bd41b05b730dd31c65ec
Author: Stefan Dösinger <stefan at codeweavers.com>
Date: Fri Jan 10 12:40:46 2014 +0100
wined3d: Load surfaces into map binding memory on unload.
A surface can stay in DIB or user memory just fine. When buffers get
their own location an exception for them has to be added.
---
dlls/wined3d/surface.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c
index 6e15c00..19ae138 100644
--- a/dlls/wined3d/surface.c
+++ b/dlls/wined3d/surface.c
@@ -1369,7 +1369,7 @@ static void surface_unload(struct wined3d_resource *resource)
if (!(surface->flags & SFLAG_PBO))
{
surface_init_sysmem(surface);
- surface_validate_location(surface, SFLAG_INSYSMEM);
+ surface_validate_location(surface, surface->map_binding);
}
/* We also get here when the ddraw swapchain is destroyed, for example
* for a mode switch. In this case this surface won't necessarily be
@@ -1379,9 +1379,9 @@ static void surface_unload(struct wined3d_resource *resource)
}
else
{
- surface_load_location(surface, SFLAG_INSYSMEM);
+ surface_load_location(surface, surface->map_binding);
}
- surface_invalidate_location(surface, ~SFLAG_INSYSMEM);
+ surface_invalidate_location(surface, ~surface->map_binding);
surface->flags &= ~(SFLAG_ALLOCATED | SFLAG_SRGBALLOCATED);
context = context_acquire(device, NULL);
More information about the wine-cvs
mailing list