yeah, that’s what you wrote before, but the problem is that it doesn’t work with meshes that have a non-uniform thickness. I want to get a similar result as in the image i linked, which means that the ends should end in one point and in the middle it’s a bit thicker…
As you can see it works ok at the beginning, but the ends don’t line up in one point.
I hope I’m doing this right but an option like I mentioned would defenitly be a good solution ;D
We can work together a bit if you want… I just need to get the vertex positions from the current edge loop the hair is bending at for each of the loops the hair is using to bend, if you know how you could implement that.
nice, it works much better now!
Although I still think I’m going to tinker with the script a bit to see if I can get my method to work, because it still has some problems. Mainly, the hair goes quite a bit outside of the mesh with this method, especially with non-cylindrical meshes (which you stated it not working for). And also it looks very “rough”, even when you don’t add any other randomness.
Thanks for all your work!
edit: The API documentation is not very helpful with this, so just a quick question, at the line:
loop = loop.link_loop_next.link_loop_next
does this go around the face by 2 corners to get the next “edge loop” in the mesh?
And then how can I go to the next one in the other direction (around the edge loop)?
@lichtso
Wow! I didn’t think I could do this but I have successfully implemented exactly what I was talking about into your addon (even works with random length, but that was the trickiest part ;D). It works with any shape of mesh (didn’t test, but probably also curves etc as they internally get converted to meshes), it doesn’t go out of the mesh, no weird randomness if you don’t turn up randomness (all the options still work with this) and it’s 100% evenly distributed (at least in a cylinder, other shapes are of course not perfectly distributed, but if it’s at least somewhat of a “simple” closed shape it looks fine).
I’m from germany too, so I have to go to bed now, but maybe tomorrow we can discuss how you want to integrate the feature into your addon (don’t really want to go through all the github contributor hustle just for these some changed lines ;D). Also I could show you some results then, or you can just test it yourself.
Cool, I can integrate the feature into the addon after some testing.
You can send me the code if you don’t have a GitHub account. But then you will not be directly credited there.
Also: Some pics / images of your results would be nice!
My new functionality is now implemented in the master (2.90) branch. It adds:
An option checkbox called “Fill volume” to fill the inside of a mesh/curve by offsetting all hairs inwards by a random amount to give an even distribution in a cylinder (but works for every mesh/curve).
An option checkbox called “No tip rand” to disable all options that do randomness or bias for the last hair vertex, so you can do hair with randomness/bias and still have a pointy end.
edit: Just found some screenshots showcasing fill volume without any child hairs (no randomness, but the second image can also be realized with “No tip rand” if you have randomness):