mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-08 13:43:43 +00:00
wg_engine: force texture data writing on GPU side
Texture must be fully uploaded into GPU memory before we can use or destroy it. This change force texture data updates
This commit is contained in:
parent
e8702de059
commit
119ca34219
1 changed files with 1 additions and 0 deletions
|
@ -209,6 +209,7 @@ void WgImageData::update(WgContext& context, Surface* surface)
|
|||
writeSize.height = surface->h;
|
||||
writeSize.depthOrArrayLayers = 1;
|
||||
wgpuQueueWriteTexture(context.queue, &imageCopyTexture, surface->data, 4 * surface->w * surface->h, &textureDataLayout, &writeSize);
|
||||
wgpuQueueSubmit(context.queue, 0, nullptr);
|
||||
};
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue