In OpenGL ES, is it faster to draw one large object or many small ones?

For OpenGL ES 3-D on iPhone, which of the following functions is faster:

  • 10 objects with 100 triangles
  • one object having 1000 triangles
+3
source share
4 answers

Each OpenGL ES drawing call has some overhead, so if you represent 10 objects individually using glDrawArrays()or glDrawElements(), it will usually be slower than one large object. However, I think you will find the overhead from these call appeals is only a small factor in any rendering slowdowns that may occur on iOS devices.

, , . , , - (VBOs), . , , , iOS, VBOs.

, , , , , .. , Apple " Vertex", OpenGL ES iOS, OpenGL ES OpenGL ES Analyzer.

+4

, VBOs. 1 , 10 . - .

+1

, , .

0

The number of triangles is the same in both cases, so they are equivalent, all other things being equal. GL knows nothing about your “objects” - it just displays triangles.

However, there may be some saving in data size if you split vertices between triangles inside objects and use triangular stripes or fans or indexed vertices. See Brad's answer for more information on land.

0
source

All Articles