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.

Problems with skArc

sören_svenssonsören_svensson Member Posts: 20
Hi,

I'm creating some corners with skArc but some are ending up inside-out!

I'm using the getArcMidPoint function posted here earlier.

All the small arcs in the picture below should be "outies" and the large center one "innie".


Here's the code for the lower left one (ll and ur are vectors)

start = ll + vector(0 * millimeter, radius);
        end = ll + vector(radius, 0 * millimeter);
        mid = getArcMidpoint(ll + vector(radius, radius), start, end);
        skArc(sketch1, "arc2", {
                "start" : start,
                "mid" : mid,
                "end" : end
        }):

and the top right

start = ur + vector(-radius, 0 * millimeter);
        end = ur + vector(0 * millimeter, -radius);
        mid = getArcMidpoint(ur + vector(-radius, -radius), start, end);
        skArc(sketch1, "arc8", {
                "start" : start,
                "mid" : mid,
                "end" : end
        });

Anyone have any idea why and how to control it:

Regards
Soren

Tagged:

Comments

  • ilya_baranilya_baran Onshape Employees, Developers, HDM Posts: 928
    Try switching the start and end arguments to the getArcMidpoint function -- I think that function (Neil wrote it) gets the midpoint assuming the arc is counterclockwise from start to end.
    Ilya Baran \ Director, Architecture and FeatureScript \ Onshape Inc
  • sören_svenssonsören_svensson Member Posts: 20
    Thanks, worked perfectly!
    I should have thought about that  :#

Sign In or Register to comment.