[osg-users] Displaying cables

Jean-Sébastien Guay jean-sebastien.guay at cm-labs.com
Tue Feb 5 06:13:25 PST 2008


Bonjour Rémy,

> Just a stupid question : if the bottleneck is the update of the hose, 
> what would you think about using VBOs ?
>   

Well, on a hunch yesterday before leaving I did something that actually 
improved things quite a bit: Before, when I wanted to switch off display 
lists, I would use both these lines:

    geometry->setUseDisplayList(false);
    geometry->setUseVertexBufferObjects(true);

The result was that the geometry was not visible for some reason (which 
leads to a separate question of what is necessary to get VBOs working 
right, but that's not really important for now).

In one try, I "accidentally" did this:

    geometry->setUseDisplayList(false);
    //geometry->setUseVertexBufferObjects(true);

(i.e. DLs off but VBOs _not_ on - not sure what state that leaves the 
geometry in...)

And that gave a really *huge* improvement! The cables are almost not 
significant now in the draw time. So I guess it really was the display 
list recompilation that was killing my draw time.

Thanks everyone for the tips and ideas for investigation. I'd say 
problem solved at this point. :-)

J-S

-- 
______________________________________________________
Jean-Sebastien Guay    jean-sebastien.guay at cm-labs.com
                               http://www.cm-labs.com/
                        http://whitestar02.webhop.org/



More information about the osg-users mailing list