CHAI3DCHAI3D

normal Graphic rendering optimizations

More
29 Jan 2016 08:53 #1

What optimization techniques should I user when rendering large polygonal models?

Please Log in or Create an account to join the conversation.

More
29 Jan 2016 09:04 #2

If you are rendering a large polygonal models (cMesh or cMultiMesh objecs), you should always enable the display list functionality.

An OpenGL display list is an object created and stored in the memory of the graphics card that can be called multiple times without OpenGL having to recreate the object again and again. This saves processing time and thus increases the overall frames per second rate.

Now to create a list we first have to load the polygonal data and then call

    // enable display list for faster graphic rendering
    object->setUseDisplayList(true);

If you modify the shape of the object, you will then need to update the display list after the vertex and/or triangle values have been modified.
    // mark the display list for update
    object->markForUpdate(true);

Another optimization technique is the use of face culling. Face culling allows non-visible triangles of closed surfaces to be culled before expensive Rasterization and Fragment Shader operations.
    // enable face culling
    object->setUseCulling(true, true);

Please Log in or Create an account to join the conversation.