Is there a limit of vertices in WebGL?

Yes, WebGL’s vertex index buffers are limited to 16-bit right now. This is because they’re aiming to make version 1.0 as cross-platform as possible, so there’s a tendency to make stuff target the lowest common denominator — in cases like this, mobile platforms with limited graphics hardware.

Once 1.0 is out and the initial rush is over, they’re likely to loosen these constraints with the help of extensions — an app will be able to ask whether a given extension is supported by the implementation, and make use of it if it is — just like in regular desktop OpenGL. There are already a few extensions available, but again they’ve only allowed ones with very broad hardware support, so nothing that would help you increase your vertex count. However, once they loosen the cross-platform requirement, they are likely to support something like the GL_OES_element_index_uint extension that allows 32-bit vertex indices.

You can read some discussion of these issues on the Public WebGL mailing list.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)