Click to See Complete Forum and Search --> : How to speed up OpenGL rendering


Hardeep Singh
April 29th, 1999, 07:47 AM
I've created a 3D interactive interface using OpenGL. Over the past month or so, all my efforts have been towards improving the performance. This is what I've already done:

Removed specular reflection.
Replaced glMaterial() with glColorMaterial and glColor().
Disabled blending.
Replaced local/spot lights with one directional light.
Reduced the depths of most of the buffers in the Pixel Format Descriptor.
Replaced double-precision functions with their single-precision equivalents.
Done away with use of glScale() for the objects.
Used simple approximations as bounding boxes for the selection(see below).

I'm still not satisfied with the performance. I know it can be made much faster. Possible bottlenecks still present:

Every time the mouse moves, I select the object under it. This code I've taken from one of Nate Robbins' samples, and I think it's quite optimal. Only, the bounding boxes approximate the actual objects, and so I use Scaled cubes etc. here. Will the scaling affect the performance (It greatly affects it in render mode)?
I load all my objects in the beginning from display lists created by exporting .3ds files using View3ds. Even here, I can't do much, I just call the lists when I render the scene.

What should I do to get even better performance?
Most of the above performace tips I got from SGI's website. They've put up some slides from a talk on 'OpenGL performance tips'.

Any concrete suggestions would be helpful.
Thanks,
-Hardeep.