Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations IDS on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

API: Get (correct) arc normals from sketch?

Status
Not open for further replies.

rocheey

Industrial
Jan 21, 2001
230
Ive been using a routine for a while that works well, using GetPolyLines5 to extract all the lines/arcs/polys/splines, etc from a drawing VIEW. No problem here.

But Im attempting to now do similar with a 'block' object.
It seems I have to get the SKETCH Object (instead of the View object) from the BlockReference, which doesnt allow me to use the generic GetPolyLines5 (which returns all lines,arcs, etc) and instead, make separate calls using the "GetLines2" and "GetArcs2", etc, API calls.

First thing I noticed was that docs seemed wrong; 'GetLines2' states 7 items per line enitity, it worked correctly with 12 items. 'GetArcs2' states 12 items per enitity, while 16 is what worked.

But the problem here is the 'normal' for the arc; GetPolyLines5 always returned the X,Y,and Z normals, and seemed to do it correctly, while 'GetArcs2' seems to only return the Z Normal, and it seems to always be set to '1', even when I added arcs that could NOT be represented in a CCW fashion using a normal of "1" ...

Is there anything Im missing?
 
Replies continue below

Recommended for you

An arc is, by definition, a planar entity. A plane can be expressed with a single normal. Perhaps this is the value you are getting for the normal. [bat]Gravity is a harsh mistress.[bat]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor