Research and Development: CG Hair

One of the hardest thing to do in CG is to get good hair that looks realistic/beautiful, renders beautiful, moves correctly, and renders quickly/in a manageable amount of time.  There are a lot of little nuances to hair and one such nuance is the color. People's hair don't tend to be just one color, instead there is a lot of little variation between each strand to give an overall full effect and to give depth and layer. Then there is the issue of how light bounces around between each strand on top of how the oils in hair causes variations in the specular shine as light falls across hair. Hair needs to be clumped and layered properly. There's been a big push to use dynamic hair where follicle strands are generated along a curve instead of just having a mesh. While the dynamics allows for a more naturalistic movement and animators wouldn't have to worry about follow through with a lot of finicky controls placed in the hair, in turn it tends to cause render time to increase.Seeing some artwork from "The Last of Us" I was tasked with doing some R&D on hair in that style to see how it would turn out. The Last of Us is a video game and the method that they used to create hair is to have many little polygon strips attached to the head. Then an artist would go in and paint each strip along with a transparency map to create the clumps of hair.

For my R&D I received some strips of polygons that were used as strips which I painted, and supposedly down the line the strips would be turned into nCloth for dynamics. It was an interesting experience as I have never done something like this before. In 2D paintings, when painting hair, you would block in the hair and then have a single area that would be the focal point and thus put all your detail into that one area. The rest of the hair would be left blockier to create the composition and create dimension to the painting. However as I am painting this on individual strips, each have to be equally detailed. From the initial render test there are some issues that could be seen. The hair strips that I were given were of a single width face so when smoothed all the edges will contract in which not only causes issue to the shape of the hair but also the ends where my transparency map resides to feather out the edges. The hair also really needs to be sculpted and groomed as seen in the models of The Last of Us where the strips of hair are made up of multiple faces and are curved and falls appropriately. Also, I tried to decrease some of the workload by stacking some of the UVs for the hair but it gives a very repetitive look to the hair so unfortunately each strand clump will have to be individually painted. There is also an issue with some of the hair intersecting some of the other strips so you can see a hard horizontal line cutting across some strips.

Then I did an updated version, still with quickly blocked in painted hair as I only had a week turnaround period. I added in two subdivisions to each strip so that they would retain their shape instead of contracting in. There is still the issue of how the hair strips end exactly where one would expect hair to end but upon this R&D we realized that the strips actually need to be larger/longer to allow space for transparency map to feather it out. Otherwise the transparency map will also be shortening the hair and bald spots appear, which can be seen on the side of the character's hair. I quickly made specular and bump maps out of the diffuse for some testing to see how well the hair would hold up from various distances. The painted hair method tends to work in close ups and medium shots but in far shots the bump becomes less defined and with the spec the hair starts looking like plastic instead of the nice striated spec the hair created.

The other path that we had taken and ultimately used was to use the same strips of hair as guides and extract curves from it and then attach Maya's nHair to it. The hair is groomed and layered properly unlike if there was just a single large mesh to use as a guide where an artist would have to try to cut and groom into a specific shape. Interestingly, it turned out it was quicker for someone to extract the curves than for me to paint the hair as I had four large maps to paint and they all had to be covered in hair.

I would say this method works well for games if you have a modeler to actually groom the hair strands and a good artist who can paint hair but I am not entirely sold on using this method for animated films that requires a lot of rendering, layer passes, and comping.