1
0
Fork 0
mirror of synced 2025-03-07 03:53:26 +01:00

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

This commit is contained in:
Zebediah Figura 2024-01-03 20:49:04 -06:00 committed by Alexandre Julliard
parent b712d6c846
commit d6204ccd54

View file

@ -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)
{
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);
assert(surface->texture_location & DDRAW_SURFACE_LOCATION_DRAW);