OBJ2MDL - an OBJ->MDL converter

Posted By: Hiroyuki

OBJ2MDL - an OBJ->MDL converter - 05/31/06 08:02

Hello,

I developed a software "OBJ2MDL".
OBJ2MDL is a OBJ->MDL converter software.
It can load Wavefront OBJ file and convert it into 3D Gamestudio MDL5 file.

This software supports converting multiple OBJ files into single MDL5 with vertex animations.
This feature may help you especially when you are working with the Poser.

This software also has a automatic function that loading *.mtl file
and unify multiple skin textures into single one (skin texture #1).
Moreover, it also paint the corresponding UV point on newly created
skin texture #2 using diffuse color of the corresponding face (if any).

This software is free of charge for standard use(game creation).



I know there is a MDL7 format and newest MED has a OBJ import function,
But still I hope this software helps you much!

DOWNLOAD the OBJ2MDL
Posted By: capanno

Re: OBJ2MDL - an OBJ->MDL converter - 05/31/06 08:27

Nice!
Posted By: JetpackMonkey

Re: OBJ2MDL - an OBJ->MDL converter - 05/31/06 10:50

Awesome, Hiroyuki!!!

Is drag + drop implemented so I can drag my OBJ onto the app? I can't tell, because unfortunately all my OBJS crash the app, with an error message that says '0.03989080...etcetc

Would you like the file?

Best wishes and thanks for contributing your app! It looks very exciting. I personally am very attracted to the idea that it will combine multiple textures. Will this version of MD5 work with 6.314 too?

Thanks a ton,

JPM
Posted By: broozar

Re: OBJ2MDL - an OBJ->MDL converter - 05/31/06 11:12

i thought, obj cannot store animations?
Posted By: ventilator

Re: OBJ2MDL - an OBJ->MDL converter - 05/31/06 11:51

it doesn't but his tool interprets multiple numbered obj files as vertex animation frames. nice idea!

@jetpack_monkey: probably it would have been nicer if your model splitter directly read obj files instead of mdls. hm... or collada would be even better because it contains a better scenegraph with transformations and so on but collada is much more complicated to read i think.
Posted By: JetpackMonkey

Re: OBJ2MDL - an OBJ->MDL converter - 05/31/06 11:59

I think you're right, Ventilator. Maybe with .ase, alternately.

Here's my art path:

1. Export my scene using .ase from Maya/PLE using the Unreal ActorX axmesh tool. This free plugin is also available for MAX. Cinema too? It's a great exporter.
2. Convert it to .3ds via something like Deep Exploration. Unfortunately at this point, DE loses the DDS textures and converts them into BMP.
3. Import the 3DS into Med 6.40 version.
4. Export the MDL and use your handy model splitter to generate the wmp.
5. Re-import the DDS textures into the new MDL's as needed. (Ug!)

It would be very convenient to go straight from .ase or .obj into the splitter, this way the object names could be retained.

Furthermore, with a naming scheme, it might be possible to imbed actions/behaviors into the new .wmp, for example if an object is named:

smokestack__dosmokeparticle__1__2__3__4__5__6

The WMP could have an object named Smokestack, with the action "dosmokeparticle", skill 1=1, skill2 = 2, skill 3=3, etc etc etc.

Of course this would require a lot more work, right? Converting the .obj or .ase into new MDL files.

For those of you unfamiliar with Ventilator's Model Splitter, it takes a multiple object MDL file from MED and converts it into a WMP level, with each object in it's corresponding location, each now a unique entity. It's a great way to make a WMP level out of a multi-object polymesh file. It's a must if you want to make your levels entirely out of polymeshes.

Best wishes,

Jetpack
Posted By: broozar

Re: OBJ2MDL - an OBJ->MDL converter - 05/31/06 12:03

my path:

export from cinema/wings in obj,
load in blender
use ventilators exporter ^^ has full anim support

no hassle at all...
Posted By: frazzle

Re: OBJ2MDL - an OBJ->MDL converter - 05/31/06 19:17

Nice contribution Hiroyuki !!!!
Posted By: Silent_Assassin

Re: OBJ2MDL - an OBJ->MDL converter - 05/31/06 23:10

Thnx for this Hiroyuki ive been needing one of these

i got it earlier...just couldnt be bothered posting hehe
Posted By: kopitzki

Re: OBJ2MDL - an OBJ->MDL converter - 06/01/06 11:26

Thanks for sharing the program, Hiroyuki!! I've been working with Poser and it's just what I'll need soon. (I mean the "loading *.mtl file" option.)
Posted By: Hiroyuki

Re: OBJ2MDL - an OBJ->MDL converter - 06/02/06 02:58

@ALL: Thank you very much for comments above!

@Jetpack_Monkey: Maybe I can find the cause of the error, if you send me OBJ and MTL files which results the error with the OBJ2MDL. And MED of the 3DGS 6.314 can load MDL5 from this software. I usually convert the MDL5 to a MDL7 with MED, in order to optimize texture.

By the way, I want to post some info about making 3DGS models by working with the Poser.

I know original Poser models and most of famous 3rd party Poser models(such as the DAZ) cannot be used for 3D games(as mesh), without special permission of the author(or someone who holds certain rights).

But, several years ago, I found a great Poser model named "MAYA":
http://www.3digitalcrafts.net/studiomaya/
And, I noticed that its Term of Use about re-distribution are very friendly!
But, a problem is that the original MAYA model is very hi-poly.

So since last year, I have struggled to make good animated 3DGS human character models more easily and less costly, by working with the Poser, and using the MAYA model. For that purpose, I developed most ideas and programming codes of my "MDL reducer" and this "OBJ2MDL" tools last year. And following screenshot is a one of its outcome:

Above was created for Xmas of 2005, but wasn't published because of my busyness. She and her cloths are both from the Poser artwork of the StudioMaya above. I constructed her in the Poser with many easily added animations("poses"), then exported as multiple OBJs, converted it to the 3DGS MDL and reduced its polygon, by using my tools. Its still a bit hi-poly but moves good with my hardware.

I want to share these info in this forum, because I want to develop more good solution about this, and to share great Poser artists info like the StudioMaya.
Posted By: Bananatech

Re: OBJ2MDL - an OBJ->MDL converter - 06/04/06 00:14


although this can be done in med

FIVE STARS
Posted By: Hiroyuki

Re: OBJ2MDL - an OBJ->MDL converter - 06/05/06 06:01

@Bananatech: Thank you.
Now I am enjoying new features of MED too.
Posted By: Ichiro

Re: OBJ2MDL - an OBJ->MDL converter - 06/05/06 21:10

This is a great idea!

I wasn't able to load in a test model created from (if I recall correctly) Maya:

http://www.synthscribe.com/misc/sample.obj
http://www.synthscribe.com/misc/sample.mtl

I got the following error:

Code:
---------------------------
OBJ2MDL
---------------------------
'' ??????????.
---------------------------
OK
---------------------------



There weren't any textures at all in the above; could that cause problems?
Posted By: Hiroyuki

Re: OBJ2MDL - an OBJ->MDL converter - 06/06/06 01:21

@Ichiro: I checked your sample.obj file above and noticed that it contains face which consists of more than 5 vertices as follows:
[L:711]
f 62/217 10/218 24/219 26/220 25/221 6/222 27/223 30/224 63/225 64/226 65/227 66/228 67/229 31/230 54/231 58/232 60/233 59/234 52/235 68/236 69/237 70/238 71/239

The face of 3DGS MDL5 are all triangles, so if input OBJ contains face more than 3 vertice, OBJ->MDL converter like this software must split it into triangles. Currently this software can this operation only for faces which consists of 4 vertices.(Because it's mainly developed for OBJ exported from the Poser.) So I think it's the cause of the problem above.

Some 3D software's OBJ exporter has a option such as "Export all faces as triangle" or "Split face as triangle", and so on. So if your 3D software has such option, may be it's a closest solution of the problem above.

But anyway I think it's a important point for the future improvement of my OBJ2MDL itself...
So thank you for your report of the problem above.
Posted By: Ichiro

Re: OBJ2MDL - an OBJ->MDL converter - 06/06/06 02:43

Huh. I feel silly for not noticing that. Thanks. :)
Posted By: Ichiro

Re: OBJ2MDL - an OBJ->MDL converter - 06/06/06 18:51

I'm still having bad luck. I triangulated a cylinder and ran it through -- it created an MDL without complaining, but on loading that MDL file, there was no geometry. I was using the following:

http://www.synthscribe.com/misc/c_disc.obj
http://www.synthscribe.com/misc/c_disc.mtl

Any thoughts on what's causing that?
Posted By: Hiroyuki

Re: OBJ2MDL - an OBJ->MDL converter - 06/08/06 01:55

@Ichiro: I checked your c_disc files above and noticed following two points:

1) Each end of lines of the c_disc.obj seems to be UNIX-style LF(ASCII:10) code.
My OBJ2MDL can correctly work if each lines of OBJ and MTL end with WINDOWS-style CR+LF(ASCII:13+10) codes.

2) Filename of OBJ and MTL contains "_".
"_" in the filename is used for loading multiple OBJs. So otherwise it should not to be contained.

I think those two are causes of the problem above. So it should be solved by:
1) converting ends of lines of the c_disc.obj to CR+LF. (by using suitable text editor with CR+LF save mode)
2) renameing OBJ and MTL file names without "_". (for example: cdisc.obj and cdisc.mtl)

And I will add those points to the Readme.txt of the next version of my OBJ2MDL.
Posted By: Ichiro

Re: OBJ2MDL - an OBJ->MDL converter - 06/08/06 03:57

Well, now that did the trick. Thanks for sharing such a nice utility!
© 2024 lite-C Forums