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.

Options

Get arc data from query

Lucas_CrupiLucas_Crupi Member Posts: 5 EDU
Using evCurveDefinition I noticed that there is no return value for an arc query, and it only returns the information about the circle which the arc exists on. Is there any function that will return the endpoints and direction of an arc using feature script or am I missing something?

Comments

  • Options
    Alex_KempenAlex_Kempen Member Posts: 244 EDU
    evEdgeTangentLines with parameters equal to [0, 1] will return two lines which are tangent to the input arc at each end. Specifically, the direction of each line will be tangent to the respective end of the arc, and the origin of each line will be equal to the end of the arc. Alternatively, you can use qEdgeVertex to get queries for the vertices at the end of the arc, and then use evVertexPoint to get the corresponding 3D vector (although this won't give you the direction of the arc).
    CS Student at UT Dallas
    Alex.Kempen@utdallas.edu
    Check out my FeatureScripts here:



  • Options
    Jacob_CorderJacob_Corder Member Posts: 126 PRO
    If you need to know the direction of the arc, you could check its length to see if it is > or < 180 degrees. if its 180 degrees exactly, just check its mid point using evEdgeTangentLine to see which quadrant it lies on.  

    i think its counter clockwise relative to the coordinate system, but i also think that it can be inverted. I remember once dealing with this but cannot remember exactly how i figured it out. Sorry I don't know more. 
  • Options
    Lucas_CrupiLucas_Crupi Member Posts: 5 EDU
    the points of evEdgeTangentLine at [0,0.5,1] I was able to find the endpoints of the arc and the rotation direction. Thank you!
Sign In or Register to comment.