<!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/Graphics/vtkExtractSelectedFrustum.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/Graphics/vtkExtractSelectedFrustum.h</h1><a href="a02534.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: vtkExtractSelectedFrustum.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="l00038"></a>00038 <span class="preprocessor">#ifndef __vtkExtractSelectedFrustum_h</span> <a name="l00039"></a>00039 <span class="preprocessor"></span><span class="preprocessor">#define __vtkExtractSelectedFrustum_h</span> <a name="l00040"></a>00040 <span class="preprocessor"></span> <a name="l00041"></a>00041 <span class="preprocessor">#include "<a class="code" href="a02540.html">vtkExtractSelectionBase.h</a>"</span> <a name="l00042"></a>00042 <a name="l00043"></a>00043 <span class="keyword">class </span><a class="code" href="a01226.html" title="implicit function for convex set of planes">vtkPlanes</a>; <a name="l00044"></a>00044 <span class="keyword">class </span><a class="code" href="a00872.html" title="Store vtkAlgorithm input/output information.">vtkInformation</a>; <a name="l00045"></a>00045 <span class="keyword">class </span><a class="code" href="a00895.html" title="Store zero or more vtkInformation instances.">vtkInformationVector</a>; <a name="l00046"></a>00046 <span class="keyword">class </span><a class="code" href="a00240.html" title="abstract class to specify cell behavior">vtkCell</a>; <a name="l00047"></a>00047 <span class="keyword">class </span><a class="code" href="a01250.html" title="represent and manipulate 3D points">vtkPoints</a>; <a name="l00048"></a>00048 <span class="keyword">class </span><a class="code" href="a00436.html" title="dynamic, self-adjusting array of double">vtkDoubleArray</a>; <a name="l00049"></a>00049 <a name="l00050"></a><a class="code" href="a00513.html">00050</a> <span class="keyword">class </span><a class="code" href="a02170.html#c3c1ffe2fe47b9b70ba90182b7860cce">VTK_GRAPHICS_EXPORT</a> <a class="code" href="a00513.html" title="Returns the portion of the input dataset that lies within a selection frustum.">vtkExtractSelectedFrustum</a> : <span class="keyword">public</span> <a class="code" href="a00520.html" title="abstract base class for all extract selection filters.">vtkExtractSelectionBase</a> <a name="l00051"></a>00051 { <a name="l00052"></a>00052 <span class="keyword">public</span>: <a name="l00053"></a>00053 <span class="keyword">static</span> <a class="code" href="a00513.html" title="Returns the portion of the input dataset that lies within a selection frustum.">vtkExtractSelectedFrustum</a> *<a class="code" href="a00363.html#a80436810042ef236258b927f0390bb3">New</a>(); <a name="l00054"></a><a class="code" href="a00513.html#6aa8e16f14b682f6047676766e978cce">00054</a> vtkTypeRevisionMacro(<a class="code" href="a00513.html" title="Returns the portion of the input dataset that lies within a selection frustum.">vtkExtractSelectedFrustum</a>, <a class="code" href="a00520.html" title="abstract base class for all extract selection filters.">vtkExtractSelectionBase</a>); <a name="l00055"></a>00055 <span class="keywordtype">void</span> <a class="code" href="a00520.html#26765baa7a977b672f3a48429046230c">PrintSelf</a>(ostream& os, <a class="code" href="a00869.html" title="a simple class to control print indentation">vtkIndent</a> indent); <a name="l00056"></a>00056 <a name="l00058"></a>00058 <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> <a class="code" href="a01084.html#8137c0551b29bb996f0dd2f886bcd2da">GetMTime</a>(); <a name="l00059"></a>00059 <a name="l00061"></a>00061 <a name="l00062"></a>00062 <span class="keyword">virtual</span> <span class="keywordtype">void</span> SetFrustum(<a class="code" href="a01226.html" title="implicit function for convex set of planes">vtkPlanes</a>*); <a name="l00063"></a>00063 vtkGetObjectMacro(Frustum,<a class="code" href="a01226.html" title="implicit function for convex set of planes">vtkPlanes</a>); <a name="l00065"></a>00065 <a name="l00070"></a>00070 <span class="keywordtype">void</span> CreateFrustum(<span class="keywordtype">double</span> <a class="code" href="a02995.html#f72f6dd7eacdaa16475e07e0331750a2">vertices</a>[32]); <a name="l00071"></a>00071 <a name="l00073"></a>00073 <a name="l00075"></a>00075 vtkGetObjectMacro(ClipPoints, <a class="code" href="a01250.html" title="represent and manipulate 3D points">vtkPoints</a>); <a name="l00077"></a>00077 <a name="l00079"></a>00079 <a name="l00080"></a>00080 vtkSetMacro(FieldType,<span class="keywordtype">int</span>); <a name="l00081"></a>00081 vtkGetMacro(FieldType,<span class="keywordtype">int</span>); <a name="l00083"></a>00083 <a name="l00085"></a>00085 <a name="l00087"></a>00087 vtkSetMacro(ContainingCells,<span class="keywordtype">int</span>); <a name="l00088"></a>00088 vtkGetMacro(ContainingCells,<span class="keywordtype">int</span>); <a name="l00090"></a>00090 <a name="l00092"></a>00092 <span class="keywordtype">int</span> OverallBoundsTest(<span class="keywordtype">double</span> *bounds); <a name="l00093"></a>00093 <a name="l00095"></a>00095 <a name="l00097"></a>00097 vtkSetMacro(ShowBounds,<span class="keywordtype">int</span>); <a name="l00098"></a>00098 vtkGetMacro(ShowBounds,<span class="keywordtype">int</span>); <a name="l00099"></a>00099 vtkBooleanMacro(ShowBounds,<span class="keywordtype">int</span>); <a name="l00101"></a>00101 <a name="l00103"></a>00103 <a name="l00104"></a>00104 vtkSetMacro(InsideOut,<span class="keywordtype">int</span>); <a name="l00105"></a>00105 vtkGetMacro(InsideOut,<span class="keywordtype">int</span>); <a name="l00106"></a>00106 vtkBooleanMacro(InsideOut,<span class="keywordtype">int</span>); <a name="l00108"></a>00108 <a name="l00109"></a>00109 <span class="keyword">protected</span>: <a name="l00110"></a>00110 <a class="code" href="a00513.html" title="Returns the portion of the input dataset that lies within a selection frustum.">vtkExtractSelectedFrustum</a>(<a class="code" href="a01226.html" title="implicit function for convex set of planes">vtkPlanes</a> *f=NULL); <a name="l00111"></a>00111 ~<a class="code" href="a00513.html" title="Returns the portion of the input dataset that lies within a selection frustum.">vtkExtractSelectedFrustum</a>(); <a name="l00112"></a>00112 <a name="l00113"></a>00113 <span class="comment">// sets up output dataset</span> <a name="l00114"></a>00114 <span class="keyword">virtual</span> <span class="keywordtype">int</span> <a class="code" href="a00520.html#20000e8330fa02313b3ed3c5180f769e">RequestDataObject</a>(<a class="code" href="a00872.html" title="Store vtkAlgorithm input/output information.">vtkInformation</a>* request, <a name="l00115"></a>00115 <a class="code" href="a00895.html" title="Store zero or more vtkInformation instances.">vtkInformationVector</a>** inputVector, <a name="l00116"></a>00116 <a class="code" href="a00895.html" title="Store zero or more vtkInformation instances.">vtkInformationVector</a>* outputVector); <a name="l00117"></a>00117 <a name="l00118"></a>00118 <span class="comment">//execution</span> <a name="l00119"></a>00119 <span class="keyword">virtual</span> <span class="keywordtype">int</span> <a class="code" href="a00363.html#81c15bbf415932f0eb87723639c46901">RequestData</a>(<a class="code" href="a00872.html" title="Store vtkAlgorithm input/output information.">vtkInformation</a> *, <a name="l00120"></a>00120 <a class="code" href="a00895.html" title="Store zero or more vtkInformation instances.">vtkInformationVector</a> **, <a class="code" href="a00895.html" title="Store zero or more vtkInformation instances.">vtkInformationVector</a> *); <a name="l00121"></a>00121 <span class="keywordtype">int</span> ABoxFrustumIsect(<span class="keywordtype">double</span> bounds[], <a class="code" href="a00240.html" title="abstract class to specify cell behavior">vtkCell</a> *cell); <a name="l00122"></a>00122 <span class="keywordtype">int</span> FrustumClipPolygon(<span class="keywordtype">int</span> nverts, <a name="l00123"></a>00123 <span class="keywordtype">double</span> *ivlist, <span class="keywordtype">double</span> *wvlist, <span class="keywordtype">double</span> *ovlist); <a name="l00124"></a>00124 <span class="keywordtype">void</span> PlaneClipPolygon(<span class="keywordtype">int</span> nverts, <span class="keywordtype">double</span> *ivlist, <a name="l00125"></a>00125 <span class="keywordtype">int</span> pid, <span class="keywordtype">int</span> &noverts, <span class="keywordtype">double</span> *ovlist); <a name="l00126"></a>00126 <span class="keywordtype">void</span> PlaneClipEdge(<span class="keywordtype">double</span> *V0, <span class="keywordtype">double</span> *V1, <a name="l00127"></a>00127 <span class="keywordtype">int</span> pid, <span class="keywordtype">int</span> &noverts, <span class="keywordtype">double</span> *overts); <a name="l00128"></a>00128 <span class="keywordtype">int</span> IsectDegenerateCell(<a class="code" href="a00240.html" title="abstract class to specify cell behavior">vtkCell</a> *cell); <a name="l00129"></a>00129 <a name="l00130"></a>00130 <a name="l00131"></a>00131 <span class="comment">//used in CreateFrustum</span> <a name="l00132"></a>00132 <span class="keywordtype">void</span> ComputePlane(<span class="keywordtype">int</span> idx, <a name="l00133"></a>00133 <span class="keywordtype">double</span> v0[3], <span class="keywordtype">double</span> v1[2], <span class="keywordtype">double</span> v2[3], <a name="l00134"></a>00134 <a class="code" href="a01250.html" title="represent and manipulate 3D points">vtkPoints</a> *<a class="code" href="a03761.html#c6551f7bf833e8254b2b3ecdaea0d2100fd9718c29b22570d5b02fa5c8de94f7">points</a>, <a class="code" href="a00436.html" title="dynamic, self-adjusting array of double">vtkDoubleArray</a> *norms); <a name="l00135"></a>00135 <a name="l00136"></a>00136 <span class="comment">//modes</span> <a name="l00137"></a><a class="code" href="a00513.html#2d308c4dca9ca4004b1b81063af979c2">00137</a> <span class="keywordtype">int</span> FieldType; <a name="l00138"></a><a class="code" href="a00513.html#198ee408f91329bc0d4e3d985d3d1e8d">00138</a> <span class="keywordtype">int</span> ContainingCells; <a name="l00139"></a><a class="code" href="a00513.html#82e2dc1b20052523526daf61074dbd5b">00139</a> <span class="keywordtype">int</span> InsideOut; <a name="l00140"></a>00140 <a name="l00141"></a>00141 <span class="comment">//used internally</span> <a name="l00142"></a><a class="code" href="a00513.html#26eb174f95d3cef0b69e7e6aa429259b">00142</a> <a class="code" href="a01226.html" title="implicit function for convex set of planes">vtkPlanes</a> *Frustum; <a name="l00143"></a><a class="code" href="a00513.html#ff0e840b6ea8e564c4d72e9ad7c1099a">00143</a> <span class="keywordtype">int</span> np_vertids[6][2]; <a name="l00144"></a>00144 <a name="l00145"></a>00145 <span class="comment">//for debugging</span> <a name="l00146"></a><a class="code" href="a00513.html#9e4ddcf1a9939f4610f412776c04178d">00146</a> <a class="code" href="a01250.html" title="represent and manipulate 3D points">vtkPoints</a> *ClipPoints; <a name="l00147"></a><a class="code" href="a00513.html#80eec101ae0e0a10ac0b9f5708d8d4e7">00147</a> <span class="keywordtype">int</span> NumRejects; <a name="l00148"></a><a class="code" href="a00513.html#858848a53df9c599e4db00c08c32d850">00148</a> <span class="keywordtype">int</span> NumIsects; <a name="l00149"></a><a class="code" href="a00513.html#4d247e1059793a2c0b4496ba1f469756">00149</a> <span class="keywordtype">int</span> NumAccepts; <a name="l00150"></a><a class="code" href="a00513.html#da1b924a85850af3bd9371b21fda74fe">00150</a> <span class="keywordtype">int</span> ShowBounds; <a name="l00151"></a>00151 <a name="l00152"></a>00152 <span class="keyword">private</span>: <a name="l00153"></a>00153 <a class="code" href="a00513.html" title="Returns the portion of the input dataset that lies within a selection frustum.">vtkExtractSelectedFrustum</a>(<span class="keyword">const</span> <a class="code" href="a00513.html" title="Returns the portion of the input dataset that lies within a selection frustum.">vtkExtractSelectedFrustum</a>&); <span class="comment">// Not implemented.</span> <a name="l00154"></a>00154 <span class="keywordtype">void</span> operator=(<span class="keyword">const</span> <a class="code" href="a00513.html" title="Returns the portion of the input dataset that lies within a selection frustum.">vtkExtractSelectedFrustum</a>&); <span class="comment">// Not implemented.</span> <a name="l00155"></a>00155 <a name="l00156"></a>00156 }; <a name="l00157"></a>00157 <a name="l00158"></a>00158 <span class="preprocessor">#endif</span> <a name="l00159"></a>00159 <span class="preprocessor"></span> <a name="l00160"></a>00160 </pre></div></div> <hr size="1"><address style="text-align: right;"><small>Generated on Wed Jun 3 18:35:26 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>