示例#1
0
        /*
         *        METHODS: I_DRAWABLE
         */
        public void Draw(I_Draw i_Draw, DrawParam dp)
        {
            DrawParamKnot dpKnot = dp as DrawParamKnot;

            if (dpKnot != null)
            {
                i_Draw.DrawPnt(this.Val.X, this.Val.Y,
                               dpKnot.ScrRad, dpKnot.StrColor, dpKnot.ScrWidth, this.on);
                if (dpKnot.ToShowNumber)
                {
                    i_Draw.DrawString(this.indexKnot.ToString(), this.Val.X, this.Val.Y,
                                      "Blue", 5, 1, -7);
                }
            }
        }
示例#2
0
        /*
         *        METHODS:    I_DRAWABLE
         */

        public void Draw(I_Draw i_draw, DrawParam dp)
        {
            // for debug only - begin

            /*
             * if (this.rayTmp!=null)
             * {
             *  DrawParamCurve dpCurve=new DrawParamCurve("Cyan",1,false,null);
             *  this.rayTmp.Draw(i_draw, dpCurve);
             * }
             */
            // for debug only - end
            DrawParamContour dpContour = dp as DrawParamContour;

            if (dpContour != null)
            {
                DrawParamKnot dpKnot = dpContour.DPKnot;
                if (dpKnot != null)
                {
                    foreach (Knot knot in this.knots)
                    {
                        knot.Draw(i_draw, dpKnot);
                    }
                }
                DrawParamCurve dpCurve = dpContour.DPCurve;
                if (dpCurve != null)
                {
                    for (int poz = 0; poz < this.NumKnot; poz++)
                    {
                        BCurve curve = this.CurveByPoz(poz);
                        if (curve != null)
                        {
                            curve.Draw(i_draw, dpCurve);
                        }
                    }
                }
            }
        }
示例#3
0
 // members
 override public void ClearRelease()
 {
     this.dpCurve=null;
     this.dpKnot=null;
 }
示例#4
0
 // constructors
 public DrawParamContour(DrawParamCurve dpCurve, DrawParamKnot dpKnot)
     : base(null,0)
 {
     this.dpCurve=dpCurve;
     this.dpKnot=dpKnot;
 }
示例#5
0
        /*
         *        METHODS:    I_DRAWABLE
         */
        public void Draw(I_Draw i_draw, DrawParam dp)
        {

            if (this.bbox!=null)
            {
                DrawParam dpBBox=new DrawParam("Yellow",0.5F);
                this.bbox.Draw(i_draw, dpBBox);
            }

            if (this.outl!=null)
            {
                DrawParamKnot dpKnot=new DrawParamKnot("Blue",0.5F,1.5F,true);
                DrawParamVec dpEndPoints=new DrawParamVec("Orange",0.5F,0.7F,true);
                
                string colorCurve;
                if (this.typeGlyph==GConsts.TypeGlyph.Composite)
                {
                    colorCurve="Blue";
                }
                else
                {
                    bool isOrientDefined=
                        (this.statusGV[(int)DefsGV.TypeGV.ValidateSimpContMisor].IsValid)&&
                        (this.statusGV[(int)DefsGV.TypeGV.ValidateSimpContMisor].StatusExec==
                        StatusGV.TypeStatusExec.Completed);
                    colorCurve=isOrientDefined? "Blue": "Green";
                }
                DrawParamCurve dpCurve=new DrawParamCurve(colorCurve,1F,true,dpEndPoints);
                DrawParamContour dpContour=new DrawParamContour(dpCurve,dpKnot);
            
                this.outl.Draw(i_draw, dpContour);

                BoxD bboxComputed=this.outl.BBox;
                bboxComputed.SetEnlargeFU();
                DrawParam dpBBoxComputed=new DrawParam("Yellow",0.5F);
                bboxComputed.Draw(i_draw,dpBBoxComputed);
            }
        }
示例#6
0
 // members
 override public void ClearRelease()
 {
     this.dpCurve = null;
     this.dpKnot  = null;
 }
示例#7
0
 // constructors
 public DrawParamContour(DrawParamCurve dpCurve, DrawParamKnot dpKnot)
     : base(null, 0)
 {
     this.dpCurve = dpCurve;
     this.dpKnot  = dpKnot;
 }