Replies: 1 comment 1 reply
-
|
Hi, this is not supported out of the box, but I can explain a bit how it could potentially work. It would likely make most sense to use Pygfx's own internal textures to render only to damaged regions. We could then use scissor tests / viewport to re-render only part of the image. There are a few things that make this hard though:
|
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
I was wondering whereas, for optimization purpose, it is possible to only render a part of the screen in pygfx? In the 2D case (especially GUI) there is often only a small portion of the screen to be updated. I believe this would involve two main steps :
Being able to render only a portion of the screen (maybe some sort of equivalent of glScissor in wgpu/pygfx?)
Telling the backend (for e.g Wayland) where is the damage region so that it keeps the previous buffer everywhere except where it has changed
Is 1. and/or 2. possible in pygfx ? I believe 2. would be blocked by wgpu as it does not support Present with Damage (gfx-rs/wgpu#2869) like VK_KHR_incremental_present? Is that correct?
(I suppose this could also be useful for the Jupyter Remote Frame Buffer backend by streaming only the damaged region)
Beta Was this translation helpful? Give feedback.
All reactions