<!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/Rendering/vtkImageViewer.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/Rendering/vtkImageViewer.h</h1><a href="a03418.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: vtkImageViewer.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 __vtkImageViewer_h</span> <a name="l00032"></a>00032 <span class="preprocessor"></span><span class="preprocessor">#define __vtkImageViewer_h</span> <a name="l00033"></a>00033 <span class="preprocessor"></span> <a name="l00034"></a>00034 <span class="preprocessor">#include "<a class="code" href="a02079.html">vtkObject.h</a>"</span> <a name="l00035"></a>00035 <a name="l00036"></a>00036 <span class="preprocessor">#include "<a class="code" href="a03417.html">vtkImageMapper.h</a>"</span> <span class="comment">// For all the inline methods</span> <a name="l00037"></a>00037 <span class="preprocessor">#include "<a class="code" href="a03537.html">vtkRenderWindow.h</a>"</span> <span class="comment">// For all the inline methods</span> <a name="l00038"></a>00038 <a name="l00039"></a>00039 <span class="keyword">class </span><a class="code" href="a00906.html" title="interactive manipulation of the camera specialized for images">vtkInteractorStyleImage</a>; <a name="l00040"></a>00040 <a name="l00041"></a><a class="code" href="a00847.html">00041</a> <span class="keyword">class </span><a class="code" href="a02170.html#4019f67b2e7d601f2cf984e448308dbb">VTK_RENDERING_EXPORT</a> <a class="code" href="a00847.html" title="Display a 2d image.">vtkImageViewer</a> : <span class="keyword">public</span> <a class="code" href="a01084.html" title="abstract base class for most VTK objects">vtkObject</a> <a name="l00042"></a>00042 { <a name="l00043"></a>00043 <span class="keyword">public</span>: <a name="l00044"></a>00044 <span class="keyword">static</span> <a class="code" href="a00847.html" title="Display a 2d image.">vtkImageViewer</a> *<a class="code" href="a01084.html#4d5b227267c076d6f9e38483370b6612">New</a>(); <a name="l00045"></a>00045 <a name="l00046"></a><a class="code" href="a00847.html#a1ea0c2d136a1535fd1be41c7279c46b">00046</a> vtkTypeRevisionMacro(<a class="code" href="a00847.html" title="Display a 2d image.">vtkImageViewer</a>,<a class="code" href="a01084.html" title="abstract base class for most VTK objects">vtkObject</a>); <a name="l00047"></a>00047 <span class="keywordtype">void</span> <a class="code" href="a01084.html#bf3dbb4154289b56a12483eee3866263">PrintSelf</a>(ostream& os, <a class="code" href="a00869.html" title="a simple class to control print indentation">vtkIndent</a> indent); <a name="l00048"></a>00048 <a name="l00050"></a><a class="code" href="a00847.html#e66286f9938e7365bb038f8b6310e973">00050</a> <span class="keywordtype">char</span> *GetWindowName() {<span class="keywordflow">return</span> this->RenderWindow->GetWindowName();}; <a name="l00051"></a>00051 <a name="l00053"></a>00053 <span class="keyword">virtual</span> <span class="keywordtype">void</span> Render(<span class="keywordtype">void</span>); <a name="l00054"></a>00054 <a name="l00056"></a>00056 <a name="l00057"></a><a class="code" href="a00847.html#97970a4b27c8799eb22e9fb880184920">00057</a> <span class="keywordtype">void</span> SetInput(<a class="code" href="a00751.html" title="topologically and geometrically regular array of data">vtkImageData</a> *in) {this->ImageMapper->SetInput(in);}; <a name="l00058"></a><a class="code" href="a00847.html#108e3480f8382364af5c8d70a823bddd">00058</a> <a class="code" href="a00751.html" title="topologically and geometrically regular array of data">vtkImageData</a> *GetInput() { <span class="keywordflow">return</span> this->ImageMapper->GetInput();}; <a name="l00059"></a><a class="code" href="a00847.html#0133023adc303b0b104fa824a53b9395">00059</a> <span class="keyword">virtual</span> <span class="keywordtype">void</span> SetInputConnection(<a class="code" href="a00102.html" title="Proxy object to connect input/output ports.">vtkAlgorithmOutput</a>* input) { <a name="l00060"></a>00060 this->ImageMapper->SetInputConnection(input);}; <a name="l00062"></a>00062 <a name="l00064"></a>00064 <a name="l00065"></a><a class="code" href="a00847.html#b18b775621582818097e988bbba3037a">00065</a> <span class="keywordtype">int</span> GetWholeZMin() {<span class="keywordflow">return</span> this->ImageMapper->GetWholeZMin();}; <a name="l00066"></a><a class="code" href="a00847.html#c3f6fe7e9eb027f7d9d1c24146a78675">00066</a> <span class="keywordtype">int</span> GetWholeZMax() {<span class="keywordflow">return</span> this->ImageMapper->GetWholeZMax();}; <a name="l00068"></a>00068 <a name="l00070"></a>00070 <a name="l00071"></a><a class="code" href="a00847.html#a5544056221b3f8152fc383755576741">00071</a> <span class="keywordtype">int</span> GetZSlice() {<span class="keywordflow">return</span> this->ImageMapper->GetZSlice();}; <a name="l00072"></a><a class="code" href="a00847.html#0bf997fbc65469d6d4e0a9cfb676f024">00072</a> <span class="keywordtype">void</span> SetZSlice(<span class="keywordtype">int</span> s) {this->ImageMapper->SetZSlice(s);}; <a name="l00074"></a>00074 <a name="l00076"></a>00076 <a name="l00077"></a><a class="code" href="a00847.html#8f87fc789dd0e56316e717c379916f00">00077</a> <span class="keywordtype">double</span> GetColorWindow() {<span class="keywordflow">return</span> this->ImageMapper->GetColorWindow();}; <a name="l00078"></a><a class="code" href="a00847.html#3c80910cd67fcb84772f617038274ff5">00078</a> <span class="keywordtype">double</span> GetColorLevel() {<span class="keywordflow">return</span> this->ImageMapper->GetColorLevel();}; <a name="l00079"></a><a class="code" href="a00847.html#74d8d61c8da05866078529e7ce2d8566">00079</a> <span class="keywordtype">void</span> SetColorWindow(<span class="keywordtype">double</span> s) {this->ImageMapper->SetColorWindow(s);}; <a name="l00080"></a><a class="code" href="a00847.html#00e5bfd177c7e1c6b3c7bedfecffc64e">00080</a> <span class="keywordtype">void</span> SetColorLevel(<span class="keywordtype">double</span> s) {this->ImageMapper->SetColorLevel(s);}; <a name="l00082"></a>00082 <a name="l00084"></a>00084 <a name="l00085"></a><a class="code" href="a00847.html#85bc83b7b91ae3fe3f415685853a0b1e">00085</a> <span class="keywordtype">void</span> SetDisplayId(<span class="keywordtype">void</span> *a) {this->RenderWindow->SetDisplayId(a);}; <a name="l00086"></a><a class="code" href="a00847.html#7ed1eeb7138b82b9b8dbd70210777ff7">00086</a> <span class="keywordtype">void</span> SetWindowId(<span class="keywordtype">void</span> *a) {this->RenderWindow->SetWindowId(a);}; <a name="l00087"></a><a class="code" href="a00847.html#77ecaefedae109c74d26d02f31c77466">00087</a> <span class="keywordtype">void</span> SetParentId(<span class="keywordtype">void</span> *a) {this->RenderWindow->SetParentId(a);}; <a name="l00089"></a>00089 <a name="l00091"></a>00091 <a name="l00093"></a>00093 VTK_LEGACY(<span class="keywordtype">int</span> GetGrayScaleHint()); <a name="l00094"></a>00094 VTK_LEGACY(<span class="keywordtype">void</span> SetGrayScaleHint(<span class="keywordtype">int</span> vtkNotUsed(a))); <a name="l00095"></a>00095 VTK_LEGACY(<span class="keywordtype">void</span> GrayScaleHintOn()); <a name="l00096"></a>00096 VTK_LEGACY(<span class="keywordtype">void</span> GrayScaleHintOff()); <a name="l00098"></a>00098 <a name="l00100"></a>00100 <a name="l00101"></a><a class="code" href="a00847.html#28c7e5d1c82c924150b6d9f05d292bea">00101</a> <span class="keywordtype">int</span> *GetPosition() {<span class="keywordflow">return</span> this->RenderWindow->GetPosition();}; <a name="l00102"></a><a class="code" href="a00847.html#0ca62ab6708cbdbd7138d8bb7eb83134">00102</a> <span class="keywordtype">void</span> SetPosition(<span class="keywordtype">int</span> a,<span class="keywordtype">int</span> b) {this->RenderWindow->SetPosition(a,b);}; <a name="l00103"></a>00103 <span class="keyword">virtual</span> <span class="keywordtype">void</span> SetPosition(<span class="keywordtype">int</span> a[2]); <a name="l00105"></a>00105 <a name="l00107"></a>00107 <a name="l00108"></a><a class="code" href="a00847.html#27462b4582f43dbf1f900a9899b93d43">00108</a> <span class="keywordtype">int</span> *GetSize() {<span class="keywordflow">return</span> this->RenderWindow->GetSize();}; <a name="l00109"></a><a class="code" href="a00847.html#21c564ed8a80cc9eddb4e735953e46ec">00109</a> <span class="keywordtype">void</span> SetSize(<span class="keywordtype">int</span> a,<span class="keywordtype">int</span> b) {this->RenderWindow->SetSize(a,b);}; <a name="l00110"></a>00110 <span class="keyword">virtual</span> <span class="keywordtype">void</span> SetSize(<span class="keywordtype">int</span> a[2]); <a name="l00112"></a>00112 <a name="l00114"></a>00114 <a name="l00115"></a>00115 vtkGetObjectMacro(RenderWindow,<a class="code" href="a01489.html" title="create a window for renderers to draw into">vtkRenderWindow</a>); <a name="l00116"></a>00116 vtkGetObjectMacro(Renderer, <a class="code" href="a01480.html" title="abstract specification for renderers">vtkRenderer</a>); <a name="l00117"></a>00117 vtkGetObjectMacro(ImageMapper,<a class="code" href="a00791.html" title="2D image display">vtkImageMapper</a>); <a name="l00118"></a>00118 vtkGetObjectMacro(Actor2D,<a class="code" href="a00093.html" title="a actor that draws 2D data">vtkActor2D</a>); <a name="l00120"></a>00120 <a name="l00122"></a>00122 <span class="keywordtype">void</span> SetupInteractor(<a class="code" href="a01491.html" title="platform-independent render window interaction including picking and frame rate control...">vtkRenderWindowInteractor</a> *); <a name="l00123"></a>00123 <a name="l00125"></a>00125 <a name="l00128"></a>00128 <span class="keywordtype">void</span> SetOffScreenRendering(<span class="keywordtype">int</span>); <a name="l00129"></a>00129 <span class="keywordtype">int</span> GetOffScreenRendering(); <a name="l00130"></a>00130 <span class="keywordtype">void</span> OffScreenRenderingOn(); <a name="l00131"></a>00131 <span class="keywordtype">void</span> OffScreenRenderingOff(); <a name="l00133"></a>00133 <a name="l00134"></a>00134 <span class="keyword">protected</span>: <a name="l00135"></a>00135 <a class="code" href="a00847.html" title="Display a 2d image.">vtkImageViewer</a>(); <a name="l00136"></a>00136 ~<a class="code" href="a00847.html" title="Display a 2d image.">vtkImageViewer</a>(); <a name="l00137"></a>00137 <a name="l00138"></a><a class="code" href="a00847.html#e1f090d86ef9ea7a003676f838e2ad2a">00138</a> <a class="code" href="a01489.html" title="create a window for renderers to draw into">vtkRenderWindow</a> *RenderWindow; <a name="l00139"></a><a class="code" href="a00847.html#a136ca62509bb8519c009f4c3e72a6c0">00139</a> <a class="code" href="a01480.html" title="abstract specification for renderers">vtkRenderer</a> *Renderer; <a name="l00140"></a><a class="code" href="a00847.html#0ed2334ae48dcdb371153810b459f916">00140</a> <a class="code" href="a00791.html" title="2D image display">vtkImageMapper</a> *ImageMapper; <a name="l00141"></a><a class="code" href="a00847.html#b7bb461e456807365a24385980cef2b1">00141</a> <a class="code" href="a00093.html" title="a actor that draws 2D data">vtkActor2D</a> *Actor2D; <a name="l00142"></a><a class="code" href="a00847.html#e74fa070ea090c9a713d3abb2d7a3de9">00142</a> <span class="keywordtype">int</span> FirstRender; <a name="l00143"></a><a class="code" href="a00847.html#ca993f5a0754cecb225dcf0062a666af">00143</a> <a class="code" href="a01491.html" title="platform-independent render window interaction including picking and frame rate control...">vtkRenderWindowInteractor</a> *Interactor; <a name="l00144"></a><a class="code" href="a00847.html#22368d3a2cae5bd4b31861436cea22f3">00144</a> <a class="code" href="a00906.html" title="interactive manipulation of the camera specialized for images">vtkInteractorStyleImage</a> *InteractorStyle; <a name="l00145"></a>00145 <a name="l00146"></a>00146 <span class="keyword">private</span>: <a name="l00147"></a>00147 <a class="code" href="a00847.html" title="Display a 2d image.">vtkImageViewer</a>(<span class="keyword">const</span> <a class="code" href="a00847.html" title="Display a 2d image.">vtkImageViewer</a>&); <span class="comment">// Not implemented.</span> <a name="l00148"></a>00148 <span class="keywordtype">void</span> operator=(<span class="keyword">const</span> <a class="code" href="a00847.html" title="Display a 2d image.">vtkImageViewer</a>&); <span class="comment">// Not implemented.</span> <a name="l00149"></a>00149 }; <a name="l00150"></a>00150 <a name="l00151"></a>00151 <span class="preprocessor">#endif</span> <a name="l00152"></a>00152 <span class="preprocessor"></span> <a name="l00153"></a>00153 </pre></div></div> <hr size="1"><address style="text-align: right;"><small>Generated on Wed Jun 3 18:35:46 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>