3 ms·
One of the most exciting features of WebGPU, especially over WebGL, is the ability to run compute shaders. That opens up an entire class of 2D vector graphics r
by raphlinus 3y ago
One of the most exciting features of WebGPU, especially over WebGL, is the ability to run compute shaders. That opens up an entire class of 2D vector graphics rendering techniques using compute shaders, including Vello. It's still in early stages, but the current code does include text rendering. There's a very rough demo at https://levien.com/vello-demo https://levien.com/vello-demo (the demo doesn't do variable fonts but the code can), and we'll be polishing that in time for Chrome M113 going stable.
- pjmlp 3y agoThanks to Google blocking WebGL compute shaders adoption. We could have had them three years ago.
- CSSer 3y agoInteresting. Do you have any more context around this? It sounds uncharacteristic of Google to do so given their usual stance on browsers being all things to all people.
- pjmlp 3y agoYes, https://registry.khronos.org/webgl/specs/latest/2.0-compute/ https://registry.khronos.org/webgl/specs/latest/2.0-compute/ https://github.com/9ballsyndrome/WebGL_Compute_shader https://github.com/9ballsyndrome/WebGL_Compute_shader And then Google decides not implementating it after all, because of WebGPU. https://github.com/9ballsyndrome/WebGL_Compute_shader/issues/9 https://github.com/9ballsyndrome/WebGL_Compute_shader/issues...
- fulafel 3y agoThere's a lot of literature about font rendering predating compute shaders too, compute shaders are not a functional prerequisite by any means. Here's eg one case: https://github.com/astiopin/webgl_fonts https://github.com/astiopin/webgl_fonts
- pjmlp 3y agoYeah, that as well. WebGL 2.0 is kind of PlayStation 3 like in capabilities, that we seldom see that in action besides shadertoy, Google Maps/Earth, and 360° views on ecommerce sites is another matter.
- kimown 3y agoYes, I also don't understand why google abandon webgl compute shader, just because webgpu will have same, so they force developer using newer api.
- coffeeaddict1 3y agoIs it (will it be) possible to use Vello from C++ or is this firmly Rust only?
- raphlinus 3y agoThere are no active plans to do this, but it's all open source and there are tools such as cbindgen, so if there is sufficient interest there's a good chance it will happen.