| HALCON Reference Manual / Graphics / Mouse | Operators |
get_mbutton_sub_pix — Wait until a mouse button is pressed and get the subpixel mouse position.
get_mbutton_sub_pix( : : WindowHandle : Row, Column, Button)
get_mbutton_sub_pix returns the subpixel accurate image coordinates of the mouse pointer in the output window and the mouse button pressed (Button):
Button = 1: Left button,
2: Middle button,
4: Right button.
The operator waits until a button is pressed in the output window. If more than one button is pressed, the sum of the individual buttons' values is returned. For graphics windows the coordinates Row and Column are expressed with consideration of the current image part (see set_part). For text windows the coordinates of the upper left corner are (-0.5,-0.5), while the coordinates of the lower right corner are (window height-0.5,window width-0.5) (see open_textwindow).
If only pixel accurate image coordinates are required, you can use the operator get_mbutton.
get_mbutton_sub_pix only returns if a mouse button is pressed in the window.
| WindowHandle (input_control) | window → (integer) |
| Window identifier. | |
| Row (output_control) | point.y → (real) |
| Row coordinate of the mouse position in the window. | |
| Column (output_control) | point.x → (real) |
| Column coordinate of the mouse position in the window. | |
| Button (output_control) | integer → (integer) |
| Mouse button(s) pressed. | |
get_mbutton_sub_pix returns the value 2 (H_MSG_TRUE).
get_mbutton_sub_pix is reentrant, local, and processed without parallelization.
get_mbutton, get_mposition, get_mposition_sub_pix
Foundation
| HALCON Reference Manual / Graphics / Mouse | Operators |
| Version 9.0.2 | Copyright © 1996-2010 MVTec Software GmbH |