Skip to content

unproject_coordinatesUnprojectCoordinatesUnprojectCoordinatesunproject_coordinatesT_unproject_coordinates🔗

Short description🔗

unproject_coordinatesUnprojectCoordinatesUnprojectCoordinatesunproject_coordinatesT_unproject_coordinates — Calculates image coordinates for a point in a 3D plot window.

Signature🔗

unproject_coordinates( image Image, window WindowHandle, integer Row, integer Column, out integer ImageRow, out integer ImageColumn, out real Height )void UnprojectCoordinates( const HObject& Image, const HTuple& WindowHandle, const HTuple& Row, const HTuple& Column, HTuple* ImageRow, HTuple* ImageColumn, HTuple* Height )static void HOperatorSet.UnprojectCoordinates( HObject image, HTuple windowHandle, HTuple row, HTuple column, out HTuple imageRow, out HTuple imageColumn, out HTuple height )def unproject_coordinates( image: HObject, window_handle: HHandle, row: Union[float, int], column: Union[float, int] ) -> Tuple[int, int, Union[int, float]]

Herror T_unproject_coordinates( const Hobject Image, const Htuple WindowHandle, const Htuple Row, const Htuple Column, Htuple* ImageRow, Htuple* ImageColumn, Htuple* Height )

void HImage::UnprojectCoordinates( const HWindow& WindowHandle, const HTuple& Row, const HTuple& Column, Hlong* ImageRow, Hlong* ImageColumn, HTuple* Height ) const

void HImage::UnprojectCoordinates( const HWindow& WindowHandle, double Row, double Column, Hlong* ImageRow, Hlong* ImageColumn, Hlong* Height ) const

void HWindow::UnprojectCoordinates( const HImage& Image, const HTuple& Row, const HTuple& Column, Hlong* ImageRow, Hlong* ImageColumn, HTuple* Height ) const

void HWindow::UnprojectCoordinates( const HImage& Image, double Row, double Column, Hlong* ImageRow, Hlong* ImageColumn, Hlong* Height ) const

void HImage.UnprojectCoordinates( HWindow windowHandle, HTuple row, HTuple column, out int imageRow, out int imageColumn, out HTuple height )

void HImage.UnprojectCoordinates( HWindow windowHandle, double row, double column, out int imageRow, out int imageColumn, out int height )

void HWindow.UnprojectCoordinates( HImage image, HTuple row, HTuple column, out int imageRow, out int imageColumn, out HTuple height )

void HWindow.UnprojectCoordinates( HImage image, double row, double column, out int imageRow, out int imageColumn, out int height )

Description🔗

If Imageimageimage is displayed in WindowHandlewindowHandlewindow_handle using a 3D plot (i.e., '3d_plot'"3d_plot" was set using set_paintSetPaint), unproject_coordinatesUnprojectCoordinates calculates the image coordinates ImageRowimageRowimage_row, ImageColumnimageColumnimage_column, and the Heightheightheight for a given point Rowrowrow,Columncolumncolumn in window coordinates. The window coordinates Rowrowrow, Columncolumncolumn must be provided in respect to the current image part. As a consequence, this coordinates are subpixel coordinates. Given the current image part (row1,column1,row2, column2), the upper left corner corresponds to the coordinates (row1 - 0.5, col1 - 0.5). Accordingly, the bottom right corner corresponds to the coordinates (row2 - 0.5, col2 - 0.5). Use get_mposition_sub_pixGetMpositionSubPix or get_mbutton_sub_pixGetMbuttonSubPix to obtain these coordinates directly.

One of the window parameters 'save_depth_buffer'"save_depth_buffer" or 'interactive_plot'"interactive_plot" must be set to 'true'"true" using set_window_paramSetWindowParam. Otherwise, unproject_coordinatesUnprojectCoordinates cannot be used.

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🔗

Imageimageimage (input_object) singlechannelimage → object (byte / direction / cyclic / int1 / int2 / uint2 / int4 / real / complex / vector_field)HObject (byte / direction / cyclic / int1 / int2 / uint2 / int4 / real / complex / vector_field)HImage (byte / direction / cyclic / int1 / int2 / uint2 / int4 / real / complex / vector_field)HObject (byte / direction / cyclic / int1 / int2 / uint2 / int4 / real / complex / vector_field)Hobject (byte / direction / cyclic / int1 / int2 / uint2 / int4 / real / complex / vector_field)

Displayed image.

WindowHandlewindowHandlewindow_handle (input_control) window → (handle)HTuple (HHandle)HWindow, HTuple (IntPtr)HHandleHtuple (handle)

Window handle.

Rowrowrow (input_control) integer → (real / integer)HTuple (double / Hlong)HTuple (double / int / long)Union[float, int]Htuple (double / Hlong)

Row coordinate in the window.

Columncolumncolumn (input_control) integer → (real / integer)HTuple (double / Hlong)HTuple (double / int / long)Union[float, int]Htuple (double / Hlong)

Column coordinate in the window.

ImageRowimageRowimage_row (output_control) integer → (integer)HTuple (Hlong)HTuple (int / long)intHtuple (Hlong)

Row coordinate in the image.

ImageColumnimageColumnimage_column (output_control) integer → (integer)HTuple (Hlong)HTuple (int / long)intHtuple (Hlong)

Column coordinate in the image.

Heightheightheight (output_control) real → (integer / real)HTuple (Hlong / double)HTuple (int / long / double)Union[int, float]Htuple (Hlong / double)

Height value.

Combinations with other operators🔗

Combinations

Possible predecessors

get_mbutton_sub_pixGetMbuttonSubPix, get_mposition_sub_pixGetMpositionSubPix, disp_imageDispImage

See also

disp_objDispObj, update_window_poseUpdateWindowPose, set_paintSetPaint

Module🔗

Foundation