VTK
vtkPChacoReader.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPChacoReader.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 =========================================================================*/
15 /*----------------------------------------------------------------------------
16  Copyright (c) Sandia Corporation
17  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
18 ----------------------------------------------------------------------------*/
19 
29 #ifndef __vtkPChacoReader_h
30 #define __vtkPChacoReader_h
31 
32 #include "vtkChacoReader.h"
33 
34 class vtkTimerLog;
36 
38 {
39 public:
40  static vtkPChacoReader *New();
42  void PrintSelf(ostream& os, vtkIndent indent);
43 
47  void SetController(vtkMultiProcessController *c);
48  vtkGetObjectMacro(Controller, vtkMultiProcessController);
49 
50 protected:
52  ~vtkPChacoReader();
53 
56  int RequestData(
58 
59 private:
60  vtkPChacoReader(const vtkPChacoReader&); // Not implemented
61  void operator=(const vtkPChacoReader&); // Not implemented
62 
63  void SetUpEmptyGrid(vtkUnstructuredGrid *output);
64  int DivideCells(vtkMultiProcessController *contr, vtkUnstructuredGrid *output,
65  int source);
66  int SendGrid(vtkMultiProcessController *c, int to, vtkUnstructuredGrid *grid);
67  vtkUnstructuredGrid *GetGrid(vtkMultiProcessController *c, int from);
69  char *MarshallDataSet(vtkUnstructuredGrid *extractedGrid, int &len);
70  vtkUnstructuredGrid *UnMarshallDataSet(char *buf, int size);
71 
72  int NumProcesses;
73  int MyId;
74 
75  vtkMultiProcessController *Controller;
76 };
77 
78 #endif