VTK
dox/Filtering/vtkSelectionNode.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   ParaView
00004   Module:    vtkSelectionNode.h
00005 
00006   Copyright (c) Kitware, Inc.
00007   All rights reserved.
00008   See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00051 #ifndef __vtkSelectionNode_h
00052 #define __vtkSelectionNode_h
00053 
00054 #include "vtkObject.h"
00055 
00056 //BTX
00057 class vtkAbstractArray;
00058 class vtkDataSetAttributes;
00059 class vtkInformation;
00060 class vtkInformationDoubleKey;
00061 class vtkInformationIntegerKey;
00062 class vtkInformationObjectBaseKey;
00063 class vtkProp;
00064 class vtkTable;
00065 //ETX
00066 
00067 class VTK_FILTERING_EXPORT vtkSelectionNode : public vtkObject
00068 {
00069 public:
00070   vtkTypeMacro(vtkSelectionNode,vtkObject);
00071   void PrintSelf(ostream& os, vtkIndent indent);
00072   static vtkSelectionNode* New();
00073 
00075   virtual void Initialize();
00076   
00078 
00079   virtual void SetSelectionList(vtkAbstractArray*);
00080   virtual vtkAbstractArray* GetSelectionList();
00082 
00084 
00085   virtual void SetSelectionData(vtkDataSetAttributes* data);
00086   vtkGetObjectMacro(SelectionData, vtkDataSetAttributes);
00088   
00090 
00091   vtkGetObjectMacro(Properties, vtkInformation);
00093 
00095   virtual void DeepCopy(vtkSelectionNode* src);
00096 
00100   virtual void ShallowCopy(vtkSelectionNode* src);
00101 
00103   unsigned long GetMTime();
00104 
00105   // vtkSelectionNode specific keys follow:
00107 
00120   static vtkInformationIntegerKey* CONTENT_TYPE();
00121 //BTX
00122   enum SelectionContent
00123   {
00124     SELECTIONS,  // Deprecated.
00125     GLOBALIDS,
00126     PEDIGREEIDS,
00127     VALUES,
00128     INDICES,
00129     FRUSTUM,
00130     LOCATIONS,
00131     THRESHOLDS,
00132     BLOCKS       // used to select blocks within a composite dataset.
00133   };
00134 //ETX
00136   
00138 
00140   virtual void SetContentType(int type);
00141   virtual int GetContentType();
00143 
00145 
00149   static vtkInformationIntegerKey* FIELD_TYPE();
00150 //BTX
00151   enum SelectionField
00152   {
00153     CELL,
00154     POINT,
00155     FIELD,
00156     VERTEX,
00157     EDGE,
00158     ROW
00159   };
00160 //ETX
00162   
00164 
00166   virtual void SetFieldType(int type);
00167   virtual int GetFieldType();
00169 
00171 
00173   virtual void SetSelectedProp(vtkProp* prop);
00174   virtual vtkProp* GetSelectedProp();
00176   
00179   static vtkInformationDoubleKey* EPSILON();
00180 
00184   static vtkInformationIntegerKey* CONTAINING_CELLS();
00185 
00190   static vtkInformationIntegerKey* COMPONENT_NUMBER();
00191 
00193   static vtkInformationIntegerKey* INVERSE();
00194 
00197   static vtkInformationIntegerKey* PIXEL_COUNT();
00198 
00200   static vtkInformationObjectBaseKey* SOURCE();
00201 
00204   static vtkInformationIntegerKey* SOURCE_ID();
00205 
00207   static vtkInformationObjectBaseKey* PROP();
00208 
00211   static vtkInformationIntegerKey* PROP_ID();
00212 
00214   static vtkInformationIntegerKey* PROCESS_ID();
00215 
00217   static vtkInformationIntegerKey* COMPOSITE_INDEX();
00218 
00220 
00221   static vtkInformationIntegerKey* HIERARCHICAL_LEVEL();
00222   static vtkInformationIntegerKey* HIERARCHICAL_INDEX();
00224 
00228   static vtkInformationIntegerKey* INDEXED_VERTICES();
00229 
00232   void UnionSelectionList(vtkSelectionNode* other);
00233 
00236   bool EqualProperties(vtkSelectionNode* other, bool fullcompare=true);
00237 
00238 //BTX
00239 protected:
00240   vtkSelectionNode();
00241   ~vtkSelectionNode();
00242 
00243   vtkInformation* Properties;
00244   vtkDataSetAttributes* SelectionData;
00245 
00246 private:
00247   vtkSelectionNode(const vtkSelectionNode&);  // Not implemented.
00248   void operator=(const vtkSelectionNode&);  // Not implemented.
00249 //ETX
00250 };
00251 
00252 #endif