For this research project I decided to dive into hair cards and figure out how to make the hair style above. As a preface I have experience using Xgen and generating hair with that workflow and have never attempted hair cards so this was my very first attempt and it came out decently well. I'll go through the step by step process for the creation of the cards and the placement of them, there will be some dabbling in Unreal with getting a shader set up, but I unfortunately don't go too in depth on proper render settings due to time constraints and the scope of this project.
STEP 1: Reference Gathering/Blockout
your first step is to gather reference for your hair style, this is a good chance to find and observe different hair styles, as well as different hair types and how they can land on the head and on the body. I also gathered reference on how to build out the cards and what steps I should take for the blockout.
Here is my reference board it's definitely on the lighter side and I highly recommend going in depth on all of this to inform yourself on how to start on the best foot.
Once your reference is gathered it's time for a blockout. From my experience the blockout should stay as simple as possible and it's just to inform you on the overall style and volume of the hairstyle.
Here is the overall blockout, very simple and not incredibly detailed just informing the overall shape and volume. As a side note I did not make the character model that is going to be portrayed for this presentation, this hair project also served as a capstone deliverable for Crimson Knight.
I then go on and do a rough blockout of the hair card textures, this will serve as a guide for the actual generation of the hair cards themselves. This can be done in photoshop and again don't focus too much on the detail it's just to inform flow and shape.
Here is my hair card blockout, this went through tons of iteration and ended up changing quite a bit for the final result.
Step 2: Xgen Strand Generation
For this step I opted to use xgen to generate strands of hair that would then be rendered in Arnold to generate the actual hair card textures. First step is to set up your maya scene. Create a plane that'll have your blockout texture from step 1 on it. This is going to serve as your reference for generating hair strands within xgen.
Once that's done you'll want to create some planes that align with these separate clumps, the Xgen guides need actual geo to attach themselves to and for the final renders these can be hidden.
Once that is set it is imperative that you make sure your project is set correctly in maya. For Xgen to work properly you will need this to be set or else it will break on you and you'll be in for a ton of headaches.
Just hit new and name your new project, everything else should be left to default.
If something breaks in Xgen it's typically your project not being properly so be mindful.
You'll then want to go to generate up above and generate an Xgen Hair Description. You'll want to name your overall hair collection and then your description accordingly below I'll show the naming conventions I used to keep myself organized. Also make sure to hit placing and shaping guides at the bottom of the Create Xgen Description window.
Here is the naming convention I used for my collection and the following descriptions. Each separate plane will have it's own description attached.
Once you have everything set up it's all about placing and shaping these guides. I won't go too in depth on the specifics of Xgen so instead I'm going to link a video on what I feel is the best starter for learning Xgen and the basic modifiers you can use to create some hair strands.
Both of these videos are great examples in my opinion, the first one is a little bit quicker and the second is much more in depth with a full hair style created in Xgen. But for these I would pay attention more to the modifiers that they use and the way they set up their projects since it's very good practice.
I will also attach the modifiers stack that I used for these strands specifically.
Here is the modifier stack I used as well as some little tooltips. This slide is from a course that I took specifically for hair card and xgen workflow, I basically used these same modifiers to generate the strands.
Here is the primitive window as well and the preview/output window follow these as well and it should be a good base for all of your hair strands.
After finishing getting your hair strands created you should have something that looks very similar to this. It is important to know that your xgen clumps do not need to 1:1 match your blockout texture just make sure to not put too much variation in your clumps. You want these to be more generic since at the placement stage you can make variations happen.
Now that this step is done it is time to move on to baking the hair cards.
Step 3: Baking/Rendering
For this step we will be baking all inside of Maya, I do believe that you can get the best results directly from Arnold and they'll look very crisp it just requires a bit of patience.
The first step you'll want to do is create a new top view orthographic camera and bring it in very very closely since it's orthographic their won't be any focal length distortion and it keeps everything organized. You'll want to hide your planes as well.
On your reference plane you'll want to change out your material for an aiFlat material and set it to black.
You're then going to want to create an aiskydome light and assign it an HDRI. You can navigate over to polyhaven.com to get some free HDRIs.
These are going to be the settings I use for rendering, you can set the texture size to however you feel but I wouldn't go any lower then 2048x2048.
Here are my samples, I believe these are the defaults which worked perfectly for my use case, but play around with yours and see what results you can get.
Navigate over to the hypershader, here is where things will get a little complicated.
Here is where you'll make your color hair material, it will be using the aiStandardhair.
This shows the creation of the roots material using an aiflat shader.
Here is the showing for creating an ID shader also using a flat shader.
please follow this link to grab some AOV shaders to use in the creation of the normal/direction/AO maps. This is incredibly important so please make sure to grab these resources. You can always read through his blog as well and learn how to make these yourself!
albedo
Afterwards you'll want to make some custom AOV passes and name them accordingly. My custioms are AO, ID, Direction, Normal, Roots, Z depth can just be added from the available AOV passes.
You're then going to want to attach the shaders that you made into the AOV pass attribute editor, you'll see it under custom AOV and Shader, you'll have to drag it into the box or alternatively type in the name. This is going to allow Arnold to render these different passes.
For the alpha it comes packed into the EXR for the Albedo, Alternatively you can apply a white flat shader to your Xgen Strands and get the same result.
For the Z depth you'll need to lower the exposure to -2.5 in the Arnold render view and apply the exposure setting for it to correctly appear.
If everything renders correctly you should be able to get results that look like this:
Hair Card Placement and grooming.
First things first, you're going to want to download two very important things.
You'll want to install GS curve tools into maya. If you're at all serious about being a Character Artist I highly recommend grabbing this tool, it's absolutely fantastic and speeds up the process so much.
The second is watching this video and getting Frankie E.'s Maya scene which has an amazing set up for grouping your hair cards using GS Curve tools, the video also teaches you how to set up the scene with proper layers and grouping, as well as color coding your cards in Maya for organization. This video also teaches you how to use the UV tool that comes packed with GS Curve tools, as well as how to use the controls that Curve Tools generates for your curves. Trust me when I say this tool is probably the most important thing you can take away from this.
Once your workspace is set up and proper layers and naming conventions are in it's all about placement. There is no rushing this part. This is all about patience and getting into the zone and just locking in. But the general gist is to build up. Your first layer is going to be your coverage layer, this should cover your entire scalp and shouldn't have any peeking from your scalp. Pair this with a hair cap to get even better coverage. Intersecting doesn't matter much here since most of this will get covered.
My next layer is building on top of my base, this is also for more coverage as well as opening up the volume a little bit for the hair. Preferably no intersecting but some is okay on this layer.
My third layer is mixing in a bit of break up with some smaller clumps, this is where layering starts to happen, and it is absolutely vital that none of these cards have any sort of intersection with other cards.
My next layer is even more break up as well as cross sectioning small clumps of hair to add the illusion of layering. Intersections here should be avoided but if there is it's not a total end since these tend to be smaller clumps and are harder to individually see.
My last layer is flyaways. These are small little strands of hair that add a bit of extra dimension and believability to your hairstyle. Intersecting here is not something to really keep an eye on since these are so small, but do your best to still avoid it.
Afterwards I did kick the cards back out in zbrush just to shape them more to my liking, this step isn't necessary but it's something I had to do.
Now that this step is over all there is left to do is to kick it out into Unreal and get the material ready.
Step 4: Unreal Presentation.
As a side note I will not be going over how to set up a lighting scene in Unreal Engine as well as camera set up.
Also once everything is set up in Unreal it's perfect to start going back and forth between Maya and Unreal to make adjustments and to keep working on your hair style.
For my hair material I used the hair material that Epic made back in Unreal 4.27, even though it is old I found it perfect for my purposes and it was super easy to work with.
These are the hair parameters I used as well! It is very drag and drop and each map you have exported will be used in this shader.
That is basically the gist of this project and the steps that I took to create the final look! I hope this is somewhat helpful!
No comments:
Post a Comment