Forum Replies Created
-
AuthorPosts
-
SinghBlocked14 January 2021 at 09:10 in reply to: [SOLVED] Force Induced Topological Modification of Triangular Mesh #18207SinghBlocked
@Hugo
I pulled the master to use the changes done by Scheikl in ContactListner.h
I intended to use it by creating a scene using CPP. Isn’t that the right direction, what benefits would I have with SofaPython3.Please let me know so that I know is it worth waiting. π
Regards,
Sukhraj4 January 2021 at 16:43 in reply to: [SOLVED] Force Induced Topological Modification of Triangular Mesh #18105SinghBlockedHi @Scheikl,
Thanks for your inputs.
Sure, I will update you on the progress I make.I have mainly used *.scn files but not SofaPython.
Regards,
Sukhraj3 January 2021 at 17:02 in reply to: [SOLVED] Force Induced Topological Modification of Triangular Mesh #18098SinghBlockedHi @epernod
Greetings for the new year!I would like to start simple first. I would like just to first know the colliding triangles of a mesh with the tool, and remove those triangles.
Can you help me know what classes I must look into.
I looked
into bool RemovePrimitivePerformer<DataTypes>::createElementList()
, but it uses:/// picked structure from mouseInteractor. BodyPicked picked;
How can I find colliding faces of an organ(mesh) and tool(mesh) when using geomagic touch device?
18 November 2020 at 09:56 in reply to: [SOLVED] Force Induced Topological Modification of Triangular Mesh #1772013 November 2020 at 07:08 in reply to: [SOLVED] Force Induced Topological Modification of Triangular Mesh #17654SinghBlockedHi @epernod
Here are my answers:
Hi,
1. Do you already have a simulation of the Geomagic Touch deforming the membrane ? Everything is ready in SOFA to do that but in my knowledge there is no such example in the repository.
Ans: Yes, I do have that, I used FEM Liver scene, and then replaced the Liver meshes, with a triangular mesh. I use Triangular FEM from SOFA. I can interact with the membrane ( a rectangular Triangle Mesh ) with the geomagic touch, I can push the membrane that produces deformations in it, but it would not tear even if I keep pushing. And I think that requires using of Topological Modifiers.2. Do you already have the triangular mesh ruptured ? If yes I would be interested to know which paper you implemented.
Algorithm to cut triangular mesh are available but from given input coordinates.Ans: I don’t have that. I have not implemented any new algorithm to do so. I intended to use sofa’s implementation for the same. I did run a few sofa examples for topological modification.
3. Do you have simulation of the triangular mesh deforming and starting to cut (full simulation you are targeting but without the haptic interaction) ?
Ans: I did run an example from topological modifier, that creates cut along the edges of a mesh, basically removes the edges of mesh, and the edge indices are provided in a text file. Is that the same you are asking about?
SinghBlockedI have an additional question on topology modifier, I am trying to simulate the fenestration of a membrane using Geomagic Touch. I am using Triangular FEM from SOFA.
I can not see any example scene in which one does topological modification with a haptic device, say when we push a deformable model using haptic device, an incision is made, the triangular mesh gets ruptured/fenestrated. Can you please point me in right direction in order to achieve the same with SOFA?Regards,
SukhrajP.S. I can create a seperate topic, if you think I must.
SinghBlockedI see this issue happening in master:
commit c76874b78bd27457f3562aca0ec006ed87d76166 (HEAD -> master, origin/master, origin/HEAD) Merge: 1f180f0676 820dd1e051 Author: Guillaume Paran <guillaume.paran@sofa-framework.org> Date: Fri Sep 18 11:02:47 2020 +0200 Merge pull request #1487 from coolteemf/Improve_MeshBarycentricMapperEngine [SofaGeneralEngine] Improve mesh barycentric mapper engine
This is the error log I am getting:
38>C:\open_prj\sofa\src\applications\plugins\CGALPlugin\src\CGALPlugin/Refine2DMesh.inl(300): error C2660: 'CGAL::Constrained_triangulation_plus_2<CDT1>::vertices_in_constraint_begin': function does not take 2 arguments (compiling source file C:\open_prj\sofa\src\applications\plugins\CGALPlugin\src\CGALPlugin\Refine2DMesh.cpp) 38>C:\dev\CGAL-5.0.2\include\CGAL/Constrained_triangulation_plus_2.h(793): note: see declaration of 'CGAL::Constrained_triangulation_plus_2<CDT1>::vertices_in_constraint_begin' (compiling source file C:\open_prj\sofa\src\applications\plugins\CGALPlugin\src\CGALPlugin\Refine2DMesh.cpp) 38>
20 September 2020 at 12:39 in reply to: [SOLVED] Forces not getting rendered with Geomagic touch. #17188SinghBlocked7 September 2020 at 06:41 in reply to: [SOLVED] Forces not getting rendered with Geomagic touch. #17087SinghBlocked@hugo I checked the recent changes in the master, looks like the commit: https://github.com/sofa-framework/sofa/commit/55b1773abd2d0e380af794777d93ee7d8856b8f2#diff-135e5cfaf3fe28cc7d7e060995d54f1a
by @epernod does the same as you say in your comments. I think then we can topic as resolved.
I have not tested it as of now.P.S. Please excuse for a long delay in my reply, I had a bike accident that left me unable to work with a pc. Just started working this week.
SinghBlockedHello,
I added the same log to check the forces rendered in v19.06:
Here are my findings:
1. For Geomagic-RigidCubes.scn
– this scene is not present in v19.062. For Geomagic-FEMLiver.scn were coming of the order:
-0.352481 0.592706 0.539582 -0.352481 0.592706 0.539582 -0.354577 0.591537 0.535375 -0.357102 0.593033 0.537134 -0.356612 0.593141 0.536671 -0.356832 0.595202 0.539216 -0.356832 0.595202 0.539216
Observation: I could very well feel forces. And are much more in magnitude as compared to the v20.06. Consequently, the tool does not penetrate very easily into the liver object.
3. For Geomagic-RigidSkull
1.17827 1.10191 0.265511 1.18029 1.1175 0.265051 1.18029 1.1175 0.265051 1.18029 1.1175 0.265051 1.17963 1.1175 0.264865 1.17528 1.12405 0.263256
Observation: Forces do feel that as if I am interacting with a rigid object, the force vector magnitude is also much more than as observed with v20.06.
Overall: There is s remarkable difference in forces for a same scene between v20.06 and v19.06
SinghBlockedI am curiously waiting for a helpful reply to this question as I am working on similar problems.
SinghBlockedHello,
I added a log to check the forces rendered:
--- a/applications/plugins/Geomagic/src/Geomagic/GeomagicDriver.cpp +++ b/applications/plugins/Geomagic/src/Geomagic/GeomagicDriver.cpp @@ -144,6 +144,8 @@ HDCallbackCode HDCALLBACK stateCallback(void * userData) omni_force[1] = force_in_omni[1]; omni_force[2] = force_in_omni[2]; + std::cout << omni_force[0] << " " << omni_force[1] << " " << omni_force[2] << std::endl; + hdSetDoublev(HD_CURRENT_FORCE, omni_force);
Here are my findings:
1. For Geomagic-RigidCubes.scn
I could see the force vector reaching these values:0.965372 -0.0650974 0.274407 0.966204 -0.0645502 0.2723 0.966221 -0.0645658 0.272316 0.965388 -0.0651183 0.274447
Observation: I can feel the forces, however very less as compared to rigid body interaction with the Touch demo application.
2. For Geomagic-FEMLiver.scn were coming of the order:
0.0168471 0.0168061 0.0109535 0.0169753 0.0167133 0.0110079 0.0169876 0.0166903 0.011016 0.0169876 0.0166903 0.011016 0.0169876 0.0166903 0.011016 0.0169876 0.0166903 0.011016 0.0170215 0.0166911 0.0110239 0.0170215 0.0166911 0.0110239
Observation: I could hardly perceive forces, however the liver deformation happens.
3. For Geomagic-RigidSkull
-0.0320186 0.0520094 0.0841243 -0.0317458 0.05224 0.0840578 -0.0318995 0.0520695 0.0841263 -0.0320336 0.0519236 0.0841948 -0.0321138 0.051894 0.0841844 -0.0320637 0.0519552 0.084153 -0.03201 0.0520199 0.084121 -0.0319648 0.0520749 0.0840929 -0.0317474 0.052238 0.0840595 -0.0319021 0.0520664 0.0841284 -0.0320369 0.0519196 0.0841974 -0.0321115 0.0518953 0.0841864 -0.0320597 0.0519587 0.084154
Observation: I could perceive very faint forces.
Overall observation, if we uncheck the Animate button, the forces still keep rendering. As seen from the log values.
Since I had been interacting with the FEM Liver scene, and assumed that checking Animate button would compute forces and unchecking would stop, and I could hardly perceive any forces, I wrongly concluded that there is an issue with force rendering.However, I must say the force rendering is very faint as compared to the earlier version of Geomagic Plugin.
I would like to know how can one tune the forces being rendered so that it feels realistic.
SinghBlockedIs there any discount for students?
1 June 2020 at 15:42 in reply to: [SOLVED] Issue while exporting tetrahedron mesh generated from polyhedron #16503SinghBlockedThanks, @jnbrunet,
Exactly that was the issue with the scene file, I have been able to export the tet mesh.Thanks for helping out!
1 June 2020 at 05:12 in reply to: [SOLVED] Issue while exporting tetrahedron mesh generated from polyhedron #16486SinghBlocked@hugo
Thanks for your inputs.
I am new to SOFA and that is my first attempt at creating a scene file πNow I understand that:
MeshGenerator.outputPoints
gives me point/geometry information.
andMeshGenerator.outputTetras
gives me topological information. And I could see the same in the code:, f_newX0( initData (&f_newX0, "outputPoints", "New Rest position coordinates from the tetrahedral generation")) , f_tetrahedra(initData(&f_tetrahedra, "outputTetras", "List of tetrahedra"))
Then what should be the input to the cellDataFields?
<VTKExporter name="exporter" filename="test_out" XMLformat="1" edges="0" tetras="1" listening="true" exportAtBegin="true" cellsDataFields="MeshGenerator.outputTetras" overwrite="true"/>
I see an empty file test_out.vtk and the application never seems to finish writing.
I could not find an example scene that shows exporting a tetrahedral mesh generated from a surface mesh.Cheers,
Sukhraj -
AuthorPosts