-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Description
Skia has support for creating an Image from a media element, but this is not currently exposed by Flutter. There are many cases such as SVG rendering, Video playback, or 3D rendering where many WebGL frameworks allow creation of textures from Media elements because it's the only relatively efficient pathway that the browser offers for doing this.
As it looks like the Texture support for Flutter web has been put on hold (#37890), perhaps an easier low hanging fruit would be to expose a helper method to do this.
We need a way to stop the renderer from crashing on web due to WebGL context limits being exhausted, but currently have no good pathway to prevent their creation. We love flutter, but the WebGL context problem is real and we really need to figure out a way to render things into layers of the canvas without forcing new contexts to be created.