VTK  9.0.2
vtkPParticleTracerBase.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkParticleTracerBase.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
27 #ifndef vtkPParticleTracerBase_h
28 #define vtkPParticleTracerBase_h
29 
30 #include "vtkParticleTracerBase.h"
31 #include "vtkSmartPointer.h" // For protected ivars.
32 
33 #include <vector> // STL Header
34 
35 #include "vtkFiltersParallelFlowPathsModule.h" // For export macro
36 
37 class VTKFILTERSPARALLELFLOWPATHS_EXPORT vtkPParticleTracerBase : public vtkParticleTracerBase
38 {
39 public:
41  void PrintSelf(ostream& os, vtkIndent indent) override;
42 
44 
48  virtual void SetController(vtkMultiProcessController* controller);
49  vtkGetObjectMacro(Controller, vtkMultiProcessController);
51 
52 protected:
54  {
58  };
59 
60  typedef std::vector<RemoteParticleInfo> RemoteParticleVector;
61 
64 
65  virtual int RequestUpdateExtent(vtkInformation* request, vtkInformationVector** inputVector,
66  vtkInformationVector* outputVector) override;
67 
68  //
69 
70  virtual vtkPolyData* Execute(vtkInformationVector** inputVector) override;
74 
82  virtual void AssignSeedsToProcessors(double time, vtkDataSet* source, int sourceID, int ptId,
84  int& localAssignedCount) override;
85 
90  virtual void AssignUniqueIds(
91  vtkParticleTracerBaseNamespace::ParticleVector& localSeedPoints) override;
92 
98  virtual bool SendReceiveParticles(
99  RemoteParticleVector& outofdomain, RemoteParticleVector& received);
100 
101  virtual bool UpdateParticleListFromOtherProcesses() override;
102 
108  virtual bool IsPointDataValid(vtkDataObject* input) override;
109 
110  //
111 
112  //
113 
114  // MPI controller needed when running in parallel
116 
117  // List used for transmitting between processors during parallel operation
119 
120  RemoteParticleVector Tail; // this is to receive the "tails" of traces from other processes
121 private:
123  void operator=(const vtkPParticleTracerBase&) = delete;
124 };
125 #endif
general representation of visualization data
Definition: vtkDataObject.h:60
abstract class to specify dataset behavior
Definition: vtkDataSet.h:57
a simple class to control print indentation
Definition: vtkIndent.h:34
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Multiprocessing communication superclass.
virtual bool SendReceiveParticles(RemoteParticleVector &outofdomain, RemoteParticleVector &received)
this is used during classification of seed points and also between iterations of the main loop as par...
virtual int RequestUpdateExtent(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
This is called by the superclass.
std::vector< RemoteParticleInfo > RemoteParticleVector
RemoteParticleVector MPISendList
virtual vtkPolyData * Execute(vtkInformationVector **inputVector) override
virtual void AssignSeedsToProcessors(double time, vtkDataSet *source, int sourceID, int ptId, vtkParticleTracerBaseNamespace::ParticleVector &localSeedPoints, int &localAssignedCount) override
Before starting the particle trace, classify all the injection/seed points according to which process...
vtkMultiProcessController * Controller
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual bool UpdateParticleListFromOtherProcesses() override
this is used during classification of seed points and also between iterations of the main loop as par...
virtual bool SendParticleToAnotherProcess(vtkParticleTracerBaseNamespace::ParticleInformation &info, vtkParticleTracerBaseNamespace::ParticleInformation &previous, vtkPointData *) override
virtual void AssignUniqueIds(vtkParticleTracerBaseNamespace::ParticleVector &localSeedPoints) override
give each one a unique ID.
virtual void SetController(vtkMultiProcessController *controller)
Set/Get the controller used when sending particles between processes The controller must be an instan...
virtual bool IsPointDataValid(vtkDataObject *input) override
Method that checks that the input arrays are ordered the same on all data sets.
A particle tracer for vector fields.
represent and manipulate point attribute data
Definition: vtkPointData.h:32
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:85
std::vector< ParticleInformation > ParticleVector
@ info
Definition: vtkX3D.h:382
@ previous
Definition: vtkX3D.h:455
@ time
Definition: vtkX3D.h:503
vtkParticleTracerBaseNamespace::ParticleInformation Current
vtkParticleTracerBaseNamespace::ParticleInformation Previous
vtkSmartPointer< vtkPointData > PreviousPD
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)