How to share model information between views?
Posted: Fri Sep 28, 2007 9:49 am
Hi everyone.
I have a pretty simple question - I want to display a single mesh in several different windows - each window has its own IrrlichtDevice, video driver, scene graph etc.
However they all need to display the same model data, which takes up quite a lot of memory. So, how can I share the model data between the scene graphs? Looking at the COctTreeSceneNode::createTree function I saw that it makes an internal copy of the vertex data in order to build the tree, so I guess I'll have to share the node itself. I'm thinking along the lines of adding the same COctTreeSceneNode instance to all the scene managers. Is that possible? I couldn't find a suitable function in ISceneManager...
I have a pretty simple question - I want to display a single mesh in several different windows - each window has its own IrrlichtDevice, video driver, scene graph etc.
However they all need to display the same model data, which takes up quite a lot of memory. So, how can I share the model data between the scene graphs? Looking at the COctTreeSceneNode::createTree function I saw that it makes an internal copy of the vertex data in order to build the tree, so I guess I'll have to share the node itself. I'm thinking along the lines of adding the same COctTreeSceneNode instance to all the scene managers. Is that possible? I couldn't find a suitable function in ISceneManager...