-
-
Notifications
You must be signed in to change notification settings - Fork 382
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Share GPU ressources across render windows #3051
Conversation
…ory public API This method changed the static Map `CLASS_MAPPING` of the corresponding backend. It was only used by the API specific render windows. Replace its usage with what is done everywhere else.
scalarTextureString didn't have a purpose and prevented caching of GPU resources
A new feature will add the ability to use a render window as child of another render window This change prevents using a render window where a renderer is needed
f500ef1
to
823da53
Compare
7b2118a
to
1d7dfe0
Compare
To share resources accross render windows, they need to share a common context To do so, the render windows can now have a parent that will contain the shared context The child render windows will proxy some methods of their parent to do the rendering The content of the parent canvas is then copied to the child canvas using a 2D context
The picking has been smoke tested and seems to be working fine. const mainCanvas = mainRenderWindowView.getCanvas();
mainCanvas.style.width = '500px';
document.body.appendChild(mainCanvas); |
@sankhesh can you please review when you get a chance |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
🎉 This PR is included in version 30.4.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
@bruyeret Sorry, I missed the review period but the changes look good to me. Excellent work! |
Add possibility to share a single context for several render windows.
This enables GPU ressource sharing accross render windows.
This feature uses
drawImage
from the main WebGL context to the child render window's canvas. It is slow if there are a lot of render windows on Firefox: see this issue.