Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.

First time visiting? Here are some places to start:
  1. Looking for a certain topic? Check out the categories filter or use Search (upper right).
  2. Need support? Ask a question to our Community Support category.
  3. Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
  4. Be respectful, on topic and if you see a problem, Flag it.

If you would like to contact our Community Manager personally, feel free to send a private message or an email.

How to visualize cut features

marci_van_dortmarci_van_dort Member Posts: 4
edited March 10 in FeatureScript

Hey everyone,

I'm working on a FeatureScript that cuts both a bolt hole and a nut slot in one feature, according to my specific needs. The feature itself is working great so far. What I am struggling with is: I am trying to figure out how to best visualize the hole that's being cut.

Typically, most of the holes' geometry will be hidden inside the part (see image), and on the outside you can only see a hole for the bolt and a slot for the nut. I want to make the feature easy to use; it might end up being used by others who are not very familiar with onshape or CAD in general. So ideally, I would like to show all of the holes' geometry while the feature is being edited.

I have considered a couple options:
- Using addDebugEntities to show the shape of the cutting tool I make. This works, partially; it only shows the part of the cutter that protrudes outside the target part, it does not show the geometry inside the part.
- Temporarily making the target parts transparent. This also only works partially: I can create a boolean input to toggle the parts' transparency. However, I can't change the appearance of any parts that already have a color assigned to them manually. Also, ideally, I'd like this transparancy to behave similarly to addDebugEntities, such that it automatically shows while the part is being edited (and only then).
- Changing the camera settings. By selecting "Hidden edges visible", I can perfectly see what's going on inside my part. I searched, but as far as I could find it's not possible to (temporarily) override camera settings using FeatureScript. And I can't trust users to know that this option exists. (of course I could write documentation, but then people would need to actually read it 😅)

What do you think would be the best way to deal with this problem?

Comments

Sign In or Register to comment.