mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-14 12:04:29 +00:00
examples: fix surface refresh approuchfor webgpu
Move surface refresh approach from engine side to user size.
This commit is contained in:
parent
e27ce23d4b
commit
9b638ea470
1 changed files with 5 additions and 0 deletions
|
@ -440,6 +440,11 @@ struct WgWindow : Window
|
|||
//Set the canvas target and draw on it.
|
||||
verify(canvas->target(instance, surface, width, height));
|
||||
}
|
||||
|
||||
void refresh() override
|
||||
{
|
||||
wgpuSurfacePresent(surface);
|
||||
}
|
||||
};
|
||||
|
||||
#else
|
||||
|
|
Loading…
Add table
Reference in a new issue