I am learning OpenGL 3.3 and working on an small game engine of mine.
But the more I explore it feels like the offline PC games might become obsolete one day. All the games will be on browser.
I am also very interested in integrating everything in browse as long as it is possible to leverage the same strength as any other non-browser game.
After a little research I found, WebGL, which runs on HTML 5's Canvas.
Now there are several questions,
Does WebGL can leverage the same strength from the PC, as a non-browse product can?
It is fully shader based? or also supports deprecated(i don't know if it is also deprecated in WebGL) fixed function rendering? As I am learning shader based approach, I really don't want to go back to fixed function pipeline.
Or do I have to use other wrapper (Copperlich or GLGE) to get shader support? (though, none of those engines has shader support).
Is JavaScript the only way to interact with WebGL? Is there any way to write WebGL application using C/C++/Java?
Is it possible to integrate other middleware with WebGL? (for example: bullet, phyX). Do I have to write some interface using JS which connects with this native liberary?
Java application can be integrated inside the browser, which have OpenGl interface using JOGL or LWJGL. Then why WebGL, when Java can do that?
Isn't JavaScript slow? Is it really a good choice?
Is it possible to run a engine written using C/C++ using OpenGL, on WebGL context? Is it just about abstracting out the rendering system or is it not possible at all?
Is there any possibiliry for Microsoft to come up with WebX (DirectX) instread of implementing WebGL on IE?
I think the most important part of WebGL is going to be, the default integration with browser. So, you don't have to download a plug-in to play the game, like Unity Player for Unity3d or any other plug-in for a particular game engine. You can still play on any freshly installed browser as long as it supports WebGL. Just open the page and start playing. Isn't that right?
Is there any alternate to WebGL, that can provide "no plugin installation needed" launch?
What are the stability issues? Because the game will be running in the browser, its responsiveness is going to play a crucial role about the stability of the game. Should I bother about it yet? Will the browser be a bottleneck of the game?
What are the (major) things that WebGL don't support that is supported by OpenGL 3.3 or later (I know WebGL is based on OpenGL ES 2.0). As I have said earlier, I am working on my own game engine based on OpenGL 3.3
Rather then yes/no, some explanation or web reference would help.
But the more I explore it feels like the offline pc games might become obsolute one day. All the games will be on browser.
And if that happens 15 years from now, WebGL or some similar technology will still be there. No need to rush.
After a little research I found, WebGL, which runs on HTML 5's Canvas.
Unless of course the person is running Internet Explorer.
1: What do you mean by "same strengths?"
2: WebGL is a JavaScript implementation of OpenGL ES 2.0. So yes.
3: See #2.
4: WebGL is a JavaScript implementation of OpenGL ES 2.0. So it's JavaScript only ;)
5: WebGL is a JavaScript implementation of OpenGL ES 2.0. Bullet and such are compiled libraries. Unless you start getting into some browser add-ons, the only libraries you can use are what comes with the browser and whatever JavaScript tech you want to use.
Note: I'm not certain that JavaScript can directly interact with browser add-ons. If it can, it would be via a browser-specific API. So it may not be possible at all.
6: Because Java requires installing the Java runtime, which is effectively an add-on. JavaScript has more direct access to the browser. You can interface with an HTML's DOM, server-side communication via JSON or other mechanisms and the like.
7: Define "slow." Most browsers use some form of JIT, so it will run "reasonably fast." Will it have the performance that native code might have? No. But then again, are you making a game that will need that performance?
8: Say it with me now: WebGL is a JavaScript implementation of OpenGL ES 2.0. So no interfacing with C/C++ code that isn't part of the browser ;)
9: They're planning to expose 3D rendering via Silverlight soon. Silverlight is of course an add-on.
10: Yes.
11: No. Nothing even remotely cross-platform.
12: That's browser and driver dependent. WebGL implementations are still young, so they may still have some maturation to do.
13: This is a complex question. You may be aware of this, but, WebGL is a JavaScript implementation of OpenGL ES 2.0 ;) This means it supports what ES 2.0 does, along with whatever extensions that the implementation exposes. Unlike regular desktop or mobile OpenGL implementations, the implementation here has two parts: the browser itself and the hardware driver.
Google's implementation of WebGL translates WebGL's OpenGL ES 2.0 calls into Direct3D calls on Windows desktop machines. This allows them a bit of stability (since OpenGL drivers, particularly on Linux machines, are flaky). The cost is that Google now decides what extensions to support. Firefox's WebGL implementation goes straight to desktop OpenGL or the underlying OpenGL ES 2.0 for mobile devices. This allows the underlying implementation to expose extensions to WebGL.
The base ES 2.0, which is all WebGL guarantees, is approximately equivalent to desktop OpenGL 2.0. So nothing from desktop GL 3.x. There are many OpenGL ES extensions that provide access to more features, but the totality of them don't add up to desktop GL 3.x-level functionality yet.
Ultimately, WebGL is not meant for "hardcore games". It might certainly be able to implement some, but it's primary purpose is to allow drawing 3D graphics. Blistering speed and high-end physics are not what it's about.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With