Tuesday, October 6, 2009

3D diplodocus techniques; uv mapping

A common issue when texturing 3D models is stretching and mismatched resolution of uv maps. As I just encountered this on my diplodocus and some interest has been expressed in 3D techniques, I thought I'd share here. looking at the uvs alone, both uv layouts might look fine, but applying a checkerboard reveals that the first is badly distributed (the surface distribution is not consistent with its 3D counterpart).
In this case, I solved the problem by stretching the layout about and by creating a new problem - a seam. Seams are bad, and I try to avoid them, but this guy's neck is just too long. I could have also tried to lay out the geometry long - then stretched the result into a square, but the legs were too blocky for an elegant layout in that direction.

As I'm always out to use every possible pixel, I want to pack my uvs fairly tightly... you don't necessarily have to be as anal as I am. This is already packed into the square uv coordinates required by my 3D software, I work with a rectangle format until I'm happy, then squish it into a square. I use proportions of the original rectangle for my image however... as it also gets projected onto the 1:1 uv coordinates during render, you have respective resolution.
Let me know if this type of making-of post is welcome or not... I feel that I might be crashing a party.

another w.i.p. view, here the untextured, unsculpted model:


Weapon of Mass Imagination said...

This totally fits in with ART Evolved's mission statement of promoting and educating about Palaeo-art!

Can not wait for the next installment... Plus I'll have to jump in with how I UV map my 3D stuff...

Cheers David!

Peter Bond said...

Hi David, post away! On thing for the non-CG artists out there (me included): What is a uv map? (I am assuming it's not "ultraviolet"...)

davidmaas said...

I'll be doing some 2D wips, too! (see my concept sketch).

A uv is a 2 dimensional 'map' of the polygons in your mesh. A polygon can be a triangle, rectangle or - in some packages - polyangle, but they all have a surface defined by x points called vertices. Each vertex in the 3D mesh has an x, y, and z value. In the uv mesh they only have 2... a horizontal 'u' value and a vertical 'v' value. (Why the inventors took 'u' and 'v'? No idea.)

In other words, the skin of your model is skinned and flattened out.

This allows a 2D pixel image to be projected onto the surface with control over each poly's surface distribution. An image could also be projected from the front for example, but then the polys facing upward receive less pixels than polys facing forward.

There's a new technique on the horizon where the poly volume itself is calculated. Fantastic, except that you'll no longer be able to rely on 2D editors such as photoshop to texture... it all has to be in 3D.

Peter Bond said...

Cool! Thanks David! Looks great!

Glendon Mellow said...

The face is so expressive! Excellent. Definitely not party-crashing.