Hey,
I tried using some code to add solid fill patterns to closed curves in bulk, but after running the code, I couldn’t see any fill patterns.
When I selected all the shapes in the viewport, the command line showed that the fill patterns were already selected, which means the fill patterns were successfully created.
When I dragged or stretched the fill patterns using the control axis, they reappeared. What’s going on here?
Solid Hatch not display.3dm (240.8 KB)
Hi -
When I open the file and run SelBadObjects
, the hatch object is selected.
You might want to provide the code that you used to create this object.
-wim
Hi Wim Dekeyser, The code to create solid hatch is below
foreach(Curve crv in Crvs)
{
if (crv.IsClosed)
{
if(crv.ClosedCurveOrientation(Plane.WorldXY) == CurveOrientation.Clockwise)
crv.Reverse();
Hatch[] hatchs = Hatch.Create(crv, (int)HatchIndex, RhinoMath.ToRadians(HatchRotation), HatchScale, doc.ModelAbsoluteTolerance);
foreach (Hatch hatch in hatchs)
{
if(hatch != null)
{
hatch.Plane = Plane.WorldXY;
doc.Objects.AddHatch(hatch, obj_attr);
}
}
}
}
Hi Dale @dale
I don’t think so.the problem file attach below the post
Solid Hatch not display.3dm (240.8 KB)