<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"> <title>VTK: dox/Widgets/vtkSliderRepresentation2D.h Source File</title> <link href="doxygen.css" rel="stylesheet" type="text/css"> <link href="tabs.css" rel="stylesheet" type="text/css"> </head><body> <!-- Generated by Doxygen 1.5.6 --> <div class="navigation" id="top"> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li><a href="classes.html"><span>Classes</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> </ul> </div> <h1>dox/Widgets/vtkSliderRepresentation2D.h</h1><a href="a03733.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*=========================================================================</span> <a name="l00002"></a>00002 <span class="comment"></span> <a name="l00003"></a>00003 <span class="comment"> Program: Visualization Toolkit</span> <a name="l00004"></a>00004 <span class="comment"> Module: $RCSfile: vtkSliderRepresentation2D.h,v $</span> <a name="l00005"></a>00005 <span class="comment"></span> <a name="l00006"></a>00006 <span class="comment"> Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen</span> <a name="l00007"></a>00007 <span class="comment"> All rights reserved.</span> <a name="l00008"></a>00008 <span class="comment"> See Copyright.txt or http://www.kitware.com/Copyright.htm for details.</span> <a name="l00009"></a>00009 <span class="comment"></span> <a name="l00010"></a>00010 <span class="comment"> This software is distributed WITHOUT ANY WARRANTY; without even</span> <a name="l00011"></a>00011 <span class="comment"> the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR</span> <a name="l00012"></a>00012 <span class="comment"> PURPOSE. See the above copyright notice for more information.</span> <a name="l00013"></a>00013 <span class="comment"></span> <a name="l00014"></a>00014 <span class="comment">=========================================================================*/</span> <a name="l00031"></a>00031 <span class="preprocessor">#ifndef __vtkSliderRepresentation2D_h</span> <a name="l00032"></a>00032 <span class="preprocessor"></span><span class="preprocessor">#define __vtkSliderRepresentation2D_h</span> <a name="l00033"></a>00033 <span class="preprocessor"></span> <a name="l00034"></a>00034 <span class="preprocessor">#include "<a class="code" href="a03732.html">vtkSliderRepresentation.h</a>"</span> <a name="l00035"></a>00035 <span class="preprocessor">#include "<a class="code" href="a02219.html">vtkCoordinate.h</a>"</span> <span class="comment">// For vtkViewportCoordinateMacro</span> <a name="l00036"></a>00036 <a name="l00037"></a>00037 <span class="keyword">class </span><a class="code" href="a01250.html" title="represent and manipulate 3D points">vtkPoints</a>; <a name="l00038"></a>00038 <span class="keyword">class </span><a class="code" href="a00242.html" title="object to represent cell connectivity">vtkCellArray</a>; <a name="l00039"></a>00039 <span class="keyword">class </span><a class="code" href="a01260.html" title="concrete dataset represents vertices, lines, polygons, and triangle strips">vtkPolyData</a>; <a name="l00040"></a>00040 <span class="keyword">class </span><a class="code" href="a01266.html" title="draw vtkPolyData onto the image plane">vtkPolyDataMapper2D</a>; <a name="l00041"></a>00041 <span class="keyword">class </span><a class="code" href="a00093.html" title="a actor that draws 2D data">vtkActor2D</a>; <a name="l00042"></a>00042 <span class="keyword">class </span><a class="code" href="a00335.html" title="perform coordinate transformation, and represent position, in a variety of vtk coordinate...">vtkCoordinate</a>; <a name="l00043"></a>00043 <span class="keyword">class </span><a class="code" href="a01323.html" title="represent surface properties of a 2D image">vtkProperty2D</a>; <a name="l00044"></a>00044 <span class="keyword">class </span><a class="code" href="a01321.html" title="a list of Props">vtkPropCollection</a>; <a name="l00045"></a>00045 <span class="keyword">class </span><a class="code" href="a01886.html" title="window superclass for vtkRenderWindow">vtkWindow</a>; <a name="l00046"></a>00046 <span class="keyword">class </span><a class="code" href="a01833.html" title="abstract specification for Viewports">vtkViewport</a>; <a name="l00047"></a>00047 <span class="keyword">class </span><a class="code" href="a01723.html" title="describes linear transformations via a 4x4 matrix">vtkTransform</a>; <a name="l00048"></a>00048 <span class="keyword">class </span><a class="code" href="a01731.html" title="transform points and associated normals and vectors for polygonal dataset">vtkTransformPolyDataFilter</a>; <a name="l00049"></a>00049 <span class="keyword">class </span><a class="code" href="a01692.html" title="represent text properties.">vtkTextProperty</a>; <a name="l00050"></a>00050 <span class="keyword">class </span><a class="code" href="a01691.html" title="2D text annotation">vtkTextMapper</a>; <a name="l00051"></a>00051 <span class="keyword">class </span><a class="code" href="a01689.html" title="An actor that displays text. Scaled or unscaled.">vtkTextActor</a>; <a name="l00052"></a>00052 <a name="l00053"></a>00053 <a name="l00054"></a><a class="code" href="a01559.html">00054</a> <span class="keyword">class </span><a class="code" href="a02170.html#09e5ba6764f54642494e26907662d55f">VTK_WIDGETS_EXPORT</a> <a class="code" href="a01559.html" title="provide the representation for a vtkSliderWidget with a 3D skin">vtkSliderRepresentation2D</a> : <span class="keyword">public</span> <a class="code" href="a01558.html" title="abstract class defines the representation for a vtkSliderWidget">vtkSliderRepresentation</a> <a name="l00055"></a>00055 { <a name="l00056"></a>00056 <span class="keyword">public</span>: <a name="l00058"></a>00058 <span class="keyword">static</span> <a class="code" href="a01559.html" title="provide the representation for a vtkSliderWidget with a 3D skin">vtkSliderRepresentation2D</a> *<a class="code" href="a01084.html#4d5b227267c076d6f9e38483370b6612">New</a>(); <a name="l00059"></a>00059 <a name="l00061"></a>00061 <a name="l00062"></a><a class="code" href="a01559.html#7e5f7e993dca15e4c2258b73f12f808e">00062</a> vtkTypeRevisionMacro(<a class="code" href="a01559.html" title="provide the representation for a vtkSliderWidget with a 3D skin">vtkSliderRepresentation2D</a>,<a class="code" href="a01558.html" title="abstract class defines the representation for a vtkSliderWidget">vtkSliderRepresentation</a>); <a name="l00063"></a>00063 <span class="keywordtype">void</span> <a class="code" href="a01558.html#1a1d0488070168d8ed5e36ac7b9ca197">PrintSelf</a>(ostream& os, <a class="code" href="a00869.html" title="a simple class to control print indentation">vtkIndent</a> indent); <a name="l00065"></a>00065 <a name="l00072"></a>00072 <a class="code" href="a00335.html" title="perform coordinate transformation, and represent position, in a variety of vtk coordinate...">vtkCoordinate</a> *GetPoint1Coordinate(); <a name="l00073"></a>00073 <a name="l00080"></a>00080 <a class="code" href="a00335.html" title="perform coordinate transformation, and represent position, in a variety of vtk coordinate...">vtkCoordinate</a> *GetPoint2Coordinate(); <a name="l00081"></a>00081 <a name="l00083"></a>00083 <a name="l00085"></a>00085 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="a01558.html#155f5e79f035ac85ab5a32de699a6a88">SetTitleText</a>(<span class="keyword">const</span> <span class="keywordtype">char</span>*); <a name="l00086"></a>00086 <span class="keyword">virtual</span> <span class="keyword">const</span> <span class="keywordtype">char</span>* <a class="code" href="a01558.html#751a638fa8f443d36d9b9b8b9882c9c6">GetTitleText</a>(); <a name="l00088"></a>00088 <a name="l00090"></a>00090 <a name="l00092"></a>00092 vtkGetObjectMacro(SliderProperty,<a class="code" href="a01323.html" title="represent surface properties of a 2D image">vtkProperty2D</a>); <a name="l00094"></a>00094 <a name="l00096"></a>00096 <a name="l00097"></a>00097 vtkGetObjectMacro(TubeProperty,<a class="code" href="a01323.html" title="represent surface properties of a 2D image">vtkProperty2D</a>); <a name="l00098"></a>00098 vtkGetObjectMacro(CapProperty,<a class="code" href="a01323.html" title="represent surface properties of a 2D image">vtkProperty2D</a>); <a name="l00100"></a>00100 <a name="l00102"></a>00102 <a name="l00104"></a>00104 vtkGetObjectMacro(SelectedProperty,<a class="code" href="a01323.html" title="represent surface properties of a 2D image">vtkProperty2D</a>); <a name="l00106"></a>00106 <a name="l00108"></a>00108 <a name="l00109"></a>00109 vtkGetObjectMacro(LabelProperty,<a class="code" href="a01692.html" title="represent text properties.">vtkTextProperty</a>); <a name="l00110"></a>00110 vtkGetObjectMacro(TitleProperty,<a class="code" href="a01692.html" title="represent text properties.">vtkTextProperty</a>); <a name="l00112"></a>00112 <a name="l00114"></a>00114 <a name="l00117"></a>00117 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="a01877.html#dbe69d604d5e458504229326abeecd3b">PlaceWidget</a>(<span class="keywordtype">double</span> bounds[6]); <a name="l00118"></a>00118 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="a01877.html#a7dfbf5a2b39487c072266e0e1520ec7">BuildRepresentation</a>(); <a name="l00119"></a>00119 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="a01877.html#9aece0d7ff74c1fcfd5f427088cab77b">StartWidgetInteraction</a>(<span class="keywordtype">double</span> eventPos[2]); <a name="l00120"></a>00120 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="a01877.html#73adbf84d1745e1393eda384a5f31d52">WidgetInteraction</a>(<span class="keywordtype">double</span> newEventPos[2]); <a name="l00121"></a>00121 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="a01877.html#4bccab4646d6c0f19d8888a3db9845ff">Highlight</a>(<span class="keywordtype">int</span>); <a name="l00123"></a>00123 <a name="l00125"></a>00125 <a name="l00126"></a>00126 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="a01877.html#deb781ee0b2e05240de3b1d099346714">GetActors2D</a>(<a class="code" href="a01321.html" title="a list of Props">vtkPropCollection</a>*); <a name="l00127"></a>00127 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="a01877.html#a5428644337fcf61013390e6d619ff9f">ReleaseGraphicsResources</a>(<a class="code" href="a01886.html" title="window superclass for vtkRenderWindow">vtkWindow</a>*); <a name="l00128"></a>00128 <span class="keyword">virtual</span> <span class="keywordtype">int</span> <a class="code" href="a01877.html#01e90cbe6f75838c27c1d1c0c5e37521">RenderOverlay</a>(<a class="code" href="a01833.html" title="abstract specification for Viewports">vtkViewport</a>*); <a name="l00129"></a>00129 <span class="keyword">virtual</span> <span class="keywordtype">int</span> <a class="code" href="a01877.html#5db136973bcd6232d212eeb1afcd0354">RenderOpaqueGeometry</a>(<a class="code" href="a01833.html" title="abstract specification for Viewports">vtkViewport</a>*); <a name="l00131"></a>00131 <a name="l00132"></a>00132 <span class="keyword">protected</span>: <a name="l00133"></a>00133 <a class="code" href="a01559.html" title="provide the representation for a vtkSliderWidget with a 3D skin">vtkSliderRepresentation2D</a>(); <a name="l00134"></a>00134 ~<a class="code" href="a01559.html" title="provide the representation for a vtkSliderWidget with a 3D skin">vtkSliderRepresentation2D</a>(); <a name="l00135"></a>00135 <a name="l00136"></a>00136 <span class="comment">// Positioning the widget</span> <a name="l00137"></a><a class="code" href="a01559.html#c8c933b465a024cc209f24c5c7e3d99f">00137</a> <a class="code" href="a00335.html" title="perform coordinate transformation, and represent position, in a variety of vtk coordinate...">vtkCoordinate</a> *Point1Coordinate; <a name="l00138"></a><a class="code" href="a01559.html#e202452d85e9be28d7df804fecdaf5e5">00138</a> <a class="code" href="a00335.html" title="perform coordinate transformation, and represent position, in a variety of vtk coordinate...">vtkCoordinate</a> *Point2Coordinate; <a name="l00139"></a>00139 <a name="l00140"></a>00140 <span class="comment">// Determine the parameter t along the slider</span> <a name="l00141"></a>00141 <span class="keyword">virtual</span> <span class="keywordtype">double</span> ComputePickPosition(<span class="keywordtype">double</span> eventPos[2]); <a name="l00142"></a>00142 <a name="l00143"></a>00143 <span class="comment">// Define the geometry. It is constructed in canaonical position</span> <a name="l00144"></a>00144 <span class="comment">// along the x-axis and then rotated into position.</span> <a name="l00145"></a><a class="code" href="a01559.html#c617646d374b13ab357c18ecde198dbd">00145</a> <a class="code" href="a01723.html" title="describes linear transformations via a 4x4 matrix">vtkTransform</a> *XForm; <a name="l00146"></a><a class="code" href="a01559.html#cf9318f2eb3571dae7e2d013a18895a8">00146</a> <a class="code" href="a01250.html" title="represent and manipulate 3D points">vtkPoints</a> *Points; <a name="l00147"></a>00147 <a name="l00148"></a><a class="code" href="a01559.html#ce7051fd9c3ba8c9821ecdb66a12b809">00148</a> <a class="code" href="a00242.html" title="object to represent cell connectivity">vtkCellArray</a> *SliderCells; <a name="l00149"></a><a class="code" href="a01559.html#7b677537644898484c4cb2a77faa5b27">00149</a> <a class="code" href="a01260.html" title="concrete dataset represents vertices, lines, polygons, and triangle strips">vtkPolyData</a> *Slider; <a name="l00150"></a><a class="code" href="a01559.html#51a3fa58aa46145e071073a1b8f7ca67">00150</a> <a class="code" href="a01731.html" title="transform points and associated normals and vectors for polygonal dataset">vtkTransformPolyDataFilter</a> *SliderXForm; <a name="l00151"></a><a class="code" href="a01559.html#1982a9f815dd03b0dff0f1e3a9fa1700">00151</a> <a class="code" href="a01266.html" title="draw vtkPolyData onto the image plane">vtkPolyDataMapper2D</a> *SliderMapper; <a name="l00152"></a><a class="code" href="a01559.html#1a6c46b6bb07f3361ecb2ae232a15ebf">00152</a> <a class="code" href="a00093.html" title="a actor that draws 2D data">vtkActor2D</a> *SliderActor; <a name="l00153"></a><a class="code" href="a01559.html#2d88ff6f122fbd0bd0732d093808fe0b">00153</a> <a class="code" href="a01323.html" title="represent surface properties of a 2D image">vtkProperty2D</a> *SliderProperty; <a name="l00154"></a>00154 <a name="l00155"></a><a class="code" href="a01559.html#ea0d1dcdf7c4104d73feab1146123f74">00155</a> <a class="code" href="a00242.html" title="object to represent cell connectivity">vtkCellArray</a> *TubeCells; <a name="l00156"></a><a class="code" href="a01559.html#6a6dddf9ef91a853b61b30aaa1050a48">00156</a> <a class="code" href="a01260.html" title="concrete dataset represents vertices, lines, polygons, and triangle strips">vtkPolyData</a> *Tube; <a name="l00157"></a><a class="code" href="a01559.html#51450a109ee866a6cd472de4cf68e35f">00157</a> <a class="code" href="a01731.html" title="transform points and associated normals and vectors for polygonal dataset">vtkTransformPolyDataFilter</a> *TubeXForm; <a name="l00158"></a><a class="code" href="a01559.html#1feaecf3d8274ad7fd15b5fe6466e9b0">00158</a> <a class="code" href="a01266.html" title="draw vtkPolyData onto the image plane">vtkPolyDataMapper2D</a> *TubeMapper; <a name="l00159"></a><a class="code" href="a01559.html#cfa40fdff03a3ee9bfc2e116dd72e257">00159</a> <a class="code" href="a00093.html" title="a actor that draws 2D data">vtkActor2D</a> *TubeActor; <a name="l00160"></a><a class="code" href="a01559.html#e37087b1690065d836eb8ef2b26dbb9a">00160</a> <a class="code" href="a01323.html" title="represent surface properties of a 2D image">vtkProperty2D</a> *TubeProperty; <a name="l00161"></a>00161 <a name="l00162"></a><a class="code" href="a01559.html#2d8b971a9986c72c830552fe760e0004">00162</a> <a class="code" href="a00242.html" title="object to represent cell connectivity">vtkCellArray</a> *CapCells; <a name="l00163"></a><a class="code" href="a01559.html#f07dd43f5c370455881267eafe79bc3d">00163</a> <a class="code" href="a01260.html" title="concrete dataset represents vertices, lines, polygons, and triangle strips">vtkPolyData</a> *Cap; <a name="l00164"></a><a class="code" href="a01559.html#6c669a4536888ceab910bff25221ae21">00164</a> <a class="code" href="a01731.html" title="transform points and associated normals and vectors for polygonal dataset">vtkTransformPolyDataFilter</a> *CapXForm; <a name="l00165"></a><a class="code" href="a01559.html#e422ee226fe5eebf0a04689ab13a865a">00165</a> <a class="code" href="a01266.html" title="draw vtkPolyData onto the image plane">vtkPolyDataMapper2D</a> *CapMapper; <a name="l00166"></a><a class="code" href="a01559.html#bf663e31d31710e60bd949b621597da6">00166</a> <a class="code" href="a00093.html" title="a actor that draws 2D data">vtkActor2D</a> *CapActor; <a name="l00167"></a><a class="code" href="a01559.html#c4f4ce5e9b81f7651759d7d82332a7b4">00167</a> <a class="code" href="a01323.html" title="represent surface properties of a 2D image">vtkProperty2D</a> *CapProperty; <a name="l00168"></a>00168 <a name="l00169"></a><a class="code" href="a01559.html#ffcd482c77f31ecaf695db8ab7483dd9">00169</a> <a class="code" href="a01692.html" title="represent text properties.">vtkTextProperty</a> *LabelProperty; <a name="l00170"></a><a class="code" href="a01559.html#7f189b8b81fa2e146dfbc5e84f973870">00170</a> <a class="code" href="a01691.html" title="2D text annotation">vtkTextMapper</a> *LabelMapper; <a name="l00171"></a><a class="code" href="a01559.html#15f0cc0f8d115f64205b3803ee713720">00171</a> <a class="code" href="a00093.html" title="a actor that draws 2D data">vtkActor2D</a> *LabelActor; <a name="l00172"></a>00172 <a name="l00173"></a><a class="code" href="a01559.html#67a11060c2e241a6cf21557ec341ab50">00173</a> <a class="code" href="a01692.html" title="represent text properties.">vtkTextProperty</a> *TitleProperty; <a name="l00174"></a><a class="code" href="a01559.html#74c00e00221eeb264d5ad5321bf5424e">00174</a> <a class="code" href="a01691.html" title="2D text annotation">vtkTextMapper</a> *TitleMapper; <a name="l00175"></a><a class="code" href="a01559.html#2f08825ef1ca650937d38ea01cba936e">00175</a> <a class="code" href="a00093.html" title="a actor that draws 2D data">vtkActor2D</a> *TitleActor; <a name="l00176"></a>00176 <a name="l00177"></a><a class="code" href="a01559.html#2d3983e73be38cd92a1a6c13f3cf2a33">00177</a> <a class="code" href="a01323.html" title="represent surface properties of a 2D image">vtkProperty2D</a> *SelectedProperty; <a name="l00178"></a>00178 <a name="l00179"></a>00179 <span class="comment">// internal variables used for computation</span> <a name="l00180"></a><a class="code" href="a01559.html#6685de22257d13653f0ac66bb437ca68">00180</a> <span class="keywordtype">double</span> X; <a name="l00181"></a>00181 <a name="l00182"></a>00182 <span class="keyword">private</span>: <a name="l00183"></a>00183 <a class="code" href="a01559.html" title="provide the representation for a vtkSliderWidget with a 3D skin">vtkSliderRepresentation2D</a>(<span class="keyword">const</span> <a class="code" href="a01559.html" title="provide the representation for a vtkSliderWidget with a 3D skin">vtkSliderRepresentation2D</a>&); <span class="comment">//Not implemented</span> <a name="l00184"></a>00184 <span class="keywordtype">void</span> operator=(<span class="keyword">const</span> <a class="code" href="a01559.html" title="provide the representation for a vtkSliderWidget with a 3D skin">vtkSliderRepresentation2D</a>&); <span class="comment">//Not implemented</span> <a name="l00185"></a>00185 }; <a name="l00186"></a>00186 <a name="l00187"></a>00187 <span class="preprocessor">#endif</span> </pre></div></div> <hr size="1"><address style="text-align: right;"><small>Generated on Wed Jun 3 18:35:54 2009 for VTK by <a href="http://www.doxygen.org/index.html"> <img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.6 </small></address> </body> </html>