WebGL2.0的特性与API
原文
新特性
- OPENGL ES着色器语言3.0
- vertex array objects (VAOs)
- 三维纹理
- multiple render target(MRT)
- Texture access in vertex shaders
- 浮点数纹理
- 深度纹理
- texelFetch
- 采样器对象
- 一直缓冲对象
- 同步对象
- 查询对象
- 变换反馈对象
- Hardware Instancing
- immutable textures
- EXT_color_buffer_float
- Standard Derivatives
- Instanced Drawing
- Depth Textures (WEBGL_depth_texture)
- UNSIGNED_INT indices (OES_element_index_uint)
- Setting gl_FragDepth(EXT_frag_depth)
- Blend Equation MIN/MAX (EXT_blend_minmax)
- Direct texture LOD access (EXT_shader_texture_lod)
- Multiple Draw Buffers (WEBGL_draw_buffers)
- Non-Power of 2 Texture Support
- Floating Point Framebuffer Attachments
新API
Draw
- draw_image_space
- draw_instanced
- draw_primitive_restart
- draw_range_arrays
Frame Buffer Object
- fbo_blit
- fbo_multisample
- fbo_new_blend_equation
- fbo_rtt_draw_buffers
- fbo_rtt_texture_array
- fbo_rtt_depth_texture
- fbo_read_pixels
Sampler
- sampler_object
- sampler_filter
- sampler_wrap
GLSL
- glsl_centroid
- glsl_flat_smooth_interpolators
- glsl_non_square_matrix
Query
Buffer
- draw_instanced_ubo
- buffer_copy
- buffer_uniform
Texture
- texture_2d_array
- texture_3d
- texture_derivative
- texture_fetch
- texture_format
- texture_grad
- texture_immutable
- texture_integer
- texture_lod
- texture_offset
- texture_pixel_store
- texture_srgb
- texture_vertex
Transform Feedback
- transform_feedback_interleaved
- transform_feedback_separated
- transform_feedback_separated_2
- transform_feedback_instanced
Geometry
用新API做的常见效果