Jump to content

[SOLVED] ObjectMeshDynamic updateBounds in thread


photo

Recommended Posts

hi, subj does not work in thread, why?

 

---thread:

...

mesh.AddVertex() ...

mesh.updateBounds() - invisible

---

 

 

---main thread

mesh.updatebounds() - visible

---

Link to comment

Hi Sergey,

 

Please take my apologies for late reply.

 

Bounds are correct and you're able to calculate them in another thread but the problem is that engine won't add node to the spatial tree from another thread so it won't appear on the screen. It's better to update bounds in the main thread but if you're relying on node bounds in another thread than you can just call Node::setEnabled(1) in the main thread and it should do the trick.

Link to comment
×
×
  • Create New...