I am using Joan of Arch tutorial but keeping polycount in consideration. I want to give my first female head a kind of peekaboo haircut:
http://www.hair2009.info/wp-content/uploads/2008/10/68.jpeg
Regardless of if it is specifically for this style (though that would be great), do you know of any tutorials talking about hair theory and how to model it with planes? I get the basic idea, but I am could use some theory to bump me in the right direction.
Replies
Just try modelling it with some planes man, if you get the basic idea. Experiment and post your results!
http://www.paultosca.com/varga_hair.html
Yea sorting can be a bitch even in offline rendering it takes forever to sort all that out and render shadows accurately. Most render'ers take the geometry into account, not what is painted in the transparency map, until you force certain settings, then it takes even longer.
For real time try to stick to:
Alpha test: Pixels will be evaluated as Black or White, On or Off greyscale is rounded up or down, this is the default for transparency in Unreal. It's pretty quick and probably the method you should work around. That's not to say you can't have nice soft grayscale transparencies, just make sure it will "alpha test" well.
Alpha sort: Grayscale determines the opacity of the pixel, this becomes increasingly complex to calculate the more partically opaque pixels you stack in front of each other. Toss in shadow casting and you're going to be sitting there a while. Most engines will cut off and ignore at a certain level of stacking.
You also have to remember that your character being a dynamic moving object could walk behind or infront of a transparency so if your engine is set to cut off at 3 levels deep, you probably only want to stack 2 levels on the hair. But that is getting all very engine specific so you'll have to cross those bridges when you get to them.
Instead of going the highly accurate way of having the opacity map influence shadows, you can stick to keeping the geometry as close to the shape of the hair as possible. This means instead of using a bunch of big cards with large transparent sections painted out, use a little more geo to get the shape right, and use the opacity map to rough up the tips. This also saves on wasted UV space and casts pretty accurate shadows based on the geo which is cheaper then using the opacity map. It also helps keeps the number of big transparent pixels.
Some engines also have trouble with intersecting planes of transparency like 2 polys forming a +. The problem comes from a plane being in front of and behind at the same time. So instead of two planes intersecting, you probably want 4 and they just meet in the middle. So be careful how much intersection you have going on.