Looking at model exports

Discuss about anything related to the Irrlicht Engine, or read announcements about any significant features or usage changes.
Post Reply
thenewkgb
Posts: 59
Joined: Thu Jan 25, 2024 6:54 pm
Location: UK

Looking at model exports

Post by thenewkgb »

Good day everyone.

It's a good thing to want a finished game to show people. I've given myself a whole year to see where I am at when focusing on one game, one language, one engine - although last night was troubling. If I chose any engine available today, I would still run into trouble at some point. I vented in my diary last night and after some sleep browsed the forums for solutions.

It seems there are quite a few ways to get custom models into Irrlicht. I'm not the best planner/manager/most experienced in game development/seasoned dev with a dozen finished games, but I'd like to overcome this hurdle.

I've seen with my own eyes, all it takes is some perseverance. Maybe not instant answers, and completely doable.
thenewkgb
Posts: 59
Joined: Thu Jan 25, 2024 6:54 pm
Location: UK

Re: Looking at model exports

Post by thenewkgb »

I'm at home now. A good vent, a sleep on it, and looking at what's available.

I see in the SVN trunk has a B3DExport.py file. Also building the MeshConverter project could help.

It may seem "cool" for me to change/switch to another project, but I wouldn't get far if I bail out every time a "big" problem appears :(

I may also save myself hundreds of £££s by not needing Maya. My first attempt at solo game dev aimed towards Unity and Unreal. I thought Maya would fit nicely with them.
thenewkgb
Posts: 59
Joined: Thu Jan 25, 2024 6:54 pm
Location: UK

Re: Looking at model exports

Post by thenewkgb »

Downloaded Blender 2.59 and Python 2.6 and used the B3DExport.py script. It's sort of working.
In my program as well as MeshViewer the simple cube model doesn't animate.
I've tried both keyframes and also a bone. I haven't baked anything, just trying simple things that I remembered.
Once I loaded the cube (24 frames in Blender) I set these functions up:

Code: Select all

blitz_mesh_node->setPosition(irr::core::vector3df(0.f, 50.f, 0.f));
blitz_mesh_node->setScale(irr::core::vector3df(100.f, 100.f, 100.f));
blitz_mesh_node->setAnimationSpeed(5.f);
blitz_mesh_node->setFrameLoop(0, 24);
I'll keep searching the forums.

I see this dialog in the console:

Code: Select all

-read ChunkNODE: Cube
--read ChunkMESH
---ChunkVRTS
---ChunkTRIS
--read ChunkANIM
FPS: 60.000000
--read ChunkNODE: Bone
---read ChunkBONE
---read ChunkKEYS
Skinned Mesh - finalize
Loaded mesh: media/my_b3d_bone.b3d
thenewkgb
Posts: 59
Joined: Thu Jan 25, 2024 6:54 pm
Location: UK

Re: Looking at model exports

Post by thenewkgb »

And also the directx .x file export is the same in MeshViewer. Both files load the mesh but no animation is being played.
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: Looking at model exports

Post by CuteAlien »

Noiecity recently made a tutorial video about that, maybe it helps? viewtopic.php?p=307310
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
n00bc0de
Posts: 55
Joined: Tue Oct 04, 2022 1:21 am

Re: Looking at model exports

Post by n00bc0de »

I would also like to mention that you can use other software besides blender for animation.

Here is a list of software that easily exports animation to irrlicht:
  • Milkshape 3D
  • Misfit 3D
  • Maverick Model 3D
  • Truespace* - This is not worth the trouble but if you want to try it, do not download it from its own website. Look for another website that host it.
I also wrote a library that imports skeletal animation from anim8or as skinned meshes. I am planning on improving it but it works just fine if you just want to import your model with skeletal animation (which is currently all I use it for). viewtopic.php?t=52934

Blender does support the ability to export each frame of an animation as *.obj. You can easily create an animated mesh in irrlicht from this.

There is also a gltf importer I came across in a fork of irrlicht. I haven't tried this out myself but it may be worth looking into. https://github.com/jordan4ibanez/irrlic ... s-animated
thenewkgb
Posts: 59
Joined: Thu Jan 25, 2024 6:54 pm
Location: UK

Re: Looking at model exports

Post by thenewkgb »

Thank you. I have a little urge to pay for Milkshape. It'd be a little nostalgia from my younger days making models for Half-Life.

I also found Asset Importer (assimp) searching forums (may help)
viewtopic.php?t=50751

Blender plugin/SuperTuxCart (CuteAlien's link above helped) and I found version 2.59 worked okay for me

This for X files. I'm not sure if .x can animate in Irrlicht or not. The feature pages says .x is animated.
viewtopic.php?t=52229

p.s. I didn't join the vertices to the bone while parenting which stopped the animation playing properly.
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: Looking at model exports

Post by CuteAlien »

X can animate (there is an animated dwarf.x model in Irrlicht media), but there's hardly any support for that format out there anymore. I have unfortunately no examples for non-working animated .x models, so not sure what problem there was with the one there.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Post Reply