VTK  9.0.1
vtkPainterCommunicator.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPainterCommunicator.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 =========================================================================*/
25 #ifndef vtkPainterCommunicator_h
26 #define vtkPainterCommunicator_h
27 
28 #include "vtkRenderingLICOpenGL2Module.h" // for export macro
29 
30 class VTKRENDERINGLICOPENGL2_EXPORT vtkPainterCommunicator
31 {
32 public:
35 
40  vtkPainterCommunicator(const vtkPainterCommunicator& other) { this->Copy(&other, false); }
41 
43  {
44  this->Copy(&other, false);
45  return *this;
46  }
47 
53  virtual void Copy(const vtkPainterCommunicator*, bool) {}
54 
58  virtual void Duplicate(const vtkPainterCommunicator*) {}
59 
63  virtual int GetRank() { return 0; }
64  virtual int GetSize() { return 1; }
65  virtual bool GetIsNull() { return false; }
66 
70  virtual int GetWorldRank() { return 0; }
71  virtual int GetWorldSize() { return 1; }
72 
76  virtual bool GetMPIInitialized() { return false; }
77  virtual bool GetMPIFinalized() { return true; }
78 };
79 
80 #endif
81 // VTK-HeaderTest-Exclude: vtkPainterCommunicator.h
A communicator that can safely be used inside a painter.
virtual void Duplicate(const vtkPainterCommunicator *)
Duplicate the communicator.
vtkPainterCommunicator & operator=(const vtkPainterCommunicator &other)
virtual bool GetMPIInitialized()
Querry MPI about its state.
vtkPainterCommunicator(const vtkPainterCommunicator &other)
Copy and assignment operators.
virtual void Copy(const vtkPainterCommunicator *, bool)
Copy the communicator, the flag indicates if ownership should be assumed.
virtual int GetRank()
Querry MPI about the communicator.
virtual int GetWorldRank()
Querry MPI about the world communicator.