Easy Ogre Exporter for 3DSMAX

The place for artists, modellers, level designers et al to discuss their approaches for creating content for OGRE.
Post Reply
User avatar
EricB
Bronze Sponsor
Bronze Sponsor
Posts: 360
Joined: Fri Apr 09, 2010 5:28 am
Location: Florida
x 213
Contact:

Re: Easy Ogre Exporter for 3DSMAX

Post by EricB »

arkeon wrote:Hi bronzebeard !

Do you see something wrong in the generated .material ?
Is your max material a "standard material" or an another one ?
if you put an another material on your mesh does it still look black ?
what happen if you perform a reset Xform after your uvw ?

could you send me your max file for debug ?
EDIT*** Bingo resetting xform fixed the headlight. I'm an idiot :)

I don't see anything wrong with the material files, I didn't try reset xform, but I also have another issue with lighting as well. I went ahead and PM'd you the .max files and the tool to run the exported files that i've been using. I'll try resetting the xform and edit this post on the results.
Image
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

EOE Release 0.997 is available.

this correct a bug on uv coords when using the vertex colors.
On materials to disable texture alpha on diffuse you can use the "Alpha source" texture setting and set it to NONE

And yes the reset X-form is a kind of magic in Max ^^
The "real" Transformation datas are not up to date in the max SDK until you apply the reset X-form
OpenSpace 3D Project manager
http://www.openspace3d.com
Walker
Gnoblar
Posts: 2
Joined: Fri Jun 29, 2012 3:56 pm

Re: Easy Ogre Exporter for 3DSMAX

Post by Walker »

I've been using this exporter with no issues until I tried to use instancing. Long story short - Easy Ogre is exporting meshes with multiple submeshes when it really doesn't need to. As instancing will only instance a single submesh this is causing a lot of problems but seems like a bit of an issue anyway. To see this in effect you only need to create a box and export it (each face is a submesh - this isn't intentional right?). Several other primitives (like cones) behave similarly, though some (like spheres) do not.

I have tried messing with options in the exporter (is there more to find somewhere, or just what I find in the export window?). Additionally I tried exporting problem objects with OgreMax which will only generate one submesh per mesh so I don't think it's something in the mesh itself (though there could be 3dsMax options I'm not aware of that OgreMax handles differently).

(In 3dsMax 2012)

Any help would be appreciated!

Cheers
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

Hi !

EOE export the mesh as 3DS max give it ^^
The default box in max assign a material id (submesh) per face.
The material IDs are independent of the assigned material.

Initially EOE is intended to use the max parameters to determine the way to export.
So if you need only one subentity on your mesh only assign one material id for all the faces.

This is not an issue but the way Max works ^^
I don't want to override that and prefer the graphist to choose is needs.
for example you could export an object with 2 materials ID but with the same material assigned and dynamically set a different material per subentity in the program.
OpenSpace 3D Project manager
http://www.openspace3d.com
Walker
Gnoblar
Posts: 2
Joined: Fri Jun 29, 2012 3:56 pm

Re: Easy Ogre Exporter for 3DSMAX

Post by Walker »

arkeon wrote:Hi !

EOE export the mesh as 3DS max give it ^^
The default box in max assign a material id (submesh) per face.
The material IDs are independent of the assigned material.

Initially EOE is intended to use the max parameters to determine the way to export.
So if you need only one subentity on your mesh only assign one material id for all the faces.

This is not an issue but the way Max works ^^
I don't want to override that and prefer the graphist to choose is needs.
for example you could export an object with 2 materials ID but with the same material assigned and dynamically set a different material per subentity in the program.
I thought it might have been something like that for the box, but my inexperience in max did not lead me to the settings! After a more thorough search (for "Material ID") I got there. Naturally, the reason it was happening to other meshes was because they began as primitives!

Cheers!
htm688
Gnoblar
Posts: 4
Joined: Wed Jun 29, 2011 8:21 pm
x 1

Re: Easy Ogre Exporter for 3DSMAX

Post by htm688 »

Hi

When I try to export this from 3ds 2011 32bit , it crashes.

this is the log:

Code: Select all

Logging to file c:\edumat\models in developement\export\easyOgreExporter.log
Found node: Box001
Found mesh node: Box001
Creating skeleton ...
Info : Get vertex bone weight
Info : Found a root bone : Bone001
Info : Found a root bone : Bone002
Exporting root bone: Bone001
Exporting root bone: Bone002
Num. Skinned Vertices: 490
and this is the 3ds max file: http://www.mediafire.com/?9mf55sdcc2fdumu

I have an object with 2 bones, object has two elements, each skined to one of the bones.
the third bone in the scene does not cause the problem, it can be deleted and the problem presists.

Do you guys know how can i change the scee so it can be exported?

Thanks a lot.
User avatar
Brocan
Orc
Posts: 441
Joined: Tue Aug 01, 2006 1:43 am
Location: Spain!!
x 8

Re: Easy Ogre Exporter for 3DSMAX

Post by Brocan »

Hi!

First of all, great exporter!

I've a wish, could it be possible to save several max objets in a unique mesh like ogre max does? each object would be set as submesh. Its a very useful option for single models build from several max objects :mrgreen:

Thanks in advance!
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

Hello,

I don't think this should be very efficient ^^
For example if you have an animated mesh, skeleton or node animation this should be very complicated to manage correctly.
And where is the difficulty to simply add the desired meshs as elements in a max editable mesh ?
OpenSpace 3D Project manager
http://www.openspace3d.com
User avatar
Brocan
Orc
Posts: 441
Joined: Tue Aug 01, 2006 1:43 am
Location: Spain!!
x 8

Re: Easy Ogre Exporter for 3DSMAX

Post by Brocan »

arkeon wrote:Hello,

I don't think this should be very efficient ^^
For example if you have an animated mesh, skeleton or node animation this should be very complicated to manage correctly.
And where is the difficulty to simply add the desired meshs as elements in a max editable mesh ?
You are right, but my meshes are simply static :P . It's only a question of work efficiency, press an option or deal with convert it in a single mesh matching material ids, and so on. BTW, don't worry at all, it was only a question about if this feature was in your roadmap. :mrgreen:
htm688
Gnoblar
Posts: 4
Joined: Wed Jun 29, 2011 8:21 pm
x 1

Re: Easy Ogre Exporter for 3DSMAX

Post by htm688 »

arkeon wrote:Hello,

I don't think this should be very efficient ^^
For example if you have an animated mesh, skeleton or node animation this should be very complicated to manage correctly.
And where is the difficulty to simply add the desired meshs as elements in a max editable mesh ?
This is what I'm trying to do, adding meshes as elements to an editable mesh, but unfortunately my scene crashes when I try to export it (info on my above post including the scene in max format).
Tried exporting it on another pc today, same problem.
so if I can't get it to work that way, do I have to export as multiple meshes and assemble them when loading in my program?
I didn't know that ogremax has the option to export several objects as one mesh file, but anyway I can't afford ogremax exporter, the price is super high.

Thanks for sharing easy ogre exporter arkeon, I only have access to 3ds max files, and I couldn't use ogre without your exporter.
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

First thanks to every one supporting EOE :)

And sorry htm688 I missed your post ^^
I'll look at your max file this evening and try to found what happen :)
stay tuned !
OpenSpace 3D Project manager
http://www.openspace3d.com
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

@htm688

I debugged your max file ^^
Once again bad news :/ this is again a 3ds Max bug.

during the skinning export the SDK function pGameMesh->GetNumberOfVerts() return 8 vertices against 490 and the skin modifier return 490 vertices so it finally crash when I bind the vertices weights ^^

Once again a reset X-Form on the mesh make the Max IGame Interface (MAX API for exporters) return the correct values.

The IGame Interface is really a big ch...t I think that I'll have to rewrite everything without it ...
OpenSpace 3D Project manager
http://www.openspace3d.com
htm688
Gnoblar
Posts: 4
Joined: Wed Jun 29, 2011 8:21 pm
x 1

Re: Easy Ogre Exporter for 3DSMAX

Post by htm688 »

Thanks a lot for your help, reset Xform did the trick, but after I exported the test mesh, the animation as viewed in ogre Meshy is different than the one in 3ds.
my max file: http://www.mediafire.com/?v81ia3rpgukygsx
my exported mesh and skeleton: http://www.mediafire.com/?zscpvbqmht1ly3j
http://www.mediafire.com/?k3t63r8530b868f
and log:

Code: Select all

Logging to file c:\edumat\models in developement\export\easyOgreExporter.log
Found node: Box001
Found mesh node: Box001
Creating skeleton ...
Info : Get vertex bone weight
Info : Found a root bone : Bone001
Info : Found a root bone : Bone002
Exporting root bone: Bone001
Exporting root bone: Bone002
Num. Skinned Vertices: 490
Writing Box001 mesh binary...
Info: Create Ogre submeshs
Info: create submesh : 1
Info: create submesh : 0
Info: create submesh : 4
Info: create submesh : 3
Info: create submesh : 5
Info: create submesh : 2
Info: Create mesh bounding box
Info: Link Ogre skeleton
Info: Write mesh file : c:\edumat\models in developement\export\rollkick18Box001.mesh
Loading joint animations...
clip "Roundtrip"
length: 0.700000
num keyframes: 22
clip "Kick"
length: 2.633333
num keyframes: 80
Writing skeleton binary...
Found node: Bone001
Found node: Bone002
Writing materials data...
Copy material textures files
Info: export done.
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

New V0.998 available :
- Correction on bad vertex color values
- manage the "Vertex Color" texture type for materials on ambient and diffuse
- inform on skeleton export if the mesh is not valid "Perform a Reset X-Form"
- updated plugins with Bjoe mesh optimizations

Thanks again to Bjoe for his contributions :)
OpenSpace 3D Project manager
http://www.openspace3d.com
htm688
Gnoblar
Posts: 4
Joined: Wed Jun 29, 2011 8:21 pm
x 1

Re: Easy Ogre Exporter for 3DSMAX

Post by htm688 »

awesome improvements in V0.998, great exporter overall.

Thanks a lot for debugging my max file.
I tried your suggestion and did the reset xform, mesh exports easily now but I got some problems with getting the same animation after exporting.
I am moving the bones in my animation, if I just rotate them the animation exported matches the one in 3ds max, but when I move the bones I get that movements in a different direction in exported mesh.
I made a post about it yesterday but it is awaiting approval. there are links to the files in question in that post, it will appear two posts above this one when approved.
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

HI !

this is a know issue : http://redmine.scolring.org/issues/400
I'll try to found a good way to get the correct bones translation matrix asap.

If someone have some tips about that in the max SDK help is welcome :)
OpenSpace 3D Project manager
http://www.openspace3d.com
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

Hello !

EOE V0.999 :
I finally rewrite most of the mesh exporter without the Max SDK IGameInterface ^^
The difference is that the reset X-Form is no more needed to export the mesh. (but it still needed in some case in max, when you perform a mirror for example)
You can now use the vertex animation with any mesh modifier like the noise or ripple modifier.
The bones translations are now exported with the correct direction.

some tickets have also been closed.

Next time I'll try to manage the material better and I'd like to make an alternative shader generation without multipass.

Enjoy ;)
OpenSpace 3D Project manager
http://www.openspace3d.com
User avatar
TWO
Halfling
Posts: 61
Joined: Sat Jan 26, 2008 9:30 pm
Location: Germany
Contact:

Re: Easy Ogre Exporter for 3DSMAX

Post by TWO »

Hey! Great and easy exporter, very good work (:

I'm having problems with multiple UVs. I want to export AO for my models, but it seems as if the 2nd automatic UV does not get exported. Could you add a line per model to the log stating how many UVs were actually exported? Is there any condition where the exporter does decide not to export them?

Beware, I'm a programmer and I'm by no means good in 3ds max. Thank you.
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

Hi !

first thanks ^^

Damn you're right multi uv are broken :/ shame...
I've tested almost all the max scenes users sent to me, but none with multi uv ^^

I'll correct that asap
OpenSpace 3D Project manager
http://www.openspace3d.com
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

Hi!

EOE v1.0
- the additional UV coords are exported correctly
- there was also a mistake on multi material IDs

As usual binaries are available on the wiki page.

@TWO I also added a log message about the number of exported UV
OpenSpace 3D Project manager
http://www.openspace3d.com
bornloser
Gnoblar
Posts: 1
Joined: Fri Jun 29, 2012 4:54 am

Re: Easy Ogre Exporter for 3DSMAX

Post by bornloser »

I'm using easy ogre exporter 64bit on 3ds max 2013. I want to export a model as a .mesh file but I can only find the option to export as a .scene

What am I doing wrong?
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

Hello,

EOE only manage to export dot scene and automatically export associated meshs.
To get a mesh you must export the scene, a mesh directory will contain the mesh binaries.
OpenSpace 3D Project manager
http://www.openspace3d.com
lucky7456969
Gremlin
Posts: 156
Joined: Tue Sep 18, 2012 3:43 am

Re: Easy Ogre Exporter for 3DSMAX

Post by lucky7456969 »

Excuse me. Arr.. What about the svn command string that downloads the source code.
Thanks
Jack
arkeon
Goblin
Posts: 272
Joined: Fri Dec 04, 2009 6:02 pm
x 38

Re: Easy Ogre Exporter for 3DSMAX

Post by arkeon »

Hello !

just checkout the source link on the wiki page http://www.ogre3d.org/tikiwiki/tiki-ind ... e+Exporter
OpenSpace 3D Project manager
http://www.openspace3d.com
impytus
Gnoblar
Posts: 12
Joined: Thu Oct 11, 2012 8:40 pm

Re: Easy Ogre Exporter for 3DSMAX

Post by impytus »

Hi, Im having a really strange problem.

Im using 64bit 2011 version. I am trying to export a character model that I made using biped as the rig and a skin modifier

This is what happens when I export it and put it in ogre:

Image

believe me when I say, this is not what she is supposed to look like. even the legs are really deformed even though its not as noticeable. The head seems to be the only part that is unaffected.

and Ive attached the logs.
Ogre.log
(2.73 KiB) Downloaded 949 times
easyOgreExporter.log
(10.97 KiB) Downloaded 963 times
I couldn't help but notice that ogre log states that there are some bones that are not weighted, even though I Know they all are. the other log file states that several bones have more than 4 weights. even though I dont understand why this could be a problem, regardless I opened a new max window, placed in a biped. placed a few spheres on the hands, body, head and feet, attached them all together to make one object. Then I used the reset xform and skinned it. There were no errors this time but it caused the same problem when I put it into ogre.

Any ideas whats going wrong?

Would appreciate any help on this.. thanks.
Post Reply