<div dir="ltr">Hi Gianni,<br><div class="gmail_extra"><br><div class="gmail_quote">On 21 July 2017 at 11:32, Gianni Ambrosio <span dir="ltr"><<a href="mailto:g.ambrosio+osg@gmail.com" target="_blank">g.ambrosio+osg@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I tried what Lionel suggested but in fact the geometry generation is much more slow now.<br>
Anyway, since I suspected that "dirtyDisplayList()" is the cause of the delay, I tried to remove that line but without it I cannot see the new color.<br>
Now, is "dirtyDisplayList()" really required for what I need or is there a different call should I use just to see the triangle with the updated color?<br></blockquote><div><br></div><div>If you use display lists and you modify the osg::Geometry you need to call dirtyDislplayList() to force OSG to recompile.<br><br></div><div>What you need to do is to break your dataset into smaller chunks, 10,000 vertices per osg::Geometry is a reasonable level of granularity. Using VertexBufferObjects rather than DisplayLists is also something you should do. Finally optimize the dataset so you don't have some many vertices by making sure the triangle share vertices where possible - you'll need to use osg::DrawElementsUInt/UShort to use indices.<br><br></div><div>Doing these above steps will resolve most of the problems you have been presenting recently. If want to handle big datasets these are the steps you absolutely need to do.<br></div><div><br></div><div>Robert.<br></div><div><br><br></div><div><br><br></div><div><br> </div></div><br></div></div>