Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

dox/Common/vtkInterpolatedVelocityField.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkInterpolatedVelocityField.h,v $
00005   Language:  C++
00006 
00007   Copyright (c) 1993-2002 Ken Martin, Will Schroeder, Bill Lorensen 
00008   All rights reserved.
00009   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00010 
00011      This software is distributed WITHOUT ANY WARRANTY; without even 
00012      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00013      PURPOSE.  See the above copyright notice for more information.
00014 
00015 =========================================================================*/
00044 #ifndef __vtkInterpolatedVelocityField_h
00045 #define __vtkInterpolatedVelocityField_h
00046 
00047 #include "vtkFunctionSet.h"
00048 
00049 class vtkDataSet;
00050 class vtkGenericCell;
00051 
00052 class vtkInterpolatedVelocityFieldDataSetsType;
00053 
00054 class VTK_COMMON_EXPORT vtkInterpolatedVelocityField : public vtkFunctionSet
00055 {
00056 public:
00057   vtkTypeRevisionMacro(vtkInterpolatedVelocityField,vtkFunctionSet);
00058   virtual void PrintSelf(ostream& os, vtkIndent indent);
00059 
00062   static vtkInterpolatedVelocityField *New();
00063 
00066   virtual int FunctionValues(float* x, float* f);
00067 
00072   virtual void AddDataSet(vtkDataSet* dataset);
00073 
00075 
00076   vtkGetMacro(LastCellId, vtkIdType);
00077   vtkSetMacro(LastCellId, vtkIdType);
00079 
00082   void ClearLastCellId() { this->LastCellId = -1; }
00083 
00085 
00088   int GetLastWeights(float* w);
00089   int GetLastLocalCoordinates(float pcoords[3]);
00091 
00093 
00094   vtkGetMacro(Caching, int);
00095   vtkSetMacro(Caching, int);
00096   vtkBooleanMacro(Caching, int);
00098 
00100 
00101   vtkGetMacro(CacheHit, int);
00102   vtkGetMacro(CacheMiss, int);
00104 
00106 
00109   vtkGetStringMacro(VectorsSelection);
00110   void SelectVectors(const char *fieldName) 
00111     {this->SetVectorsSelection(fieldName);}
00113   
00115   vtkGetObjectMacro(LastDataSet, vtkDataSet);
00117 
00118 protected:
00119   vtkInterpolatedVelocityField();
00120   ~vtkInterpolatedVelocityField();
00121 
00122   vtkGenericCell* GenCell; // last cell
00123   vtkGenericCell* Cell;
00124   float* Weights; // last weights
00125   int WeightsSize;
00126   float LastPCoords[3]; // last local coordinates
00127   vtkIdType LastCellId;
00128   int CacheHit;
00129   int CacheMiss;
00130   int Caching;
00131 
00132   vtkDataSet* LastDataSet;
00133 
00134   vtkSetStringMacro(VectorsSelection);
00135   char *VectorsSelection;
00136 
00137   vtkInterpolatedVelocityFieldDataSetsType* DataSets;
00138 
00139   int FunctionValues(vtkDataSet* ds, float* x, float* f);
00140 
00141 private:
00142   vtkInterpolatedVelocityField(const vtkInterpolatedVelocityField&);  // Not implemented.
00143   void operator=(const vtkInterpolatedVelocityField&);  // Not implemented.
00144 };
00145 
00146 #endif
00147 
00148 
00149 
00150 
00151 
00152 
00153 
00154