I used the tutorial to load the sydney.md2 file fine with the texture.
I replaced the .md2 file with a 3ds max model (.3ds) which the model loaded was all white.
I think the .3ds file has a texture inbuilt, so how do I load these files completely.
thanks for looking
UF
how to load .3ds files
So far as i know the .3Ds file hasen´t the textures included, just the Path and the settings of the textures...
In my Opinion, irrlicht will just find the textures, if they in the same Folder or .zip file like your .3Ds file!
Or try: node->setMaterialTexture/getTexture like in the Tutorials...
And last: Search the Forum!
Sorry for my bad English
In my Opinion, irrlicht will just find the textures, if they in the same Folder or .zip file like your .3Ds file!
Or try: node->setMaterialTexture/getTexture like in the Tutorials...
And last: Search the Forum!
Sorry for my bad English
-
- Admin
- Posts: 14143
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
Yes, indeed if your mesh was correctly textures (uvmapped) the loader should at least try to load the texture. If it does not find the file it will issue a warning to the console. Just read it there and post it if you don't understand what it tells you.
If you do not have textures, but still want to have colors in 3ds files you'll have to patch Irrlicht and recompile it. Patch file found on my web page.
If you do not have textures, but still want to have colors in 3ds files you'll have to patch Irrlicht and recompile it. Patch file found on my web page.
-
- Posts: 4
- Joined: Sat May 20, 2006 7:28 pm
Hello,
this topic fits well for my problem. I also try to load an animated mesh file. The syndey.md2 file works well. then I created my own animation and converted it to a .x file. I have a viewer that play that .x animation, but when I try to get it working in Irrlicht, the model sits just there and does nothing, here is my code:
(it's java syntax, because Im using Jirr, this should be not the problem understanding what Im doing).
Does anyone has an idea why my model (.x) is not animated in the scene (I checked, that the .x file is correct and has an animation)?
Thanks a lot
this topic fits well for my problem. I also try to load an animated mesh file. The syndey.md2 file works well. then I created my own animation and converted it to a .x file. I have a viewer that play that .x animation, but when I try to get it working in Irrlicht, the model sits just there and does nothing, here is my code:
Code: Select all
IAnimatedMesh mesh = scene.getMesh("c:/temp/sydney.x");
IAnimatedMeshSceneNode node = scene.addAnimatedMeshSceneNode(mesh);
node.setFrameLoop(0, 30);
node.setAnimationSpeed( 30 );
node.setMaterialFlag( E_MATERIAL_FLAG.EMF_LIGHTING, false );
Does anyone has an idea why my model (.x) is not animated in the scene (I checked, that the .x file is correct and has an animation)?
Thanks a lot