Scenegraph thread safety

I’ve removed the synchronized modifier from the renderOnce method in Renderer and replaced it with a synchronized block, which takes the current VirtualUniverse instance as the mutex. This way you can create synchronized blocks on your own also using your VirtualUniverse as the mutex and your scenegraph manipulations will be thread safe.

Marvin

Wouldn’t it impact performance, such way of synchronization?
I feel just “in loop synchronizations” as we used to are fatser (not sure though)
Those mutex monitors or whatever way they are called - migth be slow… Or I am wrong?

Yes, they are. But one monitor doesn’t hurt at all. And if you want to synchronize your operations this way, you’re free to do. I didn’t say it is the way of choice now.