/***************************************************/ public static void RenderRhinoWires(RHG.PolylineCurve polyline, Rhino.Display.DisplayPipeline pipeline, Color bhColour, int thickness) { RHG.Polyline poly; if (polyline.TryGetPolyline(out poly)) { pipeline.DrawPolyline(poly, bhColour, thickness); } }
/***************************************************/ public static bool IsEqual(this BHG.Polyline bhPolyline, RHG.PolylineCurve rhPolylineCurve, double tolerance = BHG.Tolerance.Distance) { if (bhPolyline == null & rhPolylineCurve == null) { return(true); } RHG.Polyline rhPolyline; rhPolylineCurve.TryGetPolyline(out rhPolyline); return(bhPolyline.IsEqual(rhPolyline, tolerance)); }
/***************************************************/ public static BHG.Polyline FromRhino(this RHG.PolylineCurve polyline) { if (polyline == null) { return(null); } if (!polyline.IsPolyline()) { return(null); } RHG.Polyline rPolyline; polyline.TryGetPolyline(out rPolyline); return(rPolyline.FromRhino()); }