RoundedRectangleShapedCompositeCurve rrscc1 = new RoundedRectangleShapedCompositeCurve(Plane.YZ, 40, 120, 12, true); SlotShapedCompositeCurve sscc1 = new SlotShapedCompositeCurve(Plane.YZ, 9, 5.25, true); sscc1.Translate(0, 0, 43); SlotShapedCompositeCurve sscc2 = new SlotShapedCompositeCurve(Plane.YZ, 9, 5.25, true); sscc2.Rotate(Utility.DegToRad(90), Vector3D.AxisX, Point3D.Origin); sscc2.Translate(0, 0, -40); Circle c1 = new Circle(Plane.YZ, 4.25); Region r1 = new Region(rrscc1, sscc1, sscc2, c1); Solid3D ext1 = r1.ExtrudeAsSolid3D(-4); viewportLayout1.Entities.Add(ext1, 0, Color.YellowGreen); CompositeCurve cc1 = new CompositeCurve( new Line(Plane.YZ, 8, -10, 11, -10), new Arc(Plane.YZ, new Point2D(11, -5), 5, Utility.DegToRad(270), Utility.DegToRad(360)), new Line(Plane.YZ, 16, -5, 16, +5), new Arc(Plane.YZ, new Point2D(11, +5), 5, Utility.DegToRad(0), Utility.DegToRad(90)), new Line(Plane.YZ, 11, 10, -11, 10), new Arc(Plane.YZ, new Point2D(-11, +5), 5, Utility.DegToRad(90), Utility.DegToRad(180)), new Line(Plane.YZ, -16, +5, -16, -5), new Arc(Plane.YZ, new Point2D(-11, -5), 5, Utility.DegToRad(180), Utility.DegToRad(270)), new Line(Plane.YZ, -11, -10, -8, -10)); Region r2 = cc1.OffsetToRegion(-2.5, 0, false); ext1.ExtrudeAdd(r2, 275); SlotShapedRegion ssr2 = new SlotShapedRegion(Plane.XY, 12, 5.25); ssr2.Translate(9, 0, 0); ext1.ExtrudeRemovePattern(ssr2, 10, 35, 8, 0, 1); viewportLayout1.Entities.Regen();
Have more questions? Submit a request
Comments
Please sign in to leave a comment.