예제 #1
0
        public virtual void RotateAtCentroid(float degrees)
        {
            PolygonF rotatePly = PolygonF.Rotate(this, degrees, this.Centroid);

            this.Clear();
            this._pnts.AddRange(rotatePly._pnts.ToArray());
            if (this._preCalcBBox)
            {
                this.UpdateMinMax(this._pnts);
            }
            rotatePly.Clear();
        }
예제 #2
0
 public static Polygon Rotate(Polygon ply, float degrees, Point center)
 {
     return(Polygon.Truncate(PolygonF.Rotate(ply._ply, degrees, new PointF((float)center.X, (float)center.Y))));
 }