Beispiel #1
0
        public sNurbsCurve DuplicatesNurbsCurve()
        {
            List <sXYZ> cpts = new List <sXYZ>();

            foreach (sXYZ cp in this.controlPoints)
            {
                cpts.Add(cp.DuplicatesXYZ());
            }
            sNurbsCurve nc = new sNurbsCurve(cpts, this.weights.ToList(), this.knots.ToList(), this.length, this.degree);

            nc.objectGUID = this.objectGUID;
            return(nc);
        }
 public sCurve DuplicatesCurve()
 {
     if (this.curveType == eCurveType.LINE)
     {
         sLine sc = this as sLine;
         return(sc.DuplicatesLine());
     }
     else if (this.curveType == eCurveType.POLYLINE)
     {
         sPolyLine thispl = this as sPolyLine;
         return(thispl.DuplicatesPolyline());
     }
     else if (this.curveType == eCurveType.NURBSCURVE)
     {
         sNurbsCurve nc = this as sNurbsCurve;
         return(nc.DuplicatesNurbsCurve());
     }
     else
     {
         return(null);
     }
 }