|
发表于 2018-6-8 14:50:00
|
显示全部楼层
//添加矩形框
Point2d jx1 = new Point2d(x, y);
Point2d jx2 = new Point2d(x1, y1);
pl.CreateRectangle(jx1, jx2);
ObjectId plid = db.AddToModelSpace(pl);
ObjectIdCollection ids = new ObjectIdCollection();
ids.Add(plid);
//绘制填充
Hatch hatch = new Hatch();
hatch.CreateHatch(HatchPatternType.CustomDefined, patternname, true);
hatch.AppendLoop(HatchLoopTypes.Outermost, ids);
ids.Clear();代码参考才鸟的书,具体可以看那本书 |
|