mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-08 21:53:41 +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
a56fc81733
commit
83e834e16f
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