VTK
dox/Infovis/vtkRandomLayoutStrategy.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkRandomLayoutStrategy.h
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00015 /*-------------------------------------------------------------------------
00016   Copyright 2008 Sandia Corporation.
00017   Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
00018   the U.S. Government retains certain rights in this software.
00019 -------------------------------------------------------------------------*/
00034 #ifndef __vtkRandomLayoutStrategy_h
00035 #define __vtkRandomLayoutStrategy_h
00036 
00037 #include "vtkGraphLayoutStrategy.h"
00038 
00039 class VTK_INFOVIS_EXPORT vtkRandomLayoutStrategy : public vtkGraphLayoutStrategy 
00040 {
00041 public:
00042   static vtkRandomLayoutStrategy *New();
00043 
00044   vtkTypeMacro(vtkRandomLayoutStrategy, vtkGraphLayoutStrategy);
00045   void PrintSelf(ostream& os, vtkIndent indent);
00046 
00048 
00051   vtkSetClampMacro(RandomSeed, int, 0, VTK_LARGE_INTEGER);
00052   vtkGetMacro(RandomSeed, int);
00054 
00056 
00059   vtkSetVector6Macro(GraphBounds,double);
00060   vtkGetVectorMacro(GraphBounds,double,6);
00062 
00064 
00067   vtkSetMacro(AutomaticBoundsComputation, int);
00068   vtkGetMacro(AutomaticBoundsComputation, int);
00069   vtkBooleanMacro(AutomaticBoundsComputation, int);
00071 
00073 
00075   vtkSetMacro(ThreeDimensionalLayout, int);
00076   vtkGetMacro(ThreeDimensionalLayout, int);
00077   vtkBooleanMacro(ThreeDimensionalLayout, int);
00079 
00081   void SetGraph(vtkGraph *graph);
00082 
00084   void Layout();
00085 
00086 protected:
00087   vtkRandomLayoutStrategy();
00088   ~vtkRandomLayoutStrategy();
00089 
00090   int RandomSeed;
00091   double GraphBounds[6];
00092   int   AutomaticBoundsComputation;
00093   int   ThreeDimensionalLayout;  //Boolean for a third dimension.
00094 private:
00095 
00096   vtkRandomLayoutStrategy(const vtkRandomLayoutStrategy&);  // Not implemented.
00097   void operator=(const vtkRandomLayoutStrategy&);  // Not implemented.
00098 };
00099 
00100 #endif
00101