Dent and bulge using geometries queries - Bifrost 2.1.0.0 sample scene

Dent and bulge using geometries queries - Bifrost 2.1.0.0 sample scene

Grahame_Fuller
Autodesk Autodesk
1,713 Views
5 Replies
Message 1 of 6

Dent and bulge using geometries queries - Bifrost 2.1.0.0 sample scene

Grahame_Fuller
Autodesk
Autodesk

Here's a Maya 2019 scene with a completely non-physically--based deformation of a mesh denting and bulging in response to a collider. It's an example of using the building blocks in Bifrost 2.1.0.0 to create geometry queries that go a bit beyond the pre-built compounds. If you're familiar with ICE, you might notice its similarity to one of the Softimage sample scenes. 🙂

 

dent-bulge.png

 

It uses raycasting to determine whether each point of the ground mesh is on the "wrong" side of the collider based on the input direction, and applies a dent accordingly. It also raycasts in the opposite direction to check for collisions that would limit the amount of bulging possible. For efficiency, it reuses the same raycast acceleration structure for both operations.

 

For the bulging, it next gets the neighbours within a radius of each point on the ground mesh that was not dented on that frame. If there is a dented neighbour, the first one found will be the closest so the graph applies a bulge based on the distance and a profile curve (capped by the maximum room for bulging found by the second raycasting). Since bulging is not applied to points that have been dented on the same frame, the closest-point accelerator is built outside the per-point loop.

 

The bandwidth input might not be obvious. It simply allows for a bit of space between the collider and ground mesh.

 

I hope this example is useful for exploring some of the possibilities for custom geometry queries. Please reply with any questions or problems.


Grahame Fuller
Learning Content Developer
1,714 Views
5 Replies
Replies (5)
Message 2 of 6

Christoph_Schaedl
Mentor
Mentor

Such sample scenes are pure gold. There is so much to learn from.

Thanks and please dont stop. We need more.

 

Cheers

Oglu

----------------------------------------------------------------
https://linktr.ee/cg_oglu
Message 3 of 6

darioOrtisi
Collaborator
Collaborator

@Grahame_Fuller 

Hi.

I will like to get only the color information without the deformation and take the color output as color userDatacolor. How do i get this?

Thanks

Message 4 of 6

Grahame_Fuller
Autodesk
Autodesk

Hi,

 

As it stands, the graph sets a property called "basecolor" which gets automatically picked up and used because it is the name of a standard surface parameter.

 

Instead of "basecolor", you can use set_geo_property to store the colors as a property with any custom name you want, and then get that property with a user data shader.

 

Hope that helps,

gray


Grahame Fuller
Learning Content Developer
0 Likes
Message 5 of 6

darioOrtisi
Collaborator
Collaborator

Hi @Grahame_Fuller 

I'm trying to make particles as collider for dent and Bulge but it wont work.

It's not possible at all?

Thanks

0 Likes
Message 6 of 6

Grahame_Fuller
Autodesk
Autodesk

Hi Dario,

 

That example raycasts from the ground points up to the collider to find which points on the ground need to be dented. Particles don't have any surface to raycast onto, so you'd need a very different strategy.

 

Cheers,

gray


Grahame Fuller
Learning Content Developer
0 Likes