Home Technical Talk

Hair Creation - Struggling with Specular

DustyShinigami
polycounter lvl 4
Offline / Send Message
Pinned
DustyShinigami polycounter lvl 4
Hi

I'm currently following Johan Lithvall's Hair Creation for Game Characters course. He suggested I add a bit more variation for the specular to make it a bit more interesting. I've baked out a couple of extra Height maps (using xNormal) to composite with in Photoshop, but I'm actually really struggling to do it. :s I've been trying to use Blend modes, Adjustment Layers - such as Brightness/Contrast, Hue/Saturation, Levels, Curves etc. - but they're either not working, or I'm not getting a good enough result. I just have a complete mental block at the moment and I'm unsure how to proceed.

He suggested something like this using Hue/Saturation and Brightness/Contrast:

I have a few Adjustment Layers stacked above some Height maps in my Photoshop file. Some of those appear to only be making a subtle difference. But adding anything else just isn't doing a lot. And I certainly can't get some interesting breakups like in that image.

And this is what my hair texture currently looks like, along with the Alpha and ID map:





I also have some Gradient and Root bakes too. And then here are a couple of the extra Height maps I did to add some more specularity:



Any help or suggestions would be greatly appreciated. :) Thanks.

Replies

  • thomasp
    Offline / Send Message
    thomasp hero character
    To get variation into your maps you can overlay other bakes. A subtly overlaid ID pass, a depth bake, something like that. Keeping the roots darker in the specular is a good idea in my experience so perhaps try overlaying the gradient bake too. The color map will need plenty of variation too in most cases.

    Beyond that - your render output looks jaggy, it needs to be be smooth. And your hair elements are very dense, practically opaque. That will make it really hard to layer and blend them, I bet you'll be able to practically count the haircards used on the finished piece.

    If you check out the small piece posted as the first image, that's much more the kind of density you should be targeting, along with plenty of builtin shape variation. If everything is just more or less straight lines of the same length, it'll not look like hair when put together.

    You might be better off following my standard advice: forget the baking for now - paint some placeholders first in photoshop or a vectorgraphics package and try to use them in a simple hairstyle. Worry about proper textures later when you know what your hair elements should look like.

  • DustyShinigami
    Offline / Send Message
    DustyShinigami polycounter lvl 4
    Thanks for the suggestions. By render output, do you mean my first image - the diffuse...? Or the other bakes - Height, ID etc.? I have been thinking that a number of my hair chunks are a bit thick, although I was trying to mimmick the chunks from the videos I've been following, which are these:

    I did make three additional ones too. And I've combined 2-3 cards together to get more varied results, like these:





    The textures were done a while ago now. :) I'm currently finishing up the second layer of the block-out. And this is how it's looking at the moment:




    So I'm just after some fine-tuning with them really. To give them a bit more specularity.
  • DustyShinigami
    Offline / Send Message
    DustyShinigami polycounter lvl 4
    Actually, a part of me now is completely full of doubt. I'm wondering if I should scrap it all and start again. There's something about it I'm not happy with and a lot of my hair cards do look quite skewed and blocky from struggling with the modifiers and twisting things out of shape. Along with reducing the tri count by removing edges. :-\
  • kanga
    Offline / Send Message
    kanga quad damage
    The hair strands are waaaaay too thick in the last example. Try scaling the textures in the x axis, by as much as 50%. Your hair is also dead, no specularity or gloss to be seen.
  • thomasp
    Offline / Send Message
    thomasp hero character
    What I meant was to mix diffuse and specular bake outputs with other bake outputs to get color/value variation in there and export the result out as new diffuce/specular maps.

    I have to say though judging by the screenshots that's the least of your worries right now. The hair cards look like wet cardboard to me, IMO you'll need to experiment much more with the textures, overall coverage, strand thickness, messy-ness, tapering of clumps, etc. Mockups would be the easy answer here.


  • Eric Chadwick
    You need an IBL here otherwise you will never be able to see specular at all! A studio HDR for lighting would be a good place to start. https://polyhaven.com/hdris/studio


  • DustyShinigami
    Offline / Send Message
    DustyShinigami polycounter lvl 4
    thomasp said:
    What I meant was to mix diffuse and specular bake outputs with other bake outputs to get color/value variation in there and export the result out as new diffuce/specular maps.

    Ahh, gotcha.

    I have to say though judging by the screenshots that's the least of your worries right now. The hair cards look like wet cardboard to me, IMO you'll need to experiment much more with the textures, overall coverage, strand thickness, messy-ness, tapering of clumps, etc. Mockups would be the easy answer here.

    Ah. :-\ It could be to do with the material I have set up. I was after a similar sheen-like effect the guy in the video was using.


    This snap was taken from one of his videos. He said it was just a standard material, but with the Type set to Anisotropic. It could be the values I've set...




    And this is just with a standard Lambert material:


    Regarding mock-ups though - what with how much and how far I've come with the course/tutorial, I think I'd prefer to carry on with it and see the project through to the end, just to learn the workflow shown. ^^; Any mistakes made at the beginning, I'd rather improve when attempting a new project from scratch. :) Although, I don't mind tweaking/adjusting the texture in Photoshop. If I can, I can always upload my Photoshop file for someone to peruse. I have used baked gradients to adjust the root and tip thickness...

  • DustyShinigami
    Offline / Send Message
    DustyShinigami polycounter lvl 4
    kanga said:
    The hair strands are waaaaay too thick in the last example. Try scaling the textures in the x axis, by as much as 50%. Your hair is also dead, no specularity or gloss to be seen.

    Sorry, I'm a little confused by this. Do you mean to scale the hair cards themselves or the actual texture in Photoshop...?

    Looks like I really need to add some specularity then... lol
  • DustyShinigami
    Offline / Send Message
    DustyShinigami polycounter lvl 4
    I've discovered one thing I did forget to do with my Photoshop file - I didn't enable my ID (maps) folder. Having that overlayed as helped with its overall look, but I'm still not having much luck with the specularity.





    I did try adding a Noise filter in Photoshop, but it could barely be seen to be worth bothering with. :-\ No amount of tweaking in Photoshop is giving me anything decent. I'm still really unsure. :s

    Also, some of the jagged-ness could be down to me removing some edge loops...? I did originally add some centre ones - going vertically down the card - but I've deleted them, or removed some edges, to try and reduce the number of tris. I'm wondering if I should re-add them...?

    Also also - one thing I have failed to mention, is that all of this will be setup in Unreal, with hair shaders applied. So I presume a lot of the specularity will be controlled via parameters anyway...?
  • DustyShinigami
    Offline / Send Message
    DustyShinigami polycounter lvl 4
    Thinking about it, I could just bake out an Ambient Occlusion, right…? And then overlay that with a Levels in Photoshop. The course videos I’ve been following don’t actually cover or show the guy adding any specularity, which is partly why this has all been so confusing. His final texture he imports into Maya looks pretty flat to be honest. But in a later video they’ve changed.
  • DustyShinigami
    Offline / Send Message
    DustyShinigami polycounter lvl 4
    Hmm... This is what it's currently looking like with an added AO over the top and a slight Levels adjustment. Does this look a bit too much, perhaps...?


  • DustyShinigami
    Offline / Send Message
    DustyShinigami polycounter lvl 4
    Could someone clarify if the changes made have improved it at all...? I'm still really unsure and stuck with this. :-\
  • thomasp
    Offline / Send Message
    thomasp hero character
    Not really possible to say when looking at padded textures. If this needs to go into Unreal then it will need to be adjusted with that engine in mind and on the model.

    Btw. the jagged look I was talking about is not in regards to geometry - different issue - but rather bake output quality. You have no antialiasing going on like in my example on the left:
    Unreal's hair shader will eat your texture.
  • DustyShinigami
    Offline / Send Message
    DustyShinigami polycounter lvl 4
    Oh. :anguished: Hmm... Well, this is how it's looking without the padding...

    I'm not sure how old the tutorial videos are that I'm following, but I do remember Johan setting the Anti-Aliasing to x1 in xNormal. Not quite sure why. So naturally, I followed what he did.

    EDIT: Looking ahead at the next batch of videos, one involves extra tweaking of the texture in Photoshop. Scrubbing through it, it looks like the guy adds some blur, so that's probably his way of dealing with the lack of anti-aliasing.

    EDIT 2: Yep, just started watching the video and he adds three types of blur to fix the anti-aliasing issues. So that's why they appear jagged. :)

    How exactly will Unreal's Hair Shader eat my texture?

    EDIT 3: Just noticed at the start of one of the videos that they were done in 2016, so some of the methods are probably a bit old now.
  • DustyShinigami
    Offline / Send Message
    DustyShinigami polycounter lvl 4
    Playing around with my Photoshop file, I did notice as well that my Root/Gradient bakes were having no effect with my ID bakes enabled. I've adjusted a few things and got them working with everything again, so this time the roots should be a bit darker than they were before.

    The other question is - when overlaying my AO bake, should I set it to Soft Light, like it looks above - or put it to Overlay...? With Overlay, there is a bit of light/colour variation.

    It does look a bit saturated though
  • BagelHero
    Offline / Send Message
    BagelHero interpolator
    With this kind of workflow, I'd venture there's not really a "correct" setting or choice to make here, just what looks better to you.

    I prefer the overlay result here, personally. If the saturation on the darker colors isn't what you want, you can either tint the AO very slightly to a contrasting color (in this case, a dark blue) to give the appearance of something more neutral, de-saturate the base color a bit, or add a color correction adjustment layer on top of the whole stack to get the colors you want after the fact.
  • DustyShinigami
    Offline / Send Message
    DustyShinigami polycounter lvl 4
    BagelHero said:
    With this kind of workflow, I'd venture there's not really a "correct" setting or choice to make here, just what looks better to you.

    I prefer the overlay result here, personally. If the saturation on the darker colors isn't what you want, you can either tint the AO very slightly to a contrasting color (in this case, a dark blue) to give the appearance of something more neutral, de-saturate the base color a bit, or add a color correction adjustment layer on top of the whole stack to get the colors you want after the fact.

    Thanks. :) I did try playing around with the hue/saturation with an Adjustment Layer, but it wasn't having any effect. Only the brightness/contrast does. I'll try tinting the AO. And a Colour Overlay using a Layer Style.
Sign In or Register to comment.