I have got a complex code that is fully loaded with references to ISceneNode objects. I would like to enable shadows for these. However, the function that let us enable shadows is addShadowVolumeSceneNode(), which is only available for the class IMeshSceneNode.
My question is, how do I convert a ISceneNode into a IMeshSceneNode in order to apply shadows to it?
ps: I know it is not possible to apply shadows to a ISceneNode: http://irrlicht.sourceforge.net/forum/viewtopic.php?t=42174
You can cast an
ISceneNodepointer to anIMeshSceneNodepointer, if it actually points to an IMeshSceneNode object:But the better solution would be to store
IMeshSceneNodepointers asIMeshSceneNodepointers from the start.