Skip to content

draw_rectangle2_modDrawRectangle2ModDrawRectangle2Moddraw_rectangle2_modT_draw_rectangle2_modπŸ”—

Short descriptionπŸ”—

draw_rectangle2_modDrawRectangle2ModDrawRectangle2Moddraw_rectangle2_modT_draw_rectangle2_mod β€” Interactive drawing of any orientated rectangle.

SignatureπŸ”—

draw_rectangle2_mod( window WindowHandle, rectangle2.center.y RowIn, rectangle2.center.x ColumnIn, rectangle2.angle.rad PhiIn, rectangle2.hwidth Length1In, rectangle2.hheight Length2In, out rectangle2.center.y Row, out rectangle2.center.x Column, out rectangle2.angle.rad Phi, out rectangle2.hwidth Length1, out rectangle2.hheight Length2 )void DrawRectangle2Mod( const HTuple& WindowHandle, const HTuple& RowIn, const HTuple& ColumnIn, const HTuple& PhiIn, const HTuple& Length1In, const HTuple& Length2In, HTuple* Row, HTuple* Column, HTuple* Phi, HTuple* Length1, HTuple* Length2 )static void HOperatorSet.DrawRectangle2Mod( HTuple windowHandle, HTuple rowIn, HTuple columnIn, HTuple phiIn, HTuple length1In, HTuple length2In, out HTuple row, out HTuple column, out HTuple phi, out HTuple length1, out HTuple length2 )def draw_rectangle2_mod( window_handle: HHandle, row_in: float, column_in: float, phi_in: float, length_1in: float, length_2in: float ) -> Tuple[float, float, float, float, float]

Herror T_draw_rectangle2_mod( const Htuple WindowHandle, const Htuple RowIn, const Htuple ColumnIn, const Htuple PhiIn, const Htuple Length1In, const Htuple Length2In, Htuple* Row, Htuple* Column, Htuple* Phi, Htuple* Length1, Htuple* Length2 )

void HWindow::DrawRectangle2Mod( double RowIn, double ColumnIn, double PhiIn, double Length1In, double Length2In, double* Row, double* Column, double* Phi, double* Length1, double* Length2 ) const

void HWindow.DrawRectangle2Mod( double rowIn, double columnIn, double phiIn, double length1In, double length2In, out double row, out double column, out double phi, out double length1, out double length2 )

DescriptionπŸ”—

draw_rectangle2_modDrawRectangle2Mod returns the parameter for any orientated rectangle, which has been created interactively by the user in the window.

The created rectangle is described by its center, its two half axes and the angle between the first half axis and the horizontal coordinate axis.

To create a rectangle are expected the parameters RowInrowInrow_in, ColumnIncolumnIncolumn_in,PhiInphiInphi_in,Length1Inlength1Inlength_1in,Length2Inlength2Inlength_2in. A click close to one side β€œgrips” it to modify the rectangle’s dimension in perpendicular direction (Length2length2length_2) to this side. You only can modify the orientation (Phiphiphi), if you grip a side perpendicular to the first half axis. After another mouse click in the middle of the created rectangle, you can move it. Pressing the right mouse button terminates the procedure.

After terminating the procedure the rectangle 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πŸ”—

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πŸ”—

WindowHandlewindowHandlewindow_handle (input_control) window β†’ (handle)HTuple (HHandle)HWindow, HTuple (IntPtr)HHandleHtuple (handle)

Window handle.

RowInrowInrow_in (input_control) rectangle2.center.y β†’ (real)HTuple (double)HTuple (double)floatHtuple (double)

Row index of the center.

ColumnIncolumnIncolumn_in (input_control) rectangle2.center.x β†’ (real)HTuple (double)HTuple (double)floatHtuple (double)

Column index of the center.

PhiInphiInphi_in (input_control) rectangle2.angle.rad β†’ (real)HTuple (double)HTuple (double)floatHtuple (double)

Orientation of the bigger half axis in radians.

Length1Inlength1Inlength_1in (input_control) rectangle2.hwidth β†’ (real)HTuple (double)HTuple (double)floatHtuple (double)

Bigger half axis.

Length2Inlength2Inlength_2in (input_control) rectangle2.hheight β†’ (real)HTuple (double)HTuple (double)floatHtuple (double)

Smaller half axis.

Rowrowrow (output_control) rectangle2.center.y β†’ (real)HTuple (double)HTuple (double)floatHtuple (double)

Row index of the center.

Columncolumncolumn (output_control) rectangle2.center.x β†’ (real)HTuple (double)HTuple (double)floatHtuple (double)

Column index of the center.

Phiphiphi (output_control) rectangle2.angle.rad β†’ (real)HTuple (double)HTuple (double)floatHtuple (double)

Orientation of the bigger half axis in radians.

Length1length1length_1 (output_control) rectangle2.hwidth β†’ (real)HTuple (double)HTuple (double)floatHtuple (double)

Bigger half axis.

Length2length2length_2 (output_control) rectangle2.hheight β†’ (real)HTuple (double)HTuple (double)floatHtuple (double)

Smaller half axis.

ResultπŸ”—

draw_rectangle2_modDrawRectangle2Mod returns 2 (H_MSG_TRUE) if the window is valid. If necessary, an exception is raised.

Combinations with other operatorsπŸ”—

Combinations

Possible predecessors

open_windowOpenWindow

Possible successors

reduce_domainReduceDomain, disp_regionDispRegion, set_coloredSetColored, set_line_widthSetLineWidth, set_drawSetDraw

Alternatives

draw_rectangle2DrawRectangle2, draw_rectangle1DrawRectangle1, draw_rectangle2DrawRectangle2, draw_regionDrawRegion

See also

gen_rectangle2GenRectangle2, draw_circleDrawCircle, draw_ellipseDrawEllipse

ModuleπŸ”—

Foundation