Polygon buffering/offsetting?

Also made a forum thread

My iPhone game can already build meshes but they use a single texture – I want to automatically apply a different texture to the edges. There seems to be two main goals – smart mesh creation and smart UV mapping so that the texture is mapped appropriately. I have no idea where to start for UV mapping, but this thread offers a starting point for generating the meshes (NOTE: I need to go inward to get the edges, unlike the example in that thread.

What I’m kind of lost on is how I’d check for tight spaces so that the boarder
a. doesn’t extend outside of the original mesh’s space
b. doesn’t overlap with other parts of the boarder

What I want:
alt text

or

alt text

Examples found in other games:
alt text
alt text
alt text
alt text

How do they do it?

Edit: 2D Straight Skeleton and Polygon Offsetting looks like what I’m looking for is called Straight Skeleton

This is probably not the way you want to do it, but you could just go to your texturing program (say Photoshop) and add those side details in? It’ll save you a headache wondering about it.