hyper3d
hyper3d copied to clipboard
Get Ready for WebGL 2.0!
Here are some of the new features of WebGL 2.0:
- Muliple Render Targets: The current implementation of geometry pass doesn't use MRT. By using MRT, ALU load can be reduced by 1/4.
- Vertex Array Objects: Reduction of draw calls.
- Instancing: Reduction of draw calls.
- Uniform Buffer Objects: Reduction of draw calls.
- 3D Texture: Might be useful for some global illumination methods as well as volumetrics.
gl_FragDepth: Depth buffer can be downsampled.- Query Objects: Occlusion culling.
- ~~Sync Objects: Accurate profiling~~.
We could take advantage of these features by using WebGL 2.0, but we need to take these things into consideration:
- GLSL of WebGL 2.0 differs from that of WebGL 1.0 slightly
- WebGL API itself didn't change too much, so we can and should avoid duplicated code
Hyper3D core for WebGL 2.0 is being written in C++.