5 ms·
WebGL runs on the same machine but uses a very different path to the GPU. On Mac, OpenGL is deprecated and the implementation is very outdated and feature poor.
by modeless 2y ago
WebGL runs on the same machine but uses a very different path to the GPU. On Mac, OpenGL is deprecated and the implementation is very outdated and feature poor. WebGL is not deprecated, and uses the ANGLE library to run on top of Metal.
- shooly 2y agoFrom what I know, OpenGL on macOS is internally implemented using Metal and supports more features than ANGLE. ANGLE on macOS supports OpenGL ES 3.0 when running using Metal backend (source: https://github.com/google/angle https://github.com/google/angle), whereas macOS natively supports Core 4.1. And from my experience, there is basically no difference in performance between Apple's implementation and ANGLE, especially for simple things like what the author is doing.
- modeless 2y agoI don't have internal knowledge of Apple's implementation but it could potentially be layered on top of Metal for Apple Silicon (probably not for Intel) though if so it probably uses internal-only capabilities not exposed to Metal users. OpenGL ES 3.0 is newer than OpenGL 4.1. The feature set is broadly very similar. Native macOS OpenGL is a backwards compatibility feature and not intended for new development. Lack of KHR_debug and general bugginess makes it a poor choice for learning OpenGL or deploying software on. On the other hand, WebGL is currently supported and extensively tested, with much better validation and error messages and much (much, much) better cross platform compatibility.
- LoganDark 2y ago> WebGL is not deprecated, and uses the ANGLE library *on Chromium!!! Firefox and WebKit do not use ANGLE for rendering.
- modeless 2y agoThis is false. Source: I added WebGL 2 support to WebKit using ANGLE, with Apple's help (they made ANGLE's Metal backend). Firefox uses ANGLE on every platform for shader translation, and on some platforms it uses ANGLE for the entire API (on others it has a custom OpenGL to WebGL translation layer).
- LoganDark 2y agoDo they use it for the window surfaces? AFAIK Chromium is the only one that does that.