File: vtkwidgets_vtkpointwidget.html

package info (click to toggle)
freemat 4.2%2Bdfsg1-4
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 141,800 kB
  • ctags: 14,082
  • sloc: ansic: 126,788; cpp: 62,046; python: 2,080; perl: 1,255; sh: 1,146; yacc: 1,019; lex: 239; makefile: 100
file content (166 lines) | stat: -rw-r--r-- 10,894 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>FreeMat: vtkPointWidget</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">FreeMat
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.1.1 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="pages.html"><span>Related&#160;Pages</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('vtkwidgets_vtkpointwidget.html','');});
</script>
<div id="doc-content">
<div class="header">
  <div class="headertitle">
<div class="title">vtkPointWidget </div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><p>Section: <a class="el" href="sec_vtkwidgets.html">Visualization Toolkit Widget Classes</a> </p>
<h1><a class="anchor" id="Usage"></a>
Usage</h1>
<p>This 3D widget allows the user to position a point in 3D space using a 3D cursor. The cursor has an outline bounding box, axes-aligned cross-hairs, and axes shadows. (The outline and shadows can be turned off.) Any of these can be turned off. A nice feature of the object is that the vtkPointWidget, like any 3D widget, will work with the current interactor style. That is, if vtkPointWidget does not handle an event, then all other registered observers (including the interactor style) have an opportunity to process the event. Otherwise, the vtkPointWidget will terminate the processing of the event that it handles.</p>
<p>To use this object, just invoke SetInteractor() with the argument of the method a vtkRenderWindowInteractor. You may also wish to invoke "PlaceWidget()" to initially position the widget. The interactor will act normally until the "i" key (for "interactor") is pressed, at which point the vtkPointWidget will appear. (See superclass documentation for information about changing this behavior.) To move the point, the user can grab (left mouse) on any widget line and "slide" the point into position. Scaling is achieved by using the right mouse button "up" the render window (makes the widget bigger) or "down" the render window (makes the widget smaller). To translate the widget use the middle mouse button. (Note: all of the translation interactions can be constrained to one of the x-y-z axes by using the "shift" key.) The vtkPointWidget produces as output a polydata with a single point and a vertex cell.</p>
<p>Some additional features of this class include the ability to control the rendered properties of the widget. You can set the properties of the selected and unselected representations of the parts of the widget. For example, you can set the property of the 3D cursor in its normal and selected states.</p>
<p>To create an instance of class vtkPointWidget, simply invoke its constructor as follows </p>
<pre class="fragment">  obj = vtkPointWidget
</pre> <h1><a class="anchor" id="Methods"></a>
Methods</h1>
<p>The class vtkPointWidget has several methods that can be used. They are listed below. Note that the documentation is translated automatically from the VTK sources, and may not be completely intelligible. When in doubt, consult the VTK website. In the methods listed below, <code>obj</code> is an instance of the vtkPointWidget class. </p>
<ul>
<li>
<code>string = obj.GetClassName ()</code>  </li>
<li>
<code>int = obj.IsA (string name)</code>  </li>
<li>
<code>vtkPointWidget = obj.NewInstance ()</code>  </li>
<li>
<code>vtkPointWidget = obj.SafeDownCast (vtkObject o)</code>  </li>
<li>
<code>obj.SetEnabled (int )</code> - Methods that satisfy the superclass' API.  </li>
<li>
<code>obj.PlaceWidget (double bounds[6])</code> - Methods that satisfy the superclass' API.  </li>
<li>
<code>obj.PlaceWidget ()</code> - Methods that satisfy the superclass' API.  </li>
<li>
<code>obj.PlaceWidget (double xmin, double xmax, double ymin, double ymax, double zmin, double zmax)</code> - Grab the polydata (including points) that defines the point. A single point and a vertex compose the vtkPolyData.  </li>
<li>
<code>obj.GetPolyData (vtkPolyData pd)</code> - Grab the polydata (including points) that defines the point. A single point and a vertex compose the vtkPolyData.  </li>
<li>
<code>obj.SetPosition (double x, double y, double z)</code> - Set/Get the position of the point. Note that if the position is set outside of the bounding box, it will be clamped to the boundary of the bounding box.  </li>
<li>
<code>obj.SetPosition (double x[3])</code> - Set/Get the position of the point. Note that if the position is set outside of the bounding box, it will be clamped to the boundary of the bounding box.  </li>
<li>
<code>double = obj.GetPosition ()</code> - Set/Get the position of the point. Note that if the position is set outside of the bounding box, it will be clamped to the boundary of the bounding box.  </li>
<li>
<code>obj.GetPosition (double xyz[3])</code> - Turn on/off the wireframe bounding box.  </li>
<li>
<code>obj.SetOutline (int o)</code> - Turn on/off the wireframe bounding box.  </li>
<li>
<code>int = obj.GetOutline ()</code> - Turn on/off the wireframe bounding box.  </li>
<li>
<code>obj.OutlineOn ()</code> - Turn on/off the wireframe bounding box.  </li>
<li>
<code>obj.OutlineOff ()</code> - Turn on/off the wireframe x-shadows.  </li>
<li>
<code>obj.SetXShadows (int o)</code> - Turn on/off the wireframe x-shadows.  </li>
<li>
<code>int = obj.GetXShadows ()</code> - Turn on/off the wireframe x-shadows.  </li>
<li>
<code>obj.XShadowsOn ()</code> - Turn on/off the wireframe x-shadows.  </li>
<li>
<code>obj.XShadowsOff ()</code> - Turn on/off the wireframe y-shadows.  </li>
<li>
<code>obj.SetYShadows (int o)</code> - Turn on/off the wireframe y-shadows.  </li>
<li>
<code>int = obj.GetYShadows ()</code> - Turn on/off the wireframe y-shadows.  </li>
<li>
<code>obj.YShadowsOn ()</code> - Turn on/off the wireframe y-shadows.  </li>
<li>
<code>obj.YShadowsOff ()</code> - Turn on/off the wireframe z-shadows.  </li>
<li>
<code>obj.SetZShadows (int o)</code> - Turn on/off the wireframe z-shadows.  </li>
<li>
<code>int = obj.GetZShadows ()</code> - Turn on/off the wireframe z-shadows.  </li>
<li>
<code>obj.ZShadowsOn ()</code> - Turn on/off the wireframe z-shadows.  </li>
<li>
<code>obj.ZShadowsOff ()</code> - If translation mode is on, as the widget is moved the bounding box, shadows, and cursor are all translated simultaneously as the point moves.  </li>
<li>
<code>obj.SetTranslationMode (int mode)</code> - If translation mode is on, as the widget is moved the bounding box, shadows, and cursor are all translated simultaneously as the point moves.  </li>
<li>
<code>int = obj.GetTranslationMode ()</code> - If translation mode is on, as the widget is moved the bounding box, shadows, and cursor are all translated simultaneously as the point moves.  </li>
<li>
<code>obj.TranslationModeOn ()</code> - If translation mode is on, as the widget is moved the bounding box, shadows, and cursor are all translated simultaneously as the point moves.  </li>
<li>
<code>obj.TranslationModeOff ()</code> - Convenience methods to turn outline and shadows on and off.  </li>
<li>
<code>obj.AllOn ()</code> - Convenience methods to turn outline and shadows on and off.  </li>
<li>
<code>obj.AllOff ()</code> - Get the handle properties (the little balls are the handles). The properties of the handles when selected and normal can be set.  </li>
<li>
<code>vtkProperty = obj.GetProperty ()</code> - Get the handle properties (the little balls are the handles). The properties of the handles when selected and normal can be set.  </li>
<li>
<code>vtkProperty = obj.GetSelectedProperty ()</code> - Get the handle properties (the little balls are the handles). The properties of the handles when selected and normal can be set.  </li>
<li>
<code>obj.SetHotSpotSize (double )</code> - Set the "hot spot" size; i.e., the region around the focus, in which the motion vector is used to control the constrained sliding action. Note the size is specified as a fraction of the length of the diagonal of the point widget's bounding box.  </li>
<li>
<code>double = obj.GetHotSpotSizeMinValue ()</code> - Set the "hot spot" size; i.e., the region around the focus, in which the motion vector is used to control the constrained sliding action. Note the size is specified as a fraction of the length of the diagonal of the point widget's bounding box.  </li>
<li>
<code>double = obj.GetHotSpotSizeMaxValue ()</code> - Set the "hot spot" size; i.e., the region around the focus, in which the motion vector is used to control the constrained sliding action. Note the size is specified as a fraction of the length of the diagonal of the point widget's bounding box.  </li>
<li>
<code>double = obj.GetHotSpotSize ()</code> - Set the "hot spot" size; i.e., the region around the focus, in which the motion vector is used to control the constrained sliding action. Note the size is specified as a fraction of the length of the diagonal of the point widget's bounding box.  </li>
</ul>
</div></div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="index.html">FreeMat Documentation</a></li><li class="navelem"><a class="el" href="sec_vtkwidgets.html">Visualization Toolkit Widget Classes</a></li>
    <li class="footer">Generated on Thu Jul 25 2013 17:18:36 for FreeMat by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.1.1 </li>
  </ul>
</div>
</body>
</html>