how small is a "small" display list?
hi,
in the redbook it says:
now, does anyone know how small is "small"? e.g. does it make sense to store a low polygon object with lets say 12 gl_triangles into a display list, or will this affect performance?
d.
in the redbook it says:
Quote:Although you're not guaranteed that your OpenGL implementation optimizes display lists for any particular uses, the execution of display lists isn't slower than executing the commands contained within them individually. There is some overhead, however, involved in jumping to a display list. If a particular list is small, this overhead could exceed any execution advantage.
now, does anyone know how small is "small"? e.g. does it make sense to store a low polygon object with lets say 12 gl_triangles into a display list, or will this affect performance?
d.
The numbers I've heard are: Fewer than 10 vertices are more efficient in immediate mode than in a vertex array, and fewer than 100 vertices are more efficient in a vertex array than in a display list. I have no idea how accurate those numbers are, as I haven't benchmarked them myself...
Alex Diener
Alex Diener
according to the apple video, if there are less than 16 polys, it doesn't optimize the list at all. Also, when passing data to display list, try to keep it in a consistent format, cause apple's drivers will detect that and try to optimize them. other than that, if you got a static object, I suggest you put it in a display list.
amusing story about the consistency of data... I put this into a display list:
That was taking about 2 minutes to compile into a display list
I changed the code to look like this:
and display list compilation time went down under 1 second.
Code:
glBegin(GL_TRIANGLES);
for about 1000000 times
{
glColor3f
18 glVertex2f calls
}
glEnd();That was taking about 2 minutes to compile into a display list
I changed the code to look like this:
Code:
glBegin(GL_TRIANGLES);
for about 1000000 times
{
18 x glColor3f followed by glVertex2f
}
glEnd();and display list compilation time went down under 1 second.
ok, thanks. So I guess I know where to go:
I put my objects into vertex arrays and the whole scene, which does not need to be transformed into a display list, right?
d.
I put my objects into vertex arrays and the whole scene, which does not need to be transformed into a display list, right?
d.
OneSadCookie Wrote:amusing story about the consistency of data...
display lists somehow behave quite differently on different hardware. on nvidia cards compiling immediate mode calls into a display list seems to make calling the lists extremely slow. my guess is that ati cards somehow optimize the lists or store them completely different than the geforce cards i've tried (drawing vertex arrays into lists works fine on the other hand).
Possibly Related Threads...
| Thread: | Author | Replies: | Views: | Last Post | |
| Small error with glViewport and gluPerspective? | cjcaufield | 1 | 2,875 |
Sep 20, 2009 01:10 AM Last Post: DoG |
|
| Drawing strategies for many small models | Fenris | 11 | 4,257 |
Nov 20, 2006 06:10 AM Last Post: unknown |
|
| Consistent "look" between small and large objects | WhatMeWorry | 1 | 2,251 |
Oct 10, 2005 12:26 AM Last Post: Fenris |
|
| Roots of Display List Overhead | aarku | 10 | 4,950 |
Apr 12, 2005 12:24 PM Last Post: FCCovett |
|
| Display list overhead | TomorrowPlusX | 4 | 3,793 |
Dec 20, 2004 02:13 PM Last Post: TomorrowPlusX |
|

