Re: [osg-users] How to correct remove objects from scene graph and destruct they not in render thread?

2012-02-17 Thread Robert Osfield
Hi Mikhail, If you want to remove elements from the scene graph but delay destruction to be done in a background thread the way to do it take a ref_ptr to the subgraph you want to remove to prevent it from being deleted, then remove the subgraph from the scene within the update phase of the

Re: [osg-users] How to correct remove objects from scene graph and destruct they not in render thread?

2012-02-17 Thread Mikhail I. Izmestev
17.02.2012 16:11, Robert Osfield пишет: Hi Mikhail, If you want to remove elements from the scene graph but delay destruction to be done in a background thread the way to do it take a ref_ptr to the subgraph you want to remove to prevent it from being deleted, then remove the subgraph from the

[osg-users] How to correct remove objects from scene graph and destruct they not in render thread?

2012-02-16 Thread Mikhail I. Izmestev
Hi, To remove heavy in destruction objects (which will free large buffers and etc.) I use method like in DatabasePager - hold object references and pass they to another thread for destructing. But there is one case which cause crash. (root) | (some nodes)