1 // Copyright (C) 2007-2008 CEA/DEN, EDF R&D, OPEN CASCADE
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
22 // VISU OBJECT : interactive object for VISU entities implementation
23 // File: VISU_StreamLinesPL.hxx
24 // Author: Alexey PETROV
27 #ifndef VISU_StreamLinesPL_HeaderFile
28 #define VISU_StreamLinesPL_HeaderFile
30 #include "VISUPipeline.hxx"
31 #include "VISU_DeformedShapePL.hxx"
32 #include <vtkStreamLine.h>
37 class VTKViewer_GeometryFilter;
38 class VISU_MaskPointsFilter;
41 //----------------------------------------------------------------------------
42 class VISU_PIPELINE_EXPORT VISU_StreamLinesPL : public VISU_DeformedShapePL
45 vtkTypeMacro(VISU_StreamLinesPL, VISU_DeformedShapePL);
55 //----------------------------------------------------------------------------
58 SetParams(vtkFloatingPointType theIntStep,
59 vtkFloatingPointType thePropogationTime,
60 vtkFloatingPointType theStepLength,
61 vtkPointSet* theSource = NULL,
62 vtkFloatingPointType thePercents = 0.3,
63 int theDirection = VTK_INTEGRATE_BOTH_DIRECTIONS);
99 GetMaxIntegrationStep();
103 GetMinIntegrationStep();
115 GetMinPropagationTime();
119 GetMaxPropagationTime();
123 GetBasePropagationTime();
142 //! Gets memory size used by the instance (bytes).
149 SetMapScale(vtkFloatingPointType theMapScale = 1.0);
154 GetMaxIntegrationStep(vtkDataSet* theDataSet);
158 GetMinIntegrationStep(vtkDataSet* theDataSet,
159 vtkFloatingPointType thePercents = 0.3);
162 GetBaseIntegrationStep(vtkDataSet* theDataSet,
163 vtkFloatingPointType thePercents = 0.3);
167 GetMinPropagationTime(vtkDataSet* theDataSet);
171 GetMaxPropagationTime(vtkDataSet* theDataSet);
175 GetBasePropagationTime(vtkDataSet* theDataSet);
179 GetMinStepLength(vtkDataSet* theDataSet);
183 GetMaxStepLength(vtkDataSet* theDataSet);
187 GetBaseStepLength(vtkDataSet* theDataSet);
191 GetVelocityCoeff(vtkDataSet* theDataSet);
195 IsPossible(vtkPointSet* theDataSet,
196 vtkFloatingPointType thePercents = 0.3);
199 VISU_StreamLinesPL();
202 ~VISU_StreamLinesPL();
206 DoShallowCopy(VISU_PipeLine *thePipeLine,
207 bool theIsCopyInput);
211 GetNecasseryMemorySize(vtkIdType theNbOfPoints,
212 vtkFloatingPointType theStepLength,
213 vtkFloatingPointType thePropogationTime,
214 vtkFloatingPointType thePercents = 0.3);
218 FindPossibleParams(vtkDataSet* theDataSet,
219 vtkFloatingPointType& theStepLength,
220 vtkFloatingPointType& thePropogationTime,
221 vtkFloatingPointType& thePercents);
225 CorrectIntegrationStep(vtkFloatingPointType theStep,
226 vtkDataSet* theDataSet,
227 vtkFloatingPointType thePercents = 0.3);
231 CorrectPropagationTime(vtkFloatingPointType thePropagationTime,
232 vtkDataSet* theDataSet);
236 CorrectStepLength(vtkFloatingPointType theStep,
237 vtkDataSet* theDataSet);
239 vtkStreamLine* myStream;
240 vtkPointSet* mySource;
241 vtkCellCenters* myCenters;
242 VTKViewer_GeometryFilter *myGeomFilter;
243 VISU_MaskPointsFilter *myPointsFilter;
244 vtkFloatingPointType myPercents;
247 VISU_StreamLinesPL(const VISU_StreamLinesPL&); // Not implemented.
248 void operator=(const VISU_StreamLinesPL&); // Not implemented.