well, i am finally attempting some coding with IRR - i have the basics up and running BUT i have a newbie problem - i want to load a .3ds model that is static - i have not found in the examples or documents how to load this model - the only examples are loading the testmodel or an md2/3 or a quake bsp level - i cannot find an example of how to load a 3ds model into a node???
i tried:
node = smgr->addMeshSceneNode(smgr->getMesh("media/full.3ds"));
but since getMesh sends back an animated mesh it chokes - so how do i load a static 3ds mesh and pass it to addMeshSceneNode??
oh, and on the todo list - it would be great to have an example that did NOT load a quake level - instead it set up a plane under the player and placed a couple objects around - if someone tells me how to make a ground plane in IRR i will gladly write this example using some of my .3ds objects!
thanks!
Loading a .3ds static mesh as node??
i tried to load this as an animated mesh just for the hell of it (so i could go test other things) - i think it would work but i found out that the 3ds loader only loads version 3 or less of the 3ds format - and i guess my objects are saved in a more recent version 
node = smgr->addAnimatedMeshSceneNode(smgr->getMesh("media/full.3ds"));
well, what format objects should i stick with for my static objects - .x ? - i see that niko has made a .x loader - will it load static meshes? - if i grab the 4.2 update will i get the .x loader with it? and if not .x what other format will be around for the long haul?
thanks for any replies and help!
node = smgr->addAnimatedMeshSceneNode(smgr->getMesh("media/full.3ds"));
well, what format objects should i stick with for my static objects - .x ? - i see that niko has made a .x loader - will it load static meshes? - if i grab the 4.2 update will i get the .x loader with it? and if not .x what other format will be around for the long haul?
thanks for any replies and help!
You can create a static mesh from an animated mesh, by simply getting its first frame. For example: smgr->getMesh("media/full.3ds")->getMesh(0).
The .x file loader will be available first in version 0.5, but it will support static meshes, yes.
And you can find an example of how to load a static mesh from a .3ds file in the special effects example.
Hope it helps.
The .x file loader will be available first in version 0.5, but it will support static meshes, yes.
And you can find an example of how to load a static mesh from a .3ds file in the special effects example.
Hope it helps.
what happens to the rest animated mesh that gets loaded by the smgr? (since i will only be referencing the first frame of it - will it get unloaded correctly?) - actually, i cant even ask that correctly since i dont know how IRR gets rid of nodes ...
if my call is:
node = smgr->addMeshSceneNode(smgr->getMesh("media/full.obj")->getMesh(0));
* now i am using maya object instead of a .3ds
so if my call is as above what happens to the animated mesh that the smgr loads - since i am only adding the first frame of it? who handles getting rid of the animated mesh structure?
if my call is:
node = smgr->addMeshSceneNode(smgr->getMesh("media/full.obj")->getMesh(0));
* now i am using maya object instead of a .3ds
so if my call is as above what happens to the animated mesh that the smgr loads - since i am only adding the first frame of it? who handles getting rid of the animated mesh structure?