How can I import a mesh?

Anything and everything that's related to OGRE or the wider graphics field that doesn't fit into the other forums.
Post Reply
1addrian111111
Gnoblar
Posts: 10
Joined: Sun Dec 14, 2014 6:50 pm

How can I import a mesh?

Post by 1addrian111111 »

Hi!

I use the robot.mesh ( Entity= mSceneMgr->createEntity("Player", "robot.mesh") );
The mesh is stored here: C:\Ogre3D\OgreSDK_vc11_v1-9-0\media\models

If I have download other .mesh from here http://tf3dm.com/3d-models/all/1/mesh
Let's suppose I've downloaded Hulk.mesh. The hulk folder contains: Generic_Item.mesh, Hulk_D.tga, Hulk_N.tga, Hulk_O.tga, Hulk_S.tga.
I moved all the files in models folder... Then I have used this new mesh ( Entity= mSceneMgr->createEntity("Player", "Generic_Item.mesh") ) but when I run the program the compiler gives me an error... there is a problem with the mesh!

How can I import a new mesh?
User avatar
Kojack
OGRE Moderator
OGRE Moderator
Posts: 7157
Joined: Sun Jan 25, 2004 7:35 am
Location: Brisbane, Australia
x 534

Re: How can I import a mesh?

Post by Kojack »

The hulk mesh is not an Ogre format mesh. It's actually using the Tomb Raider mesh format (completely different to our meshes, only the file extension is the same). If you look at the preview pic you can see the XNA logo, that's the XNALara program for viewing Tomb Raider meshes.

You could try the import/export tools for Blender here: http://johnzero7.deviantart.com/journal ... -475948475
Then export from Blender to Ogre.

Or get the mesh in a format like .max, .dae, etc and load into the appropriate 3d modelling tool then export to ogre. We have exporters for most popular tools here: http://www.ogre3d.org/tikiwiki/tiki-ind ... +Exporters

There is no direct way to load a Tomb Raider mesh into Ogre.
1addrian111111
Gnoblar
Posts: 10
Joined: Sun Dec 14, 2014 6:50 pm

Re: How can I import a mesh?

Post by 1addrian111111 »

I have downloaded Blender... Now I just import .3ds into Blender then export to ogre.mesh.xml (using ogre addon)... then I use ogre xml converter and it will generate my .mesh. Thank you!! :D
Post Reply