H17 Vellum and hairgen
6996 10 3- winkel
- Member
- 218 posts
- Joined: March 2006
- Offline
Hi,
having fun with vellum. I use an animated horse (always the same point count) as input and after hairgen I get different count each frame. Limited it generate on “points” solves that (not what I want). But after that I get strange polys (see pictures). If I use longer hair this problem became a white screen (full with polys;o))
Any idea?
Detlef
having fun with vellum. I use an animated horse (always the same point count) as input and after hairgen I get different count each frame. Limited it generate on “points” solves that (not what I want). But after that I get strange polys (see pictures). If I use longer hair this problem became a white screen (full with polys;o))
Any idea?
Detlef
- Enivob
- Member
- 2625 posts
- Joined: June 2008
- Offline
Confirmed, vellum hair does not work correctly with deforming geometry that contains the same point count. That is odd, because that is the most typical use case. If I translate a static object, it seems to work as expected.
Edited by Enivob - Nov. 8, 2018 09:39:14
Using Houdini Indie 20.0
Windows 11 64GB Ryzen 16 core.
nVidia 3050RTX 8BG RAM.
Windows 11 64GB Ryzen 16 core.
nVidia 3050RTX 8BG RAM.
- winkel
- Member
- 218 posts
- Joined: March 2006
- Offline
- johner
- Staff
- 823 posts
- Joined: July 2006
- Offline
You really don't want to regenerate the hair each timestep, which is what you're doing if you send the deforming geometry through HairGen. It's expensive performance-wise, and more importantly, the points generated are jumping around as the scatter is not completely stable over time.
The best way to use Vellum hair with deforming geometry is to generate all the constraints on a static groom, then use GuideDeform to update the P and orient attributes right before the hairs go into the solver. This is quite fast, and guarantees stable point count and orientations calculated from the deforming geometry. The attached file shows a stable sim using this technique.
I've also reduced hair thickness a good bit in this file, since otherwise you can sometimes get the initial edges jittering a bit as they collide with the deforming geo. I also created a group for just the skin so there's no hair on the eyes which was pointing inwards. Also you might want to change the Orientation Pin Type to Soft rather than Same as Position if you want the initial edges to be able to bend as well.
The best way to use Vellum hair with deforming geometry is to generate all the constraints on a static groom, then use GuideDeform to update the P and orient attributes right before the hairs go into the solver. This is quite fast, and guarantees stable point count and orientations calculated from the deforming geometry. The attached file shows a stable sim using this technique.
I've also reduced hair thickness a good bit in this file, since otherwise you can sometimes get the initial edges jittering a bit as they collide with the deforming geo. I also created a group for just the skin so there's no hair on the eyes which was pointing inwards. Also you might want to change the Orientation Pin Type to Soft rather than Same as Position if you want the initial edges to be able to bend as well.
- Enivob
- Member
- 2625 posts
- Joined: June 2008
- Offline
Thanks for the explanation and the working file. Deform Guides seems to do the trick.
In this HIP file, the hair strands acquire their color from the texture map of the source via vex xyzdist function.
In this HIP file, the hair strands acquire their color from the texture map of the source via vex xyzdist function.
Edited by Enivob - Nov. 8, 2018 20:25:48
Using Houdini Indie 20.0
Windows 11 64GB Ryzen 16 core.
nVidia 3050RTX 8BG RAM.
Windows 11 64GB Ryzen 16 core.
nVidia 3050RTX 8BG RAM.
- winkel
- Member
- 218 posts
- Joined: March 2006
- Offline
- keithlynch_81
- Member
- 13 posts
- Joined: Aug. 2018
- Offline
Hi Johner, I've been having the same issue as Winkel and was pointed to this thread by someone on the facebook group. The .hiplc you created works great for the horse but when I bring my own OBJ sequence in, the Hair Gen node has two warnings:
WARNING: Position input does not have a rest attribute.
WARNING: Using P instead of rest for all inputs.
And then nothing works. I've tried adding a Rest Position node and that adds that attribute but it doesn't carry over to the Hair Gen.
Am I missing something?
WARNING: Position input does not have a rest attribute.
WARNING: Using P instead of rest for all inputs.
And then nothing works. I've tried adding a Rest Position node and that adds that attribute but it doesn't carry over to the Hair Gen.
Am I missing something?
- keithlynch_81
- Member
- 13 posts
- Joined: Aug. 2018
- Offline
Hi again Johner, I worked out what I was doing wrong (was leaving the skin group in the Hair Gen node). So am not getting the warning anymore. But am still getting issues where hair guides are stretching down as the character brings his arms down. I've tried bumping up all the data in the Vellum Solver but nothing seems to effect it.
Are you able to take a quick look please?
hip attached but can download the obj sequence from here https://we.tl/t-nsfqfVA5nd [we.tl]
Are you able to take a quick look please?
hip attached but can download the obj sequence from here https://we.tl/t-nsfqfVA5nd [we.tl]
- Midasssilver
- Member
- 310 posts
- Joined: July 2012
- Offline
Here's a movie from the file you uploaded. I don't see hairs stretching as the arms move, but I do see hair stretching between the legs. Please let me know if I misinterpreted this. What is causing those stretching guides, is the interpenetration of the guides with the collision geo at the first frame. You should scale down your collision geo at frame 1 until there are no initial interpenetrations, then scale up your collision geo over time
- keithlynch_81
- Member
- 13 posts
- Joined: Aug. 2018
- Offline
thank you so much for once again taking the time to take a look at this! and you were right about scaling my collision geo over time (although I found that I needed to start with it big, and then reduce to normal size). I also spread the legs apart and added in 24 frames before the character starts to move - which allows the hair to drop down before the scale reduces. Seems to have done the trick. Really appreciate you cracking this issue for me!
- Midasssilver
- Member
- 310 posts
- Joined: July 2012
- Offline
-
- Quick Links