APOCALYX is a...

free Game Engine based on OpenGL (MAIL) (SITE) (FORUM) (BLOG)

Saturday, April 12, 2008

MDL vs MD2 performaces

I was still evaluating good animated models for GUN-TACTYX-2, my QUAKE3-style CROBOTS-like game. This time my idea was to develop a more realistic game. The first GUN-TACTYX performed a very original MD3 model (the Wrokdam model by Grant Struthers) that gave a suggestive background to the game, but also little emotive involvment in the fights among cyborgs. Instead realistic models add more atmosphere and an improved player's attachment to his team of bots. That's why I am evaluating several kind of models available on the internet.

Since I'm oriented towards the usual, inflated WW2 background, my choice falls between the models of "The Trenches" MOD for Half-Life 1 and the models of the "DDay" MOD for Quake2. The models of the latter are worse, if seen at short distances, because of the limitations of the MD2 model format, but I thought that they were going to be better to keep frame rates high. In fact, an MD2 model is very simple: one need to attach only a single texture and render only triangle strips or fans already optimized for OpenGL strips and fans. On the contrary, MDL models are more complex and better seen at short distances: they need several textures, lots of triangles and the animations based on skeletons require chains of matrices multiplications.

Because I need a lot of models around of the battleground, I thought that MD2 models were lighter, but I was wrong. In the pictures below you can see a square of 36 WW2 USA soldier in MD2 format (from "DDay" MOD) against 32 british and german WW1 soldiers in two rows (from "The Trenches" MOD). Surprisingly the frame rate is roughly the same. I don't know yet which is the cause: the poor code of the MD2 animator, the good code of the MDL animator, or the relative heaviness in triangles count of the two kind of models.
However, this first test gives more points to the better looking, more versatile MDL models.

32 WW1 british and german soldiers in two rows (MDL format)

A square of 36 WW2 USA soldiers (MD2 format)

No comments: