[GZDoom/Blender 2.79] MD3 Export, Size Reference Template

Any utility that assists in the creation of mods, assets, etc, go here. For example: Ultimate Doom Builder, Slade, WadSmoosh, Oblige, etc.
Forum rules
The Projects forums are ONLY for YOUR PROJECTS! If you are asking questions about a project, either find that project's thread, or start a thread in the General section instead.

Got a cool project idea but nothing else? Put it in the project ideas thread instead!

Projects for any Doom-based engine (especially 3DGE) are perfectly acceptable here too.

Please read the full rules for more details.
User avatar
Nash
 
 
Posts: 17434
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by Nash »

Enjay wrote:I meant to attach this earlier and just didn't.

http://www.mediafire.com/download.php?9klk7ja169bljkr

It may be useful for illustrating the scaling thing that Nash and I were discussing.

Image

Its a map and a simple box model. The box, according to the model editor, is 128x128x128. It has been used for two actors. In one actor (using the Baron marble face texture as a skin) it has a scale ratio of 1.0 1.0 1.0. The same model is used again with a ratio of 1.0 1.0 1.2 and uses the other (archvile?) marble face. In the map there is a box made from sectors that is 128x128x128 Doom units and has the pentagram marble face on it. In the map you can see that both models match the width and length of the Doom sector boxes but the 1.0 scaled Baron one is shorter whereas the 1.2 scaled archvile(?) one is the same height as the sector box.

The model-based actors have been left as non-solid so that you can wander around more freely looking at stuff. You can also see some nice z-fighting on the inside of the box. :P

Yes, and the code responsible for the short Baron box is - as demonstrated a few posts back - inside gl_models.h. I don't know why it's doing that, but that's the way it is. So to counter that, a Z ratio of 1.2 has to be applied in the actor's MODELDEF.

Interestingly enough, if you mod the GZDoom viewport renderer to draw square pixels (gl_scene.cpp), the 128x128x128 sectors (the one with the pentagram) will look perfectly square/cube, BUT the Baron box model will STILL be squashed.

So the conclusion here is that the code that draws models in GZDoom is working independantly of the viewport renderer.
User avatar
Enjay
 
 
Posts: 26517
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland
Contact:

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by Enjay »

I haven't got around to trying a modified gl_scene.cpp myself yet but your conclusion is an interesting finding.
User avatar
Nash
 
 
Posts: 17434
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by Nash »

Just a small bump. I discovered that the object cannot exceed 511 Blender units or the exporter will fail. So to create really large objects (like mountains, etc)... just be sure the dimensions do not exceed 511 Blender units in all axii, export, then scale it up in MODELDEF. I tried taking a look at the scripts but haven't figured out how to fix this. It's apparently a limit with one of the data structures used in the whole thing (SHRT_MAX?) and I don't think it's fixable from the script.
User avatar
LilWhiteMouse
Posts: 2270
Joined: Tue Jul 15, 2003 7:00 pm
Location: Maine, US
Contact:

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by LilWhiteMouse »

Nash wrote:Just a small bump. I discovered that the object cannot exceed 511 Blender units or the exporter will fail.
Is this perhaps a MD3 limitation? I can't speak for Blender, but saving a model that exceeds that limit in Misfit Model 3d as an MD3 screws up the vertexes.
User avatar
Nash
 
 
Posts: 17434
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by Nash »

If that happens with models exported from Misfit too, then that may very well be the problem then.
Gez
 
 
Posts: 17833
Joined: Fri Jul 06, 2007 3:22 pm

Re: [GZDoom/Blender] Size Reference Template

Post by Gez »

Nash wrote:The code that renders the pixels to the screen, and the one that draws the models are separate.

You can try this yourself. To get the renderer to draw 1:1 pixels in the viewport, open gl_scene.cpp, look for #define RMUL (1.6f/1.333333f) and change it to #define RMUL (1.0f)

Now you will have 1:1 scaling in the 3-d view, but the models are still being squashed vertically in gl_models.h
The latter is there to compensate for the former. In technical terms, this is what people in the know refer to as a "hack". :P

Looking at Enjay's screenshot, the midgety Baron face in the marble row is the only one that is visibly square.
User avatar
leileilol
Posts: 4449
Joined: Sun May 30, 2004 10:16 am
Preferred Pronouns: She/Her
Location: GNU/Hell

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by leileilol »

The size problem is a limit of the MD3 format intended for more precision.

Also don't worry about trying to satisfy this for Quake editing - the 2.6x MD3 export lacks empties for tags support and is more annoying to use. I still have 2.49 installed for MD3 exporting with a special edited version of the MD3 script that truncates .001's etc for LOD meshes.
User avatar
Virgil
Posts: 154
Joined: Sun Sep 28, 2003 10:01 pm

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by Virgil »

I still plan to revisit the GZDoom engine for map design, so I am very much interested in this. However...

I can't download any of the scripts/files, because the links are dead. :(
User avatar
Nash
 
 
Posts: 17434
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by Nash »

DRDTeam is currently down. They will be back online soon.

note t self: read the documentation from script author regarding scale http://forums.duke4.net/topic/5358-blen ... _p__124627
User avatar
Nash
 
 
Posts: 17434
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by Nash »

Thanks to NeoHippo for uploading these to MediaFire

http://www.mediafire.com/download/tly76 ... _Export.7z
User avatar
NeuralStunner
 
 
Posts: 12325
Joined: Tue Jul 21, 2009 12:04 pm
Preferred Pronouns: He/Him
Graphics Processor: nVidia with Vulkan support
Location: capital N, capital S, no space
Contact:

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by NeuralStunner »

Just tried this out yesterday (in Blender 2.68a) and it worked great! I managed to make, map/texture, rig/animate and export a model, and got everything working right in GZDoom. :)
User avatar
Nash
 
 
Posts: 17434
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by Nash »

Oh it works in 2.68a, great. I haven't updated yet.

Just don't make your model too small (or its vertices will deform) and don't exceed 511 Blender units in any axis and you'll be fine. If you need to make really huge objects in GZDoom, scale it up using MODELDEF.
Battlelord
Posts: 15
Joined: Thu Aug 23, 2012 2:24 am

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by Battlelord »

hallow everyone
I have uses blender 2.63 with (io_exporter_md3 2.63) to exports md3 model. the models exported succesfully only when It's rigid, but when I tried to export any part of model which is movable with a frames an error heppened as well the Image will show up ..... any Ideas :? ?
Attachments
Md3.JPG
User avatar
Nash
 
 
Posts: 17434
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by Nash »

Post the problematic .blend file please.

Also: this thread is about the GZDoom exporter, not the generic MD3 exporter. I don't have any experience using io_export_md3.py.
Battlelord
Posts: 15
Joined: Thu Aug 23, 2012 2:24 am

Re: [GZDoom/Blender 2.66a] MD3 Export, Size Reference Templa

Post by Battlelord »

Also: this thread is about the GZDoom exporter, not the generic MD3 exporter
what is the gzdoom exporter using for? Md3 exporter case is most important case of gzdoom exporter
Allright here is file.blend
http://www.mediafire.com/?d2gyg61v3530q11
Post Reply

Return to “Creation, Conversion, and Editing”