Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.
First time visiting? Here are some places to start:- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- 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.
qAdjacent for finding the face a vertex touches?
Andre_Comella
Member Posts: 61 PRO
Hi all,
I'm wondering if I'm missing something here. I'm working on a FeatureScript, where not for the first time, I want to get a query of the face of a body that is touching a given vertex. In this particular instance, I can't use evOwnerSketchPlane or the like, because I can't guarantee the vertex is actually from a sketch. It seems to me that qAdjacent should work, with the query for the vertex as the seed, but the query always returns nothing.
I'm open to other suggestions as well. Right now I'm struggling through filtering out all the things I don't want from qClosestTo.
I'm wondering if I'm missing something here. I'm working on a FeatureScript, where not for the first time, I want to get a query of the face of a body that is touching a given vertex. In this particular instance, I can't use evOwnerSketchPlane or the like, because I can't guarantee the vertex is actually from a sketch. It seems to me that qAdjacent should work, with the query for the vertex as the seed, but the query always returns nothing.
I'm open to other suggestions as well. Right now I'm struggling through filtering out all the things I don't want from qClosestTo.
0
Best Answer
-
NeilCooke Moderator, Onshape Employees Posts: 5,680For qAdjacent to work, the vertex must belong to the face you are looking for. I always use qWithinRadius(entities, point, TOLERANCE.booleanDefaultTolerance * meter) which will find everything that "touches" the vertex within a tiny sphere.Senior Director, Technical Services, EMEAI1
Answers