draw_circle_modT_draw_circle_modDrawCircleModDrawCircleMod (Operator)
Name
draw_circle_modT_draw_circle_modDrawCircleModDrawCircleMod
— Interactive drawing of a circle.
Signature
void DrawCircleMod(const HTuple& WindowHandle, const HTuple& RowIn, const HTuple& ColumnIn, const HTuple& RadiusIn, HTuple* Row, HTuple* Column, HTuple* Radius)
void HWindow::DrawCircleMod(double RowIn, double ColumnIn, double RadiusIn, double* Row, double* Column, double* Radius) const
static void HOperatorSet.DrawCircleMod(HTuple windowHandle, HTuple rowIn, HTuple columnIn, HTuple radiusIn, out HTuple row, out HTuple column, out HTuple radius)
void HWindow.DrawCircleMod(double rowIn, double columnIn, double radiusIn, out double row, out double column, out double radius)
Description
draw_circle_moddraw_circle_modDrawCircleModDrawCircleModDrawCircleMod
produces the parameter for a circle created interactive by
the user in the window.
To create a circle are expected the coordinates RowInRowInRowInRowInrowIn
and
ColumnInColumnInColumnInColumnIncolumnIn
of the center of a circle with radius RadiusInRadiusInRadiusInRadiusInradiusIn
.
After another mouse click in the created circle center you can move it.
A clicking close to the circular arc you can modify the RadiusRadiusRadiusRadiusradius
of
the circle.
Pressing the right mousebutton terminates the procedure. On macOS
draw_circle_moddraw_circle_modDrawCircleModDrawCircleModDrawCircleMod
can also be terminated by pressing the escape key.
After terminating the procedure the circle is not visible in the window any longer.
Attention
If used in a buffer window, mouse events have to be supplied by the
application, while the draw operator must be run in another thread.
Execution Information
- Multithreading type: reentrant (runs in parallel with non-exclusive operators).
- Multithreading scope: global (may be called from any thread).
- Processed without parallelization.
Parameters
WindowHandleWindowHandleWindowHandleWindowHandlewindowHandle
(input_control) window →
HWindow, HTupleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)
Window handle.
RowInRowInRowInRowInrowIn
(input_control) circle.center.y →
HTupleHTupleHtuple (real) (double) (double) (double)
Row index of the center.
ColumnInColumnInColumnInColumnIncolumnIn
(input_control) circle.center.x →
HTupleHTupleHtuple (real) (double) (double) (double)
Column index of the center.
RadiusInRadiusInRadiusInRadiusInradiusIn
(input_control) circle.radius →
HTupleHTupleHtuple (real) (double) (double) (double)
Radius of the circle.
RowRowRowRowrow
(output_control) circle.center.y →
HTupleHTupleHtuple (real) (double) (double) (double)
Row index of the center.
ColumnColumnColumnColumncolumn
(output_control) circle.center.x →
HTupleHTupleHtuple (real) (double) (double) (double)
Column index of the center.
RadiusRadiusRadiusRadiusradius
(output_control) circle.radius →
HTupleHTupleHtuple (real) (double) (double) (double)
Circle's radius.
Example (HDevelop)
read_image(Image,'monkey')
draw_circle_mod(WindowHandle,20,20,15,Row,Column,Radius)
gen_circle(Circle,Row,Column,Radius)
reduce_domain(Image,Circle,ImageReduced)
invert_image (ImageReduced, ImageInvert)
dev_display (ImageInvert)
Example (C)
read_image(&Image,"monkey");
draw_circle_mod(WindowHandle,20,20,15,&Row,&Column,&Radius);
gen_circle(&Circle,Row,Column,Radius);
reduce_domain(Image,Circle,&GrayCircle);
disp_image(GrayCircle,WindowHandle);
Example (HDevelop)
read_image(Image,'monkey')
draw_circle_mod(WindowHandle,20,20,15,Row,Column,Radius)
gen_circle(Circle,Row,Column,Radius)
reduce_domain(Image,Circle,ImageReduced)
invert_image (ImageReduced, ImageInvert)
dev_display (ImageInvert)
Example (HDevelop)
read_image(Image,'monkey')
draw_circle_mod(WindowHandle,20,20,15,Row,Column,Radius)
gen_circle(Circle,Row,Column,Radius)
reduce_domain(Image,Circle,ImageReduced)
invert_image (ImageReduced, ImageInvert)
dev_display (ImageInvert)
Example (HDevelop)
read_image(Image,'monkey')
draw_circle_mod(WindowHandle,20,20,15,Row,Column,Radius)
gen_circle(Circle,Row,Column,Radius)
reduce_domain(Image,Circle,ImageReduced)
invert_image (ImageReduced, ImageInvert)
dev_display (ImageInvert)
Result
draw_circle_moddraw_circle_modDrawCircleModDrawCircleModDrawCircleMod
returns 2 (H_MSG_TRUE) if the window is valid and the
needed drawing mode (see set_insertset_insertSetInsertSetInsertSetInsert
) is available.
If necessary, an exception is raised.
Possible Predecessors
open_windowopen_windowOpenWindowOpenWindowOpenWindow
Possible Successors
reduce_domainreduce_domainReduceDomainReduceDomainReduceDomain
,
disp_regiondisp_regionDispRegionDispRegionDispRegion
,
set_coloredset_coloredSetColoredSetColoredSetColored
,
set_line_widthset_line_widthSetLineWidthSetLineWidthSetLineWidth
,
set_drawset_drawSetDrawSetDrawSetDraw
,
set_insertset_insertSetInsertSetInsertSetInsert
Alternatives
draw_circledraw_circleDrawCircleDrawCircleDrawCircle
,
draw_ellipsedraw_ellipseDrawEllipseDrawEllipseDrawEllipse
,
draw_regiondraw_regionDrawRegionDrawRegionDrawRegion
See also
gen_circlegen_circleGenCircleGenCircleGenCircle
,
draw_rectangle1draw_rectangle1DrawRectangle1DrawRectangle1DrawRectangle1
,
draw_rectangle2draw_rectangle2DrawRectangle2DrawRectangle2DrawRectangle2
,
draw_polygondraw_polygonDrawPolygonDrawPolygonDrawPolygon
,
set_insertset_insertSetInsertSetInsertSetInsert
Module
Foundation