Hey guys!
I initially developed this deformer in Python and was dreading having to port it to c++ and to make it GPU friendly, so I made myself a challenge to see if I could convert it fully to Bifrost.
And hot ****, I think it's actually working!
Here's a video of what it does with a cube and another quick test on a model's face.
In order to get it working I had to do lots of my own mini compounds.
Right now to detect if a point is inside a mesh I'm using rays. In a nutshell if the ray's total hits is odd then the point is inside the mesh, otherwise it's outside. Since Bifrost's native raycast only returns you the first hit I used a while loop to get all possible intersections, sort of like mimicking MFnMesh's allIntersections. Here's an example to check if a locator is in a mesh, and to display its first and last hits with red locators.
I also built my own smooth compound to average the collisions with adjacent verts. An attribute is exposed to bleed off the effect of the smooth, and has a toggle to visualize this (green area gets smoothed). Here's a demo of that here.
There's still much more that I can do to improve it and to increase its performance. Right now I'm trying to optimize the graph nodes as I got a few for loops in there that I'm embarrassed of. But hey, Bifrost is a beast to get this working!!
Solved! Go to Solution.
Hey guys!
I initially developed this deformer in Python and was dreading having to port it to c++ and to make it GPU friendly, so I made myself a challenge to see if I could convert it fully to Bifrost.
And hot ****, I think it's actually working!
Here's a video of what it does with a cube and another quick test on a model's face.
In order to get it working I had to do lots of my own mini compounds.
Right now to detect if a point is inside a mesh I'm using rays. In a nutshell if the ray's total hits is odd then the point is inside the mesh, otherwise it's outside. Since Bifrost's native raycast only returns you the first hit I used a while loop to get all possible intersections, sort of like mimicking MFnMesh's allIntersections. Here's an example to check if a locator is in a mesh, and to display its first and last hits with red locators.
I also built my own smooth compound to average the collisions with adjacent verts. An attribute is exposed to bleed off the effect of the smooth, and has a toggle to visualize this (green area gets smoothed). Here's a demo of that here.
There's still much more that I can do to improve it and to increase its performance. Right now I'm trying to optimize the graph nodes as I got a few for loops in there that I'm embarrassed of. But hey, Bifrost is a beast to get this working!!
Solved! Go to Solution.
Solved by labbejason. Go to Solution.
Working. Thank you 🙂
Working. Thank you 🙂
I took a bit of a hiatus to work on some side projects, but have time today to share a little update.
Right now it's able to handle a very dense topology because the actual deformation is being done on a low poly proxy mesh. Afterwards the high-res foot steals the deformation from the proxy, making it lightweight for manipulation and playback. All of this is being done directly inside Bifrost. I also finally fixed the normals so it's easier to make out the bulge!
Here's a demo of that in action:
I took a bit of a hiatus to work on some side projects, but have time today to share a little update.
Right now it's able to handle a very dense topology because the actual deformation is being done on a low poly proxy mesh. Afterwards the high-res foot steals the deformation from the proxy, making it lightweight for manipulation and playback. All of this is being done directly inside Bifrost. I also finally fixed the normals so it's easier to make out the bulge!
Here's a demo of that in action:
Very cool Jason! Thanks for sharing too!
Very cool Jason! Thanks for sharing too!
Thanks ShihMing! Loving your self-collision deformer as well 😄
Thanks ShihMing! Loving your self-collision deformer as well 😄
Just wanted to say great work on this!
Had a quick play and found that you can make a hacky tracer as well with feedback ports.
Just wanted to say great work on this!
Had a quick play and found that you can make a hacky tracer as well with feedback ports.
Wow that's really cool! I was wondering how to go about something like that to make it act like a sim. Thanks for showing that! It makes for a neat cheap snow effect.
Wow that's really cool! I was wondering how to go about something like that to make it act like a sim. Thanks for showing that! It makes for a neat cheap snow effect.
Wow, that's quite neat..
Wow, that's quite neat..
Thanks for great examples but unfortuantly example does not seem to be working due to missing node definition on one of subgraph. "update_point_neighbors" May I ask if there is any custom compound need to be prepared? or is there any related built in operators I can replace to fix the issue? it would be awesome if you can share your thought!
Thanks in advance
Thanks for great examples but unfortuantly example does not seem to be working due to missing node definition on one of subgraph. "update_point_neighbors" May I ask if there is any custom compound need to be prepared? or is there any related built in operators I can replace to fix the issue? it would be awesome if you can share your thought!
Thanks in advance
Can't find what you're looking for? Ask the community or share your knowledge.