I’ve alluded to this a bit over the past few days, but my current non-work project is to make a program for animating 3d characters. At work, I maintain software that does this already, but I didn’t write that part of the code. For the most part, the character animation is driven by Renderware, which a fairly large and popular cross-platform graphics engine. It’s nice to be able to hand off complex tasks to a graphics engine and say “make all of this confusing stuff work and don’t trouble me with the details.” When developing commercial software on a schedule and a budget, it’s just the thing.
But I’m filling in various gaps in my knowledge and so I want to know how to do this myself, from the ground up. This means putting some of my crude, self-taught trigonometry to use. It also means getting some 3d data to work with.
|Top: Vertices are the dots that give the figure shape. Bottom: Triangles are lists of points to connect, which will eventually turn this thing into a solid shape.|
So now I need to decide what 3d program to use to make this stuff. Part of this decision will involve what sorts of 3d files the program can save. 3D models are made up of predictable things. There are points (verticies) and there are triangles (each of which plays connect-the dots with 3 particular points) uv values (information about how the texture lines up on the model) the skeleton (another collection of points, which define all of the joints in the body, where their pivot points are, and how they relate to each other). There is lots of other interesting data, but this is the critical stuff that every program needs before it can draw a 3d model.
Every 3d program has its very own file format, a method for storing all of this stuff. Some are very nice to use. It’s just a list of verices, followed by a list of triangles, etc. Others are more obscure, or have lots of extraneous data mixed in that must be weeded out. Still other files formats are “closed”: Nobody outside of their creators know how they work, so they can’t be read by any external programs. Such as mine. Some are dense, complex, tricky, poorly documented, or otherwise difficult to read. Some are easy to read but don’t preserve the most complex data – the information that ties the body to the skeleton. Since that’s the whole point of the project, I can’t go with any file format that leaves this out. File formats that are both robust AND easy to read do exist, but they are rare and not all programs support them. So, this is going to be tricky.
My budget right now is $0.00, and 3d programs tend to hail from the $500+ price range, so there’s another snag. Even if I do find a program that supports an easy-to-read, well-documented format that has what I need, it might be way out of my price range.
Well, Let’s see…
I own a copy of Truespace, so it’s “free”, but I’m not going to use it for this unless I have no other choice. It’s a poor tool for this particular task, and the file format is difficult. It’s nice to know I have this to fall back on, but I’d like to see if I can find a better tool for the job.
Content Paradise had a promotion where they were giving Poser 5 away for free, and I managed to grab a copy. As of right now the free promotion is over, but they are selling the program for $20. That is $230 less than the usual price. I don’t know what inspired this fire sale, but that’s still a good deal.
Poser isn’t a 3d modeling program per se. It’s for posing very realistic super high-polygon figures. Not really ideal, but it does have moving 3d human models and an export feature. It should at least give me my 3d figures, although I’ll have to look elsewhere for the animations that drive them.
I was able to export one of the low-poly models into 3DS format. (Pictured above) 3DS files are a bit unwieldy. They certainly aren’t a nice neat list of points, triangles, and such. The 3DS file is packed with useless stuff about window layout, light placement, camera settings, and a bunch of crazy stuff that I don’t want or need. Still, the format is documented, so I sit down and spend a few hours implementing my own code to read 3DS files.
At the end of a lot of confusion I discover a nasty little secret: Poser leaves the skeleton off when it exports. Suddenly this animated 3d guy turns into an unmoving statue, and the data to get it moving is gone. Some Googling reveals that this is the case for all formats for all versions of Poser. The program leaves this info out on purpose.
Well, at least I didn’t pay $250 for it.
I tried Blender, and eventually dismissed it for reasons belabored elsewhere. I really, really did think this was the right program for the job, which is why I gave it so many second chances. It’s open source. It LOOKS impressive. It’s feature-rich. And if you want an open file format, then an open-source program should be the place to go, right?
In the end all those second, third, tenth chances only fueled my rage and led to my intemperate and (I hoipe) uncharacteristic posts. I should have given up much earlier on. It was clear the thing just wasn’t going to cut it and I just had a mental block about the thing. I just couldn’t imagine OS software that was this bad. I must be missing something? Doing something wrong? It can’t be this useless, can it?
Yes. Yes it can. This is not the program you’re looking for. Move along.
Maya retails for about $400 or so, but Unreal Tournament 2004 came with a special limited version of Maya that had some of the high-end features disabled, and it put an annoying watermark over the 3d viewports. It was like looking at your work through a stenciled window. These programs are tough enough without that visual distraction. Also, I think the export functionality was crippled or removed in this evaluation / learning version.
I like the idea of a learning version, but this isn’t going to meet my needs. The $400 price point is WAY out of my budget, so I have to give this one a pass.
Milkshape is an odd duck. (No offense). Instead of being aimed at professionals, it is aimed at home-brew developers making game mods. Where most 3d programs have export options for various obscure file formats, Milkshape has stuff like, “Export to Doom 3”, “Export to Half-Life”, “Export to Max Payne” and so on.
The interface is alarmingly simple:
|Milkshape isn’t fancy. She might not look like much, but she’s got it where it counts. Here you can see I’m adding a skeleton to the model so that it will move. The model is bent oddly because I did something wrong and the skeleton isn’t properly attached yet. When it’s working right, the skeleton will stay inside of the model!|
Still, simple is good. Building a full 3d human with this would be really tough. Blender seems geared to very low-poly work, like making models in the 1,000 polygon range. That’s about the polygon budget of games released around 1999 and 2000. However, Milkshape does import 3DS files. So, I can take my non-animated guy from Poser, bring him into Milkshape, and manually re-create the skeleton. It’s dull work, but it will get me where I want to go and save me the time I was going to have to spend modeling a human.
But what about saving? All of this does no good if I can’t save in a format that my program can read. Well, it turns out that Milkshape has a wonderful text-based format. There is documentation on it, but I hardly need it. After a a quick read through a file I can intuit what the numbers mean. It’s all very easy and sensible.
The price point is $25, which is very reasonable. I know this project has a budget of zero, but I think this program is worth $25. Even if it doesn’t pan out, this thing looks to be a labor of love and has more than $25 worth of features. So, I found my 3d program.
After days of work, I’m finally ready to start!
This Game is Too Videogame-y
What's wrong with a game being "too videogameish"?
The Witch Watch
My first REAL published book, about a guy who comes back from the dead due to a misunderstanding.
Resident Evil 4
Who is this imbecile and why is he wandering around Europe unsupervised?
TitleWhat’s Inside Skinner’s Box?
What is a skinner box, how does it interact with neurotransmitters, and what does it have to do with shooting people in the face for rare loot?
Why Batman Can't Kill
His problem isn't that he's dumb, the problem is that he bends the world he inhabits.