Model Converter [alpha released]

Discuss the creation of various model formats for Quake engines, and related matters to modeling.
Sajt
Posts: 1215
Joined: Sat Oct 16, 2004 3:39 am

Model Converter [alpha released]

Post by Sajt »

I've decided to release the model converter I've been working on off and on for the past month. It imports MDL, MD2, and MD3, and exports to MDL. Every little part of the MDL format specs is properly implemented... or at least I hope so. It has no problem converting any UV map, or loading MD3s with multiple objects. HOWEVER: it doesn't support MD3s with multiple textures (yet).

The converter is a COMMAND-LINE TOOL. That means it's really inconvenient to use, and lacks some features such as moving frames around. You'll have to bear with me. I would like to make a GUI version later, but I thought I would release the command-line version so anybody who just needs to convert models can do so immediately.

I've tested it on 32-bit Windows and Linux, but not thoroughly. It was developed on Windows. The source is licensed under the GPL and publicly available.

Website: http://www.icculus.org/qshed/qwalk/
Download: http://www.icculus.org/qshed/qwalk/download/
Guide: http://www.icculus.org/qshed/qwalk/guide/

You NEED to read the guide AND the main qwalk page, because there's currently no other way to know how to use the converter.

And this is NOT a stable release. It's not even a beta. It's an alpha. I made the decision to make a release only two hours ago, and cobbled it together since then. It's possible I left an obvious bug in or forgot something stupid. I have tested it, but not painstakingly. If you are reading this and want to make a news post about it, please include this disclaimer!

If you have questions, found a bug, or would like to request a feature, let me know. Post on this thread, or email me at sajt at icculus dot org.
Last edited by Sajt on Mon Jan 18, 2010 2:33 pm, edited 1 time in total.
F. A. Špork, an enlightened nobleman and a great patron of art, had a stately Baroque spa complex built on the banks of the River Labe.
frag.machine
Posts: 2126
Joined: Sat Nov 25, 2006 1:49 pm

Post by frag.machine »

Yay! Excellent, Sajt. I'll check it out. I've been working in a .mdl editor on and off for a long time ago, and maybe I can help you in someway.
I know FrikaC made a cgi-bin version of the quakec interpreter once and wrote part of his website in QuakeC :) (LordHavoc)
Urre
Posts: 1109
Joined: Fri Nov 05, 2004 2:36 am
Location: Moon
Contact:

Post by Urre »

I've been holding my breath for this :)

Did scar3crow ever tell you I requested support for a widely supported common format for input? Examples being .3ds, obj, .lwo and more. Cause that'd rock, would make modeling .mdl's a great deal easier for a bunch of people. Only one of those "common" formats would be needed I believe, as all modeling software can export to them without trouble. I'd vote .obj.

In any case, this is more than awesome already, I'll be testing it out later! Way to go Sajt!
I was once a Quake modder
Sajt
Posts: 1215
Joined: Sat Oct 16, 2004 3:39 am

Post by Sajt »

Yes, I would be willing to add OBJ support. I would just need a few example OBJ models for testing. I have some experience with writing OBJ loaders, but I never got into the smoothing groups or materials or things like that.
F. A. Špork, an enlightened nobleman and a great patron of art, had a stately Baroque spa complex built on the banks of the River Labe.
c0burn
Posts: 208
Joined: Fri Nov 05, 2004 12:48 pm
Location: Liverpool, England
Contact:

Post by c0burn »

What happens if the source model exceeds the MDL specs?
Sajt
Posts: 1215
Joined: Sat Oct 16, 2004 3:39 am

Post by Sajt »

When you export a model, it will print a warning in these cases:
- The model's skin's height is greater than 200px (won't run in DOSQuake)
- The model's skin is not power of two (will be resampled in GLQuake). Almost all models have non-power-of-two textures though, so I should probably hush this warning.
- More than 1024 vertices (won't run in standard engines)
- More than 2048 triangles (won't run in standard engines)
- More than 256 frames (won't fit in standard Quake network protocol)

If the skin's width is not a multiple of 4 (which is a requirement of the format), it will be automatically padded (without borking the texcoords).

I might have missed some other limitations.

I think you can fit any number of vertices and triangles and any size skin in a MDL file, it's just the old engines that have some static limits.
F. A. Špork, an enlightened nobleman and a great patron of art, had a stately Baroque spa complex built on the banks of the River Labe.
c0burn
Posts: 208
Joined: Fri Nov 05, 2004 12:48 pm
Location: Liverpool, England
Contact:

Post by c0burn »

That's utterly fantastic. God, I wish we had the Quake models with bones intact.
Teiman
Posts: 311
Joined: Sun Jun 03, 2007 9:39 am

Post by Teiman »

Grrrreat ! :-)
frag.machine
Posts: 2126
Joined: Sat Nov 25, 2006 1:49 pm

Post by frag.machine »

Sajt wrote:If the skin's width is not a multiple of 4 (which is a requirement of the format), it will be automatically padded (without borking the texcoords).
Hmm. QuArK requires that skin dimensions be a multiple of 8, and I never understood why original player.mdl skin does not follow this rule. Multiple of 4 makes more sense.
I know FrikaC made a cgi-bin version of the quakec interpreter once and wrote part of his website in QuakeC :) (LordHavoc)
c0burn
Posts: 208
Joined: Fri Nov 05, 2004 12:48 pm
Location: Liverpool, England
Contact:

Post by c0burn »

Quark is such a vile program.
mh
Posts: 2292
Joined: Sat Jan 12, 2008 1:38 am

Post by mh »

c0burn wrote:Quark is such a vile program.
The "Lotus Notes" of Quake utils. :evil:

This tool however seems to be a clear case of bringing on the awesome. Well done that man. :D
We had the power, we had the space, we had a sense of time and place
We knew the words, we knew the score, we knew what we were fighting for
Baker
Posts: 3666
Joined: Tue Mar 14, 2006 5:15 am

Post by Baker »

I'm eager to try this. Maybe some models I've made can finally make the trip from .md3 to .mdl (Quick3D didn't always succeed; the Quark route sometimes didn't work).

Thank you.

"Some more far-fetched major features for later versions: ...Convert MAP files (e.g. the health/ammo pickups) to models."
Twice as nice.
The night is young. How else can I annoy the world before sunsrise? 8) Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
mh
Posts: 2292
Joined: Sat Jan 12, 2008 1:38 am

Post by mh »

Baker wrote:
"Some more far-fetched major features for later versions: ...Convert MAP files (e.g. the health/ammo pickups) to models."
Twice as nice.
Only twice? That's something that's been sorely needed for a long long time.
We had the power, we had the space, we had a sense of time and place
We knew the words, we knew the score, we knew what we were fighting for
c0burn
Posts: 208
Joined: Fri Nov 05, 2004 12:48 pm
Location: Liverpool, England
Contact:

Post by c0burn »

mh wrote:
Baker wrote:
"Some more far-fetched major features for later versions: ...Convert MAP files (e.g. the health/ammo pickups) to models."
Twice as nice.
Only twice? That's something that's been sorely needed for a long long time.
http://qexpo.quakedev.com/uploaded/7/pak2.zip
Urre
Posts: 1109
Joined: Fri Nov 05, 2004 2:36 am
Location: Moon
Contact:

Post by Urre »

mh wrote:Only twice? That's something that's been sorely needed for a long long time.
It's been done many times by many people, I believe Tomaz did it first. I'm also assuming c0b's link above leads to a pak containing those as .mdl's, haven't checked :)
I was once a Quake modder
Post Reply