예제 #1
0
        /// <summary>绘制圆形坐标在窗体上</summary>
        /// <param name="window">HALCON 窗体</param>
        public override void Draw(HWindow window)
        {
            //显示圆
            window.DispCircle(midR, midC, radius);

            int width = GetHandleWidth();

            //显示两个控制框
            window.DispRectangle2(row1, col1, 0, width, width);
            window.DispRectangle2(midR, midC, 0, width, width);
        }
예제 #2
0
        public override void draw(HWindow window, int imageWidth, int imageHeight)
        {
            window.SetColor(Color);
            window.SetDraw(DrawMode);
            window.SetLineWidth(LineWidth);
            window.SetLineStyle(LineStyle == "dot" ? new HTuple(2, 2) : new HTuple());

            window.DispCircle(midR, midC, radius);//body

            double littleRecSize = getHandleWidth(imageWidth, imageHeight);

            window.SetDraw("fill");
            window.DispRectangle2(midR, midC, 0, littleRecSize, littleRecSize);//0,mid

            if (Selected)
            {
                window.DispRectangle2(row1, col1, 0, littleRecSize, littleRecSize);//1,circle
            }
        }
예제 #3
0
        /// <summary>
        /// 显示圆
        /// </summary>
        public override void displayROI(HWindow hwin)
        {
            hwin.DispCircle(Center_row_y, Center_column_x, Radius);

            if (_operationing == -1)
            {
                hwin.DispRectangle2(Center_row_y, Center_column_x, 0, 5, 5);
                hwin.DispRectangle2(_row_r_y, _col_r_x, 0, 5, 5);
            }
            else
            {
                for (int i = 0; i < _operation_piont_number; i++)
                {
                    if (i == _operationing)
                    {
                        displayOperation(i, hwin);
                    }
                    else
                    {
                        no_chice_point(i, hwin);
                    }
                }
            }
        }
예제 #4
0
 /// <summary>Paints the ROI into the supplied window</summary>
 /// <param name="window">HALCON window</param>
 public override void Draw(HWindow window)
 {
     window.DispCircle(midR, midC, radius);
     window.DispRectangle2(row1, col1, 0, RoiDrawConfig.PaneWidth, RoiDrawConfig.PaneWidth);
     window.DispRectangle2(midR, midC, 0, RoiDrawConfig.PaneWidth, RoiDrawConfig.PaneWidth);
 }