Obi Official Forum
3D emboss - Printable Version

+- Obi Official Forum (https://obi.virtualmethodstudio.com/forum)
+-- Forum: Obi Users Category (https://obi.virtualmethodstudio.com/forum/forum-1.html)
+--- Forum: Obi Softbody (https://obi.virtualmethodstudio.com/forum/forum-12.html)
+--- Thread: 3D emboss (/thread-3355.html)



3D emboss - ericvenn - 09-03-2022

Hi,


I need a 3D 'emboss' effect. 
That means use an arbitrary mesh, then push it to a softbody (for instance until the middle of the softbody mesh), and the shape of the mesh is embossed in the softbody.
Without jelly spring effect.
Is that possible ?
Thanks for your help.


Eric


RE: 3D emboss - josemendez - 10-03-2022

Hi Eric,

Softbodies do support plasticity, which is what allow a material to "remember" deformation instead of springing back to its rest shape. See:

http://obi.virtualmethodstudio.com/manual/6.3/shapematchingconstraints.html

However using this to "stamp" shapes on a softbody like you describe would require to use crazy high simulation resolution (hundreds of thousands of particles) for any shape to be recognizable on the surface of the softbody. I don't know the details of your use case, but I'm inclined to say using softbody simulation for this is not practical. Maybe using normal map decals would be a better approach?

kind regards,


RE: 3D emboss - ericvenn - 10-03-2022

Hi Jose,

It's a pretty simple set. Just a high res cube (about 10 K polygons) that must be crossed by wires. Here you can see the results of some tests made by the client, that are not really correct, as the slopes of the wire holes are too straight.
It does not look like plastic (I don't know how they did it) (see picture in attachment)
Other detail, this is for a mobile game.
I have no idea how many particles an android phone is able to handle, and so the visual results that's going to give. 
Thanks for your help ! Sonrisa


RE: 3D emboss - josemendez - 10-03-2022

(10-03-2022, 10:15 AM)ericvenn Wrote: Hi Jose,

It's a pretty simple set. Just a high res cube (about 10 K polygons) that must be crossed by wires. Here you can see the results of some tests made by the client, that are not really correct, as the slopes of the wire holes are too straight.
It does not look like plastic (I don't know how they did it) (see picture in attachment)
Other detail, this is for a mobile game.
I have no idea how many particles an android phone is able to handle, and so the visual results that's going to give. 
Thanks for your help ! Sonrisa

This will require an insanely high amount of particles (probably as many as vertices, 10k), and if the target is a mobile device then particle-based softbodies are definitely not the way to go.

Assuming wires are always straight -or can be reduced to a sequence of straight lines- one possible way to achieve this effect is to just calculate the distance from each vertex in the cube to the wire (point to line segment distance), and plug that into a falloff curve to sink vertices in. This can easily and efficiently be done in a vertex shader.