Commit d6204ccd authored by Zebediah Figura's avatar Zebediah Figura Committed by Alexandre Julliard

ddraw: Use the sysmem wined3d texture for sysmem surfaces if possible.

parent b712d6c8
...@@ -698,7 +698,8 @@ static inline struct wined3d_texture *ddraw_surface_get_draw_texture(struct ddra ...@@ -698,7 +698,8 @@ static inline struct wined3d_texture *ddraw_surface_get_draw_texture(struct ddra
static inline struct wined3d_texture *ddraw_surface_get_any_texture(struct ddraw_surface *surface, unsigned int flags) static inline struct wined3d_texture *ddraw_surface_get_any_texture(struct ddraw_surface *surface, unsigned int flags)
{ {
if (surface->texture_location & DDRAW_SURFACE_LOCATION_DEFAULT) if ((surface->texture_location & DDRAW_SURFACE_LOCATION_DEFAULT)
|| (surface->surface_desc.ddsCaps.dwCaps & DDSCAPS_SYSTEMMEMORY))
return ddraw_surface_get_default_texture(surface, flags); return ddraw_surface_get_default_texture(surface, flags);
assert(surface->texture_location & DDRAW_SURFACE_LOCATION_DRAW); assert(surface->texture_location & DDRAW_SURFACE_LOCATION_DRAW);
......
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