We can't do an asynchronous upload with just WINED3D_MAP_WRITE, but we can with update_sub_resource, and prepare_upload_bo doesn't know which it was called from.
Signed-off-by: Zebediah Figura zfigura@codeweavers.com --- dlls/wined3d/cs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c index 1cbbc43399a..376ee1a6c7e 100644 --- a/dlls/wined3d/cs.c +++ b/dlls/wined3d/cs.c @@ -2465,7 +2465,8 @@ HRESULT wined3d_device_context_emit_map(struct wined3d_device_context *context,
wined3d_resource_get_sub_resource_map_pitch(resource, sub_resource_idx, &row_pitch, &slice_pitch);
- if ((*map_ptr = context->ops->prepare_upload_bo(context, resource, + if ((flags & (WINED3D_MAP_DISCARD | WINED3D_MAP_NOOVERWRITE)) + && (*map_ptr = context->ops->prepare_upload_bo(context, resource, sub_resource_idx, box, row_pitch, slice_pitch, flags, &addr))) { TRACE("Returning upload bo %s, map pointer %p, row pitch %u, slice pitch %u.\n",