Jonathan Richard schrieb:
I need to update the colors of my drawables at run time. So I call
setColorArray on my geometries but the changement is not visible at
display instead I call init on my sceneView after the update of the
colorArray. Is it a better way to update the colors?

You can modify the colorarray on the fly, no need to re-set it after a change. Be sure to call drawable->dirtyDisplayList() so OpenGL can recreate its displaylist. If you change the colors frequently (= every frame) then it's better to disable displaylists for the particular drawable: drawable->setSupportsDisplayList(false).


Hope that helps,
Stephan
_______________________________________________
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Reply via email to