Quantcast
Channel: RevitNetAddinWizard & NavisworksNetAddinWizard
Viewing all articles
Browse latest Browse all 872

Does Revit .NET API Create.NewArc Accept Degree Values?

$
0
0

Recently spotted some code in an official SDK sample:

arr.Append(m_revit.Create.NewArc(pnt2, 1.0d, 0.0d, 180.0d, Autodesk.Revit.DB.XYZ.BasisX, Autodesk.Revit.DB.XYZ.BasisY));

It seems the intent was to create a half circle arc, on the XY plane, as part of a profile which was used to create a sweep next. However, it does not look right at all because of the simple fact that only radian angle values are accepted in the Create.NewArc method. By the way, the d suffix indicates the value is a double instead of a 'DEGREE'.

The odder part is that the sample still runs in Revit! So compiling and running does not really indicate everything is fine. Some tricky issues may hide deep.


Viewing all articles
Browse latest Browse all 872

Trending Articles