Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Differences between WebGL and OpenGL

Tags:

opengl

webgl

Can anyone give me a simple answer about the exact difference between OpenGL and WebGL? I need more specific on the following: programming semantics, API's inheritence, API's extensions etc.

I've looked at the following site but it is not very clear to me: http://www.khronos.org/webgl/wiki/WebGL_and_OpenGL_Differences

like image 234
Deepak Avatar asked Dec 11 '11 06:12

Deepak


People also ask

Is WebGL like OpenGL?

WebGL is based on the OpenGL ES 2.0 specification, and retains the semantics of OpenGL ES in order to maximize portability to mobile devices. There are some significant differences in behavior of similar APIs between OpenGL ES 2.0 and the OpenGL API on desktop systems.

Is WebGL faster than OpenGL?

To answer, it is not a language bottleneck, but an api-version-used one. WebGL is based upon OpenGL ES, which has some pros but also runs a bit slower and it has more abstraction levels for code handling than pure OpenGL has, and that is reason for lowering performance - more code needs to be evaluated.

What version of OpenGL does WebGL use?

WebGL enables web content to use an API based on OpenGL ES 2.0 to perform 2D and 3D rendering in an HTML canvas in browsers that support it without the use of plug-ins.

Is WebGL a GLSL?

WebGL is a cross-platform, royalty-free API used to create 3D graphics in a Web browser. Based on OpenGL ES 2.0, WebGL uses the OpenGL shading language, GLSL, and offers the familiarity of the standard OpenGL API.


1 Answers

WebGL is "OpenGL ES 2", not plain OpenGL (the ES stands for 'for Embedded Systems'). So there's the first difference. OpenGL ES is essentially a subset of OpenGL. In addition, WebGL is almost the same as OpenGL ES 2, but has some subtle differences, explained in the link you provide. There's not much to add to that link, it's a pretty clear explanation of what is different between OpenGL ES 2 and Webgl.

like image 90
Mike 'Pomax' Kamermans Avatar answered Sep 21 '22 01:09

Mike 'Pomax' Kamermans