nHair Collision Issue

Become a member of the CGSociety

Connect, Share, and Learn with our Large Growing CG Art Community. It's Free!

THREAD CLOSED
 
Thread Tools Search this Thread Display Modes
  07 July 2013
nHair Collision Issue

I am having an issue with nHair and a passive collider mesh. I have attached two images to illustrate my problem. Both images represent nHair on a body mesh. The nHair is attached to a scalp which is inside the head (i.e. not visible in the image). The body mesh is a passive collider with the default settings (e.g. default collision thickness).

The first image shows the initial state of the nHair.

The second image shows the state of the nHair immediately after I select Interactive Playback.

Please note how the nHair pushes away from the head at the root. At first, I thought it might have to do with the collision thickness setting of the passive collider mesh. However, the behavior is exactly the same when I set the collision thickness to 0.

What is causing the nHair to push away from the head at the root when I initiate Interactive Playback?
Attached Images
File Type: jpg before.jpg (38.1 KB, 15 views)
File Type: jpg after.jpg (38.7 KB, 26 views)
 
  07 July 2013
Just going on logic, it would seem that the reason it is getting pushed out is because it is inside the collision mesh. Even at 0 this would happen I would think.

But right or wrong on that point. You probably don't want the actual body as the collision mesh. Try using another much simpler version of the head (and shoulders if you need that) to cut down on calculation time. Skin it and set it as the passive collider.

And while you are at it, make it smaller than the head mesh and don't put the hair inside it. Use the collision distance to make sure it will not penetrate the real head when colliding.

I use a similar approach to nCloth, just using that logic, not sure if it will help here.
__________________
Richard Culver
Protfolio Facebook WIP1 WIP2
 
  07 July 2013
OK. I solved the problem.

The issue was with the Push Out Radius, located in the Quality Settings tab. By default, it is set at 1.415. When I set this to 0 (or a small value), the problem goes away.

I feel a bit stupid. I had a "push out" problem and the solution was a "push out radius" setting.
 
  07 July 2013
Ah.... if it was always so obvious and easy. I love the stupid ones. Glad you sorted it.
__________________
Richard Culver
Protfolio Facebook WIP1 WIP2
 
  07 July 2013
Actually, thinking about this. This is not to be considered, "solved" when you take into account the fact that you need this feature for collisions. You are using a feature designed for something else that you are using to correct a bad set up - as I have described above. You should set it up properly and reserve push out for the hair collisions on the tips not the root.
__________________
Richard Culver
Protfolio Facebook WIP1 WIP2
 
  07 July 2013
cineartist,

You are right. My solution was not workable. It did render the push out radius unusable. I have now set things up as follows (as per your suggestion):

Three meshes are used: Head, Scalp, Collision Head

1. Head is the main visible mesh.
2. Scalp is inside of Head. nHair is attached to Scalp. This keeps the roots inside of Head.
3. Collision Head is inside of Scalp. Collision Head is set to be a passive collider with a thickness value which expands outside of Head to prevent hair from penetrating Head.

This does solve the problem while retaining the ability to use push out radius.

Thank you for your persistence on this one.
 
  07 July 2013
You are welcome.

Good luck with the project!
__________________
Richard Culver
Protfolio Facebook WIP1 WIP2
 
  07 July 2013
Thread automatically closed

This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
__________________
CGTalk Policy/Legalities
Note that as CGTalk Members, you agree to the terms and conditions of using this website.
 
Thread Closed share thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 10:29 PM.


Powered by vBulletin
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.