VTK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
vtkPBGLCollectGraph.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPBGLCollectGraph.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 2008 Sandia Corporation.
17  Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
18  the U.S. Government retains certain rights in this software.
19 -------------------------------------------------------------------------*/
50 #ifndef __vtkPBGLCollectGraph_h
51 #define __vtkPBGLCollectGraph_h
52 
53 #include "vtkInfovisParallelModule.h" // For export macro
54 #include "vtkStdString.h" // For string type
55 
56 #include <vtksys/stl/utility> // for pair
57 #include <vtksys/stl/numeric> // for accumulate, partial_sum
58 #include <vtksys/stl/functional> // for plus
59 
60 #include "vtkGraphAlgorithm.h"
61 
62 class vtkSelection;
63 class vtkDistributedGraphHelper;
64 
65 class VTKINFOVISPARALLEL_EXPORT vtkPBGLCollectGraph : public vtkGraphAlgorithm
66 {
67 public:
68  static vtkPBGLCollectGraph *New();
70  void PrintSelf(ostream& os, vtkIndent indent);
71 
73 
77  vtkGetMacro(TargetProcessor, int);
78  vtkSetMacro(TargetProcessor, int);
80 
82 
86  vtkGetMacro(ReplicateGraph, bool);
87  vtkSetMacro(ReplicateGraph, bool);
88  vtkBooleanMacro(ReplicateGraph, bool);
90 
92 
94  vtkGetMacro(CopyVertexData, bool);
95  vtkSetMacro(CopyVertexData, bool);
96  vtkBooleanMacro(CopyVertexData, bool);
98 
100 
102  vtkGetMacro(CopyEdgeData, bool);
103  vtkSetMacro(CopyEdgeData, bool);
104  vtkBooleanMacro(CopyEdgeData, bool);
106 
108 
111  vtkGetMacro(CreateOriginProcessArray, bool);
112  vtkSetMacro(CreateOriginProcessArray, bool);
113  vtkBooleanMacro(CreateOriginProcessArray, bool);
115 
117 
119  vtkSetStringMacro(OriginProcessArrayName);
121 
122 protected:
125 
126  virtual int RequestData(
127  vtkInformation *,
128  vtkInformationVector **,
129  vtkInformationVector *);
130 
131  virtual int FillInputPortInformation(
132  int port, vtkInformation* info);
133 
134  virtual int FillOutputPortInformation(
135  int port, vtkInformation* info);
136 
138 
141  void CopyStructureOfDataSetAttributes(vtkDataSetAttributes *inAttrs,
142  vtkDataSetAttributes *outAttrs,
143  vtkIdType numberOfTuples);
145 
146 private:
147  int TargetProcessor;
148  bool ReplicateGraph;
149  bool CopyVertexData;
150  bool CopyEdgeData;
151  bool CreateOriginProcessArray;
152  char * OriginProcessArrayName;
153 
154  vtkPBGLCollectGraph(const vtkPBGLCollectGraph&); // Not implemented.
155  void operator=(const vtkPBGLCollectGraph&); // Not implemented.
156 
157 };
158 
159 #endif
static vtkGraphAlgorithm * New()
A node in a selection tree. Used to store selection results.
Definition: vtkSelection.h:44
virtual int FillOutputPortInformation(int port, vtkInformation *info)
Superclass for algorithms that produce only graph as output.
void PrintSelf(ostream &os, vtkIndent indent)
Collects all of the pieces of a distributed vtkGraph into a single, non-distributed vtkGraph...
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
virtual int FillInputPortInformation(int port, vtkInformation *info)