protected virtual ElementLocation FindLoopEntryPoint(FillLoop poly, Vector2d currentPos2)
        {
            int startIndex;

            if (Settings.Part.ZipperAlignedToPoint && poly.FillType.IsEntryLocationSpecified())
            {
                // split edges to position zipper closer to the desired point?
                // TODO: Enter midsegment
                Vector2d zipperLocation = new Vector2d(Settings.Part.ZipperLocationX, Settings.Part.ZipperLocationY);
                startIndex = CurveUtils2.FindNearestVertex(zipperLocation, poly.Vertices(true));
            }
            else if (Settings.Part.ShellRandomizeStart && poly.FillType.IsEntryLocationSpecified())
            {
                // split edges for a actual random location along the perimeter instead of a random vertex?
                Random rnd = new Random();
                startIndex = rnd.Next(poly.ElementCount);
            }
            else
            {
                // use the vertex closest to the current nozzle position
                startIndex = CurveUtils2.FindNearestVertex(currentPos2, poly.Vertices(true));
            }

            return(new ElementLocation(startIndex, 0));
        }
 protected virtual void BuildLoopConcrete <TSegment>(FillLoop <TSegment> rolled, double useSpeed) where TSegment : IFillSegment, new()
 {
     Builder.AppendExtrude(rolled.Vertices(true).ToList(), useSpeed, rolled.FillType, null);
 }