Jump to content

Hair problems


Janders

Recommended Posts

Hi there! I was testing different kind of materials wen I reached a bottleneck... Yep hair.


Here some examples;



http://oi57.tinypic.com/2sbk9ag.jpg

Here I was playing with the Alpha Threshold but basically looks like s**t... Well, at least cast shadows.



http://oi60.tinypic.com/2zxxlcg.jpg

And here I tried with blend modes, it looks kinda "correct", but it doesn't cast shadows and doesn't have z hierarchy.


I tried various combinations of settings but I wasn't able to make it look right. So... Any help?


Please don't say to me to write a shader, I have no skill on that matter. :cry:

Edited by Janders
Link to comment
Share on other sites

Yeah, hair is always gunna be tricky to render in a satisfactory way, I know even MGS5 just pretty much went 'screw it' and doesn't render the hair shadows.


Can you post up a shot of a cranked up alpha threshold? That's usually the go-to on doing transparency like that, so it not working properly is kinda odd. It may be a texture format issue or something.

Link to comment
Share on other sites

Translucent Transparency (like LerAlpha) and shadows don't go along with each other. Remember T3D is (currently) running on DX9!


If you still want the shadows you'll need to turn translucent blending off. You're already working with a alpha channel, so you can make the background of your diffuse map the same colour as the hair to avoid the obvious artefacts. Further can you add a bit of subsurface effect (white!) to brighten up the dark sides; but not too much to avoid it to be lit up in low-light levels/environments.


Personally I don't mind not having shadows for hair, but never used long-haired characters before.

Link to comment
Share on other sites

Yes, I have read the post, but there is only those options. Since there is black left in the first image, you need to add more alpha treshhold.

What you should do in addition is fill the alpha channel with the color of the hair and not with black, here is a tool that does this automatically: http://www.reinerstilesets.de/programme/halo-remover/

This will get rid of the black outer lines if you use alpha treshhold, your other option is to use transparency and have no shadows at all, but I think alpha treshhold with halo removed will be the best option.

Link to comment
Share on other sites

After much messing around I think i got something acceptable.


First of all, transparencies MUST be .png, I don't know why but other formats will cause issues.


The eyelashes I fixed them applying 4 layers of LerpAlpha.


Finally something than at least isn't darkened by the Alpha Threshold.

http://oi60.tinypic.com/10pwyyq.jpg

Alpha Threshold alone It looks meh.



After that, I duplicated the hair mesh and i applied Alpha Threshold to one material, and LerpAlpha with 2 layers to the other mesh.

This Is the best looking so far but it has 2 terrible flaws... It can't receive shadows and it duplicates the hair polycount.

http://oi58.tinypic.com/xmrjag.jpg

Alpha Threshold + LerpAlpha



Shadows of the first method vs the second one.

http://oi58.tinypic.com/2w5lonq.jpg

The right one (Alpha Threshold + LerpAlpha) receives shadows in is Threshold layer but get overwritted in the Lerp layer, so we can barely see them.


Luckily both of methods work OK with illumination.

http://oi58.tinypic.com/xm5rb8.jpg


So that's it, I'm already out of ideas.

I think this can be improved with a shader that do 2 passes, one Threshold and another Lerp but with shadows. Saddly that's out of my range.


Any more ideas?

Link to comment
Share on other sites

  • 5 months later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...