Kodachi_Garou
12-11-2007 15:17:27
Hi all,
I've been noticing a very strange behaviour with Mogre 0.2.2 creation routines. It happens very, very rarely, when one has a very large SceneNode/Entity creation ratio (e.g. 1 or 2 objects created every frame for a couple of seconds).
The issue is that when calling SceneManager.Create(), the returned reference is a null reference. For instance:
However, the strangest thing is that low-level Ogre has indeed created the SceneNode, for if I query it for a SceneNode with the creation name, it returns me the correct reference for the created object.
I emphasize that this has only happened at very high creation rates, and in a non-deterministic fashion. For now, and until I figure out what it is, I've been plugging in the following safe-guard code, for instance:
Note also that this happens with any creation method, not just CreateSceneNode(), but with CreateEntity(), or even CreateChildSceneNode() in SceneNode instances.
Anyone has any idea what could be the issue here? I'll try and revert to Mogre 0.2.0. to see if it pops up there as well.
Best regards,
Gonçalo
I've been noticing a very strange behaviour with Mogre 0.2.2 creation routines. It happens very, very rarely, when one has a very large SceneNode/Entity creation ratio (e.g. 1 or 2 objects created every frame for a couple of seconds).
The issue is that when calling SceneManager.Create(), the returned reference is a null reference. For instance:
SceneNode node = manager.CreateSceneNode("testNode");
However, the strangest thing is that low-level Ogre has indeed created the SceneNode, for if I query it for a SceneNode with the creation name, it returns me the correct reference for the created object.
I emphasize that this has only happened at very high creation rates, and in a non-deterministic fashion. For now, and until I figure out what it is, I've been plugging in the following safe-guard code, for instance:
SceneNode node = manager.CreateSceneNode("testNode") ?? manager.GetSceneNode("testNode");
Note also that this happens with any creation method, not just CreateSceneNode(), but with CreateEntity(), or even CreateChildSceneNode() in SceneNode instances.
Anyone has any idea what could be the issue here? I'll try and revert to Mogre 0.2.0. to see if it pops up there as well.
Best regards,
Gonçalo