DrawLine2D


Synopsis

Draw a 2D line.

Note: This object has superceded a previous version of an object with the same name. Please note that the older version's template is VIEW.Viewers.DrawLine2D, and this version's template is GDM.Viewers.DrawLine2D. The render_view input port present in the old template is no longer necessary when used with the new Uviewers.

V name

GDM.DrawLine2D

Input Ports

view_in

GDview_templ

obj_in

GDobject_templ

 

Output Ports

draw_line.GDmap2D_ss.out_mesh

Mesh+Cell_Data

 

Description

DrawLine2D displays a 2D line and translates the line's screen space coordinates into a field. DrawLine2D is a macro that combines the following:

•      aUItwoPoint interactor

•      GDroi2d_cont

•      GDmap2d_ss

•      a user interface, which the user accesses through the Module Panel provided by the DataViewer or ModuleStack (as appropriate)

Input Ports

view_in

A connection to a view.

obj_in

An optional connection to an object. Without an object, DrawLine2D converts the line to a field in the camera's coordinate system. With an object, DrawLine2D converts the line to a field in the object's coordinate system.

Parameters

draw_mode

UIradioBox. This parameter indicates whether to draw in copy mode (0) or XORmode (1). In copy mode, the rendering window is refreshed as necessary with a pre-drawing copy of the window's contents, if possible. In XOR mode, the drawing is created (and subsequently refreshed) by performing an XOR operation on the background. XOR mode is generally faster.

immed

UItoggle. This parameter controls whether the line is immediately converted to a mesh: 1 means yes; 0 means no. When the value is 0, you must press the measure button to cause the line to be converted to a mesh.

measure

UIbutton. This parameter when set causes the line to be converted to a field.

Output Ports

out_mesh

A mesh representing the point in the appropriate coordinate system.

Example

Libraries.Examples.Graphics_Display.DrawLine2D
Libraries.Examples.Graphics_Display.ImageMeasure

File

v/view.v

See also