Most Vizard commands are not thread safe, especially when it comes to adding/removing objects from different threads. The viz.director function mainly exists for backwards compatibility reasons, and is only intended to be used to perform non-Vizard related operations (e.g. file/socket IO).
Having said that, loading models in director threads can work. You just need to be very careful not to add/remove other models while the asynchronous operation is being performed. Additionally, the model should be added to a dummy scene when being loaded asynchronously, to avoid adding the model while the active scene is rendering.
Vizard 5 will have built-in support to load models/avatars asynchronously, and all the threading issues will be handled automatically.
|