Speedy2D icon indicating copy to clipboard operation
Speedy2D copied to clipboard

WebCanvas: Handle WebGL context loss

Open QuantumBadger opened this issue 3 years ago • 2 comments

In the upcoming WebGL support, we don't handle the situation where the WebGL context is lost and restored. While it might be best to detect this externally and restart the app, we could handle this internally by saving all the textures in RAM and re-uploading them when the context is restored, as well as re-initialising all the shaders/etc.

QuantumBadger avatar Dec 04 '21 18:12 QuantumBadger

Is it too complex to be configurable?

Revertron avatar Dec 05 '21 02:12 Revertron

Is it too complex to be configurable?

It'll probably have to be configurable (and off by default) if it's added after the initial release, to avoid conflicting with any user-provided handling.

QuantumBadger avatar Dec 05 '21 10:12 QuantumBadger