- Posts: 3
- Thank you received: 0
Probe Basic Cutaway
- dang133
- Topic Author
- Offline
- New Member
-
I'm new, so go easy on me. My team is using Probe Basic as a GUI for a 5-axis CNC Mill. We're trying to create a cutaway button that will show only half of a part at a time. It will virtually slice the part and show the cutaway. After some google earching, it looks like this is not a common request. How should we go about doing this? What is the best route to take?
Thanks,
Dan
Please Log in or Create an account to join the conversation.
- cmorley
- Offline
- Moderator
-
- Posts: 6803
- Thank you received: 2181
You'll get better response there.
Please Log in or Create an account to join the conversation.
- tommylight
-
- Away
- Moderator
-
Please Log in or Create an account to join the conversation.
- Lcvette
- Offline
- Moderator
-
- Posts: 1683
- Thank you received: 784
Please Log in or Create an account to join the conversation.
- TelegramSam
- Offline
- New Member
-
- Posts: 2
- Thank you received: 0
The goal would be to show and hide portions of the machine visualization, based on what this thread describes:
forum.linuxcnc.org/qtpyvcp/56945-qtpyvcp...led-into-one?start=0
We have the machine showing, but would like to be able to have buttons show and hide portions of the machine - say one stl in the yaml config file.
Any help that can move us forward?
Please Log in or Create an account to join the conversation.
- Aciera
- Offline
- Administrator
-
- Posts: 4819
- Thank you received: 2177
github.com/Sigma1912/vtk-vismach
Model groups:
Each object of a model can optionally be assigned to a group. The assignment method can be called
on an existing object (2 lines of code)
Example 1: 'work_piece = Box(600,600,600)'
'work_piece.set_group('work')'
or the object can be created and the 'set_group' method called in one line.
Example 2: 'ReadPolyData('work_piece.stl', path_stl).set_group('work')'
Vismach will automatically create a checkbutton to show or hide each group used in the model.
Outline of my solution:
Each object in the model has a simple class variable 'group'.
When the window is created a checkbox is created for each group found in the model.
In each update cycle the objects with the matching 'group' variable value are shown or hidden according to the relevant checkbox state
Note that the vtk 'SetVisibility()' method did not seem to work for me so I use 'item.SetScale(0,0,0)' to hide an object:
Please Log in or Create an account to join the conversation.