Platform/GFX/WebGL2: Difference between revisions
mNo edit summary |
|||
Line 1: | Line 1: | ||
=== Design === | == WebGL 2 Prototype == | ||
We call WebGL 2 prototype the implementation of an experimental WebGL implementation against OpenGL ES 3.0. This prototype have not been submitted to Khronos Group, but to introduce the idea of a full officially specified WebGL 2.0 API. For now, using WebGL 2 Prototype is not secure and will be only available only on Nightlies. The developer playing with our WebGL 2.0 prototype is using it at his own risk of crashes (Gecko crashes, driver crashes and even OS crashes). Mozilla Corporation and/or Mozilla Foundation can change, add, remove features at anytime. | |||
== Playground == | |||
[coming very soon!] | |||
== Development == | |||
=== Development - Design decision === | |||
* All WebGL functions must be implemented in WebGLContext | * All WebGL functions must be implemented in WebGLContext | ||
* WebGL function member definitions of WebGLContext should be group by feature as OpenGL ES 3.0 quick reference card do into differents .cpp files | * WebGL function member definitions of WebGLContext should be group by feature as OpenGL ES 3.0 quick reference card do into differents .cpp files | ||
* {{ok|Move functions definition from WebGLContextGL.cpp to distinct cpp files grouped as same as quick reference card do}} | |||
* {{ok|Restruct all .h lik WebGL1Context.h do}} | |||
=== Preliminary === | === Development - Preliminary === | ||
* {{done|Add WebGL1Context inheriting from WebGLContext}} | * {{done|Add WebGL1Context inheriting from WebGLContext}} | ||
Line 24: | Line 35: | ||
** Add in qualifiers in fragment shaders | ** Add in qualifiers in fragment shaders | ||
=== High Priority Features === | === Development - High Priority Features === | ||
* {{done|Add existing WebGL 1 extensions as WebGL 2 features}} | * {{done|Add existing WebGL 1 extensions as WebGL 2 features}} | ||
Line 43: | Line 54: | ||
* {{wishlist|gl.drawRangeElements (GL_EXT_draw_range_elements)}} | * {{wishlist|gl.drawRangeElements (GL_EXT_draw_range_elements)}} | ||
=== Low Priority Features === | === Development - Low Priority Features === | ||
* {{deferred|Uniform buffer objects (need OpenGL 3.2 on mac)}} | * {{deferred|Uniform buffer objects (need OpenGL 3.2 on mac)}} | ||
Line 62: | Line 73: | ||
* {{ok|Buffer to buffer copies}} | * {{ok|Buffer to buffer copies}} | ||
* {{ok|Texture storage}} | * {{ok|Texture storage}} | ||
=== Implementation Bugs (Meta WebGL2 {{nbug|889977}}) === | === Implementation Bugs (Meta WebGL2 {{nbug|889977}}) === | ||
Line 79: | Line 86: | ||
</onlyinclude> | </onlyinclude> | ||
== WebGL for contributors == | |||
=== Updates feed === | |||
Anyone one who wants to tests and play with our WebGL 2 prototype, just get follow this bug to get all landed updates. | Anyone one who wants to tests and/or play with our WebGL 2 prototype, just get follow this bug to get all landed updates. | ||
* {{nbug|894482}} Contributor & pre-alpha testers feed about WebGL 2 prototype updates | * {{nbug|894482}} Contributor & pre-alpha testers feed about WebGL 2 prototype updates | ||
Line 89: | Line 96: | ||
Feel free to report any WebGL 2 prototype's bugs by blocking {{nbug|894492}}. | Feel free to report any WebGL 2 prototype's bugs by blocking {{nbug|894492}}. | ||
=== WebGL 2 Bugs reported === | |||
<onlyinclude> | <onlyinclude> |
Revision as of 02:57, 23 July 2013
WebGL 2 Prototype
We call WebGL 2 prototype the implementation of an experimental WebGL implementation against OpenGL ES 3.0. This prototype have not been submitted to Khronos Group, but to introduce the idea of a full officially specified WebGL 2.0 API. For now, using WebGL 2 Prototype is not secure and will be only available only on Nightlies. The developer playing with our WebGL 2.0 prototype is using it at his own risk of crashes (Gecko crashes, driver crashes and even OS crashes). Mozilla Corporation and/or Mozilla Foundation can change, add, remove features at anytime.
Playground
[coming very soon!]
Development
Development - Design decision
- All WebGL functions must be implemented in WebGLContext
- WebGL function member definitions of WebGLContext should be group by feature as OpenGL ES 3.0 quick reference card do into differents .cpp files
- [ON TRACK] Move functions definition from WebGLContextGL.cpp to distinct cpp files grouped as same as quick reference card do
- [ON TRACK] Restruct all .h lik WebGL1Context.h do
Development - Preliminary
- [DONE] Add WebGL1Context inheriting from WebGLContext
- [DONE] Add WebGL2Context C++ class inheriting WebGLContext
- Enable with about:config flag (webgl.enable-ensecure-webgl2)
- Add virtual func WebGLContext::IsWebGL2
- Add WebGL2 IDL inheriting WebGL 1 IDL
- Edit HTMLCanvasElement::GetContextHelper to allow experimental-webgl2
- gl.getParameter(gl.VERSION) return "WebGL 2"
- [CARRY OVER] Edit GLContext to allow getting a GL3 context; let WebGL 2 use it
- On mac, all OpenGL contexts are shared to each others, therefor they all have to be the same version.
- This is getting fixed in bug 895597.
- Current GFX shader not compatible with OpenGL 3.2 core profile
- Would need to convert shader with ANGLE to the GLSL version we use.
- On mac, all OpenGL contexts are shared to each others, therefor they all have to be the same version.
- [DONE] Bypass ANGLE shader compilation
- Bypass only when the shader code contains #version experimental-webgl2
- Add automatic provide GL_EXT_gpu_shader4
- Add in/out qualifiers in vertex shaders
- Add in qualifiers in fragment shaders
Development - High Priority Features
- [DONE] Add existing WebGL 1 extensions as WebGL 2 features
- WEBGL_draw_buffers
- OES_vertex-array_object
- [DEFERRED] ECT2 texture (need OpenGL 4.3 on mac)
- [DEFERRED] EAC textures (need OpenGL 4.3 on mac)
- [ON TRACK] sRGB textures (GL_EXT_texture_sRGB)
- [ON TRACK] Multisample renderbuffers (GL_EXT_framebuffer_multisample)
- [DEFERRED] Primitive restart with fixed index (need OpenGL 3.2 on mac)
- [DONE] Min/max blend equations (GL_EXT_blend_minmax)
- [DONE] Query objects
- GL_ARB_occlusion_query
- GL_EXT_occlusion_query_boolean
- [ON TRACK] Transform feedback (GL_EXT_transform_feedback)
- [DONE] Instanced Rendering (GL_ARB_draw_instanced)
- [WISHLIST] gl.vertexAttribDivisor (GL_ARB_instanced_array)
- [WISHLIST] gl.drawRangeElements (GL_EXT_draw_range_elements)
Development - Low Priority Features
- [DEFERRED] Uniform buffer objects (need OpenGL 3.2 on mac)
- [DEFERRED] Sampler objects (need OpenGL 4.3 on mac)
- [ON TRACK] 3D textures
- [ON TRACK] Shadow comparisons
- [ON TRACK] Non-square and transposable uniform matrices
- [ON TRACK] R and RG textures (GL_ARB_texture_rg)
- [DEFERRED] Texture swizzles (need OpenGL 4.3 on mac)
- [ON TRACK] Unrestricted NPOT textures (GL_ARB_texture_non_power_of_two)
- [ON TRACK] Mipmap level/LOD tricks
- [ON TRACK] New renderbuffer/texture formats
- [ON TRACK] Half-float vertex attributes (GL_ARB_half_float_vertex)
- [ON TRACK] Stretch blits
- [ON TRACK] Framebuffer invalidation hints
- [ON TRACK] Attach any mipmap level to a framebuffer
- [ON TRACK] Additional pixel store data
- [ON TRACK] Buffer to buffer copies
- [ON TRACK] Texture storage
Implementation Bugs (Meta WebGL2 889977)
122 Total; 1 Open (0.82%); 121 Resolved (99.18%); 0 Verified (0%);
WebGL for contributors
Updates feed
Anyone one who wants to tests and/or play with our WebGL 2 prototype, just get follow this bug to get all landed updates.
- 894482 Contributor & pre-alpha testers feed about WebGL 2 prototype updates
Feel free to report any WebGL 2 prototype's bugs by blocking 894492.
WebGL 2 Bugs reported
ID | Priority | Summary | Status | Assigned to |
---|---|---|---|---|
898386 | -- | WebGL2 bug report -Firefox crashes in mozilla::WebGLContext::GenerateWarning with "MOZ_WEBGL_FORCE_OPENGL=1" | RESOLVED | |
900439 | -- | WebGL2 unable to initialize OpenGL on Linux/Nvidia GT 330M | RESOLVED | Guillaume Abadie |
1053440 | -- | WebGL2 bug report - not context available under Mesa (ES3) | RESOLVED |
3 Total; 0 Open (0%); 3 Resolved (100%); 0 Verified (0%);