Sun, 06/12/2022 - 17:45
Forums:
When testing MeshVS (Mesh Visualization Service) component with Draw Test Harness, I find meshdispmode command and meshselmode command are not supported. However, both commands are listed in occt_test_harness.pdf.
I searched a very old topic which was similar to my concern. It seemed meshselmode command was supported before.
https://dev.opencascade.org/content/selecting-nodes-elements-mesh
Why these two commands are deleted in latest OCCT?
Attachments:
Sun, 06/12/2022 - 21:56
MeshVS_Mesh inherits AIS_InteractiveObject so that most of general-purpose commands from ViewerTest plugin are applicable to mesh objects as well. This includes commands "vselmode" and "vsetdispmode" managing active display and selection modes.
Mon, 06/13/2022 - 05:56
Hello Kirill,
Thank you. "vselmode" command targets geometry entities, not including mesh entities. I guess it'll be not very difficult to add mesh selection modes to "vselmode" command.
Another question, when "4 - face" selection mode is chosen for "vselmode" command, only the surface visible faces can be selected. How to select the faces behind the scene with click-selection or box-selection?
Mon, 06/13/2022 - 09:19
4=face is only for AIS_Shape presentations. Each interactive object defines it's own list of selection modes - so you would need checking documentation of MeshVS_Mesh as a C++ class. It defines selection modes not as a list, but rather a bitmask MeshVS_SelectionModeFlags:
Point detection returns a list of entities through picking ray sorted from closest to farthest, and on click the topmost element is selected from this list.
Mon, 06/13/2022 - 12:01
Yes, well done. It also supplies "-add" and "-set" option.
BTW, how to get the ID of the topmost element for click-selection? And how to get a list of IDs for box-selection?
Sun, 06/12/2022 - 22:18
"Latest" is a little bit imprecise here. From git log it seems this change was done almost 8 years ago, and released in OCCT 6.8.0.
Mon, 06/13/2022 - 06:01
Thank your for correcting my misunderstandings. I'll check the older OCCT releases and try to find the implementation of "meshselmode" command.