IMSTK-Unity: Freezing in Suturing Scene

Hello,

I was working with the suturing scene and it works with Virtual Reality in unity without any problems. Now I’m trying to create the same scene with different a model, the needle and thread’s components are all the same as well as the components for the new model. However, whenever I start the scene (Again in VR) and try to puncture the model with the needle, unity just fully freezes. The new model is similar to the tissue model in the suturing scene in terms of detail, both of their tetrahedral mesh counts are very close, the new model is 438 tetrahedral and the the tissue model is 598 tetrahedral. I can’t really find the source of the freezing.

Are there any special conditions for designing the models to work with the suturing?

Thanks in advance.

Hi Sarah, thanks for posting your question. I suspect that the freeze-up might be due to the thin tetrahedra. Can you try with a thicker mesh so that you are not piercing the surface through-and-through?
Also, does the freeze-up happen after the puncture event or simply on first collision between needle and mesh model? You can test this by setting the “Puncture Dot Threshold” = 1. This will effectively disable the puncture event. Check if that stops the scene from freezing up.

Hi, thanks for the replay.
I set the "Puncture Dot Threshold” to 1 and it did stop the freezing. That leaves the thickness of the mesh, is there a limit to how thin can a mesh be for the needle to be able to puncture it?
Also, is it possible to puncture the front face through the back face or does the needle have to come out from the middle like in the suturing demo scene that imstk have provided?

Thanks.

One more question. Despite increasing the thickness of the model it still freezes. So apart from the thickness, are there any values that need to be changed according to the shape of the model?
I’m assuming the values that were assigned in the components (deformable e.g.) for the tissue model are suitable for the model itself and might not work for others. So, which component value might cause such problems?

Thanks.

It might be worth testing the mesh model within iMSTK’s C++ example here: Examples/PBD/PBDDynamicSuture/pbdDynamicSutureExample.cpp · master · iMSTK / iMSTK · GitLab (kitware.com)

Note that you will have to update the createTissue() function to correctly fix the boundary vertices in the new model. If you can load this model in the C++ example, you maybe able to find where exactly it crashes or freezes.
Otherwise, if you can provide me the mesh in .stl or .vtk format I can give it a shot.