VTK
vtkRandomLayoutStrategy.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkRandomLayoutStrategy.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 -------------------------------------------------------------------------*/
34 #ifndef vtkRandomLayoutStrategy_h
35 #define vtkRandomLayoutStrategy_h
36 
37 #include "vtkInfovisLayoutModule.h" // For export macro
38 #include "vtkGraphLayoutStrategy.h"
39 
41 {
42 public:
43  static vtkRandomLayoutStrategy *New();
44 
46  void PrintSelf(ostream& os, vtkIndent indent);
47 
49 
52  vtkSetClampMacro(RandomSeed, int, 0, VTK_INT_MAX);
53  vtkGetMacro(RandomSeed, int);
55 
57 
60  vtkSetVector6Macro(GraphBounds,double);
61  vtkGetVectorMacro(GraphBounds,double,6);
63 
65 
68  vtkSetMacro(AutomaticBoundsComputation, int);
69  vtkGetMacro(AutomaticBoundsComputation, int);
70  vtkBooleanMacro(AutomaticBoundsComputation, int);
72 
74 
76  vtkSetMacro(ThreeDimensionalLayout, int);
77  vtkGetMacro(ThreeDimensionalLayout, int);
78  vtkBooleanMacro(ThreeDimensionalLayout, int);
80 
82  void SetGraph(vtkGraph *graph);
83 
85  void Layout();
86 
87 protected:
90 
92  double GraphBounds[6];
94  int ThreeDimensionalLayout; //Boolean for a third dimension.
95 private:
96 
97  vtkRandomLayoutStrategy(const vtkRandomLayoutStrategy&); // Not implemented.
98  void operator=(const vtkRandomLayoutStrategy&); // Not implemented.
99 };
100 
101 #endif
102 
virtual void SetGraph(vtkGraph *graph)
randomly places vertices in 2 or 3 dimensions
#define VTKINFOVISLAYOUT_EXPORT
#define VTK_INT_MAX
Definition: vtkType.h:130
abstract superclass for all graph layout strategies
Base class for graph data types.
Definition: vtkGraph.h:288
a simple class to control print indentation
Definition: vtkIndent.h:38
static vtkObject * New()
virtual void Layout()=0
void PrintSelf(ostream &os, vtkIndent indent)