KhronosGroup / WebGL

The Official Khronos WebGL Repository
Other
2.63k stars 668 forks source link

Why not base webGL 2 on VULKAN ?! #1101

Closed LifeIsStrange closed 9 years ago

LifeIsStrange commented 9 years ago

When webGL 2 will be shiped, it will be already obscolete.... Sorry for my bad english and thanks for your awesome work !

toji commented 9 years ago

Vulkan has not been released yet, and there are serious questions about if certain aspects of it, such as it's memory management model, will be compatible with the Web in a reasonable manner. There also hasn't been a commitment yet from several large platforms to support it, and any Web-based API needs to be available on as many platforms as possible to be useful. In other words, it's simply too early for the web to make a big investment in the API. Beyond that Vulkan will be a significantly more complex API to use than OpenGL ES, and many developers won't want or need the complexity/performance tradeoff.

Basing WebGL 2 on OpenGL ES 3.0 ensures support on the widest range of hardware and provides developers with something familiar and proven. It also provides many compelling features in a mostly-backwards-compatible way with WebGL 1, which makes it easier for the existing ecosystem of WebGL applications, tools, and libraries to upgrade. It does put the web a little behind the bleeding edge, but that's typically a tradeoff the web is willing to make for compatibility and stability.

We have nothing against Vulkan, and I personally look forward to investigating it more in the future, but it needs to mature a bit more before we can commit to it.

LifeIsStrange commented 9 years ago

I understund, thank you a lot for your rapid and big answer !

Sorry to have take your precious time and good luck :).

oscarbg commented 9 years ago

Any news on exposing ES 3.1+ Android extension pack on WebGL 3.0 or something?

kenrussell commented 9 years ago

The WebGL working group intends to upgrade up to ES 3.1 functionality as soon as possible after WebGL 2.0 implementations are passing the conformance tests.

ghost commented 8 years ago

@toji You talked about the missing commitment from several large platforms to support Vulkan, please can you be more accurate? Did you have Apple or Google in mind? The former supports Metal and the latter is known to block access to the OpenCL driver such that it can now only be used by the RenderScript compiler since Android 4.3: https://code.google.com/p/android/issues/detail?id=36361 Vulkan has to be used with OpenCL to make sense as a competitor of DirectX 12 and Metal, that's why I talk about OpenCL too. You have nothing against Vulkan and I have nothing against Android as long as it doesn't force me to use platform dependent APIs with almost no plus value in my particular case.

LifeIsStrange commented 8 years ago

All platforms will support Vulkan (even ps4 and the promising Nintendo NX), Apple is the only one wich would not support (because fucking proprietary prison philosophy) BUT justly you altruists developers from the khronos group can force Apple to support Vulkan because if you do webgl 2 or 3 with Vulkan, Apple will be forced to support it because they could lose market share if they don't support modern Games on the web. And if they support Vulkan, Metal will dead in the egg ! For the good of the humanity :)

toji commented 8 years ago

@gouessej: Apple has made no commitment to support Vulkan, and appears to be throwing their weight fully behind Metal (which isn't a bad API, IMHO). Google will be supporting Vulkan on Android. (That announcement was made after my earlier comments in this thread.) It's probably worth pointing out that Microsoft hasn't made any commitments to Vulkan either, but their (desktop) OS is permissive enough that it can be implemented without Microsoft's explicit support.

Linux is, of course, Linux, so there will definitely be an implementation that probably won't work on your configuration. :)

The point remains that Vulkan is not going to be universal in the foreseeable future, and there are real technical issues with creating an ANGLE-like Vulkan implementation on top of something like Metal. I also don't feel it will in any way be productive to try and force any companies hand by railroading a Vulkan-like web spec through and saying "Ha! Now you have to implement it!" That sounds like a surefire way to create an API that nobody will use.

Rest assured, the working group is very interested in the future of WebGL! We've been talking about possible future directions for the API, and will continue to talk about it while we get WebGL 2 out the door and while the native ecosystem has a chance to adapt to the new APIs. It's a complex subject that requires careful planning and a realistic view of where the OSes, hardware vendors, and developers are at. Please be patient and trust that we all want what's best for the web as a whole.

I'm locking this issue, because I don't feel that this horse needs any more beating.