Andrew Giovannini discussed some of the useful techniques of hair production he’s learned during CGMA’s Hair Creation for Games course.
My name is Andrew Giovannini and I’m a 3D character artist currently living in Davis, California. I graduated with my bachelor of science degree in Media Arts & Animation in mid-2016. Right after graduating, I decided to make a shift and focus specifically on 3D character art for video games. For the last 2 years, I’ve developed my skills as a character artist through personal projects and taking courses through CGMA and Game Art Institute. From CGMA, I’ve taken Anatomy for Production, Introduction to Marvelous Designer, Animal Anatomy, and Hair Creation for Games.
Hair for games
When building the hair asset it’s important to focus on the overall form and silhouette and how the form is broken up giving the hair it’s depth and natural look. It’s extremely important to gather as much real-life reference early on and study the style of hair you are trying to achieve, carefully observing how the hair is broken up, clumping, the flow of the hair, and understanding how it naturally wants to fall into place. Good high-quality reference and observation of the areas where you’ll be able to see the roots, along the hairline are also extremely important. Everything has to be considered and planned out when it comes to how you create your textures and construct the layers of hair. The more time you spend gathering good reference material and understanding the construction of the hair in real life, the easier it’s going to be when it comes time to actually constructing the hair asset out of hair cards for the character.
Xgen is a procedural tool in Maya for creating instanced geometry along the surface of a mesh. It can be used to generate hair and fur, but can also be used to populate environments with grass, trees, and debris. It’s a very powerful tool with a lot of flexibility. For real-time hair, we use it at the beginning of the workflow to generate clumps of high-poly hair geometry. Xgen has built-in modifiers that allow you to procedurally control density, clumping, length variation, noise, and even things like curls and waviness. There are also tools that let you directly groom and manipulate the hair splines directly.
Once the hair clumps are generated with Xgen, they have to be baked down onto a flat texture for the hair cards. This can be done by either rendering the Xgen splines directly in Maya with Arnold or Mental Ray or by converting the Xgen splines to geometry and using xNormal to bake the textures on to a flat geometry plane. The method and approach depend on how the shaders are set up for the game engine, but there is a lot of flexibility. For Johan’s class, we baked the hair geometry onto flat planes using Xgen to create texture maps which utilize Epic’s realistic hair shader, which they created and provide for Unreal Engine 4. I’ve also created a video breakdown of the baking process with xNormal called “Creating Hair Textures for Unreal Engine 4” which can be found on youtube.
In my personal opinion, real-time hair is probably the most challenging and labor intensive part of a real time character to get right and to do well. Even with great tools like xgen, which help a lot with texture creation and the amazing advances in shaders, which help a lot to achieve great looking results, it still takes a lot of time to construct the hair from hair cards in a convincing way. This type of challenge is best overcome by carefully planning your approach from the beginning to reduce the amount of times you might have to redo anything, which is definitely going to happen at some points no matter what. Scheduling yourself and spreading out the workload over a period of time can help a lot too if you have that luxury.
First, the individual cards are combined and setup as hair clumps consisting of 2-3 cards each. Start out by creating an opaque base layer blocking in the overall structure and flow of the hair carefully following the references, while being sure to get good coverage over the scalp of the character’s head. Then begin laying down a breakup layer using less opaque cards following the general flow and structure of the base layer, but still looking for places to breakup the flow of the base layer based on your references. While laying down cards, it’s important to be mindful and keep the number of edge loops in your cards to a minimum, only adding edges where necessary to accommodate the bending and twisting of the hair cards. This helps to minimize the number of vertices to what is necessary and minimizes the impact on the framerate in the game.
This step is repeated at least 1 or 2 more times using less opaque hair cards each time for each layer. While constructing the layers it can also be necessary to make large adjustments to the overall form and silhouette of the hair using a lattice deformer… since adding layers on top of layers can end up making the volumes too large in certain areas. The final layers are also used to work out the transition areas along the hairline and introduce stray hairs and flyaways. Once all layers are constructed, the ambient occlusion is baked into the vertices of the hair cards on a layer-by-layer basis, which can help to add some depth to the overall hair assett inside the game engine.
The final asset is imported into Unreal as one piece and the realistic hair shader provided by Epic is utilized along with the hair textures baked out with xNormal to achieve the final result.
The biggest tip I can offer for hair and character creation in general is to slow down, plan, and take the time to understand the process. There’s always a lot of pressure to get the work done quickly, it’s understandable, but careful planning will always save you time in the long run and will help you learn more and produce better results.
Learning Johan’s process and workflow has been invaluable. After tackling the assignment for the course, I feel a lot more capable of producing many different types of complicated hairstyles for games, greatly increasing my value as a character artist and creating a nice portfolio piece in the process. My time with CGMA has overall been great. The talent hired to teach the classes is top notch and the format you guys have developed for deadlines, weekly feedback, video lectures, and weekly Q&As offers a lot of content for each course. I definitely plan to come back and take more courses in the future.