wined3d: Synchronise WINED3D_CS_OP_UNLOAD_RESOURCE resource access.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
565cd2b84c
commit
af54f9b93a
|
@ -1256,6 +1256,7 @@ static void wined3d_cs_exec_unload_resource(struct wined3d_cs *cs, const void *d
|
|||
struct wined3d_resource *resource = op->resource;
|
||||
|
||||
resource->resource_ops->resource_unload(resource);
|
||||
wined3d_resource_release(resource);
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_unload_resource(struct wined3d_cs *cs, struct wined3d_resource *resource)
|
||||
|
@ -1266,6 +1267,8 @@ void wined3d_cs_emit_unload_resource(struct wined3d_cs *cs, struct wined3d_resou
|
|||
op->opcode = WINED3D_CS_OP_UNLOAD_RESOURCE;
|
||||
op->resource = resource;
|
||||
|
||||
wined3d_resource_acquire(resource);
|
||||
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue