VTK
vtkInteractorStyleTreeMapHover.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkInteractorStyleTreeMapHover.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 -------------------------------------------------------------------------*/
39 #ifndef vtkInteractorStyleTreeMapHover_h
40 #define vtkInteractorStyleTreeMapHover_h
41 
42 #include "vtkViewsInfovisModule.h" // For export macro
44 
46 class vtkPoints;
47 class vtkRenderer;
48 class vtkTree;
49 class vtkTreeMapLayout;
52 
54 {
55 public:
58  void PrintSelf(ostream& os, vtkIndent indent);
59 
61 
63  void SetLayout(vtkTreeMapLayout* layout);
64  vtkGetObjectMacro(Layout, vtkTreeMapLayout);
66 
68 
70  void SetTreeMapToPolyData(vtkTreeMapToPolyData* filter);
71  vtkGetObjectMacro(TreeMapToPolyData, vtkTreeMapToPolyData);
73 
75 
77  vtkSetStringMacro(LabelField);
78  vtkGetStringMacro(LabelField);
80 
82 
84  void OnMouseMove();
85  void OnLeftButtonUp();
87 
89 
90  void HighLightItem(vtkIdType id);
91  void HighLightCurrentSelectedItem();
93 
94  virtual void SetInteractor(vtkRenderWindowInteractor *rwi);
95 
97  void SetHighLightColor(double r, double g, double b);
98 
100  void SetSelectionLightColor(double r, double g, double b);
101 
103 
104  void SetHighLightWidth(double lw);
105  double GetHighLightWidth();
107 
109 
110  void SetSelectionWidth(double lw);
111  double GetSelectionWidth();
113 
114 protected:
117 
118 private:
120  void operator=(const vtkInteractorStyleTreeMapHover&); // Not implemented
121 
122  // These methods are used internally
123  vtkIdType GetTreeMapIdAtPos(int x, int y);
124  void GetBoundingBoxForTreeMapItem(vtkIdType id, float *binfo);
125 
126  vtkWorldPointPicker* Picker;
127  vtkBalloonRepresentation* Balloon;
128  vtkActor *HighlightActor;
129  vtkActor *SelectionActor;
130  vtkPoints *HighlightPoints;
131  vtkPoints *SelectionPoints;
132  vtkTreeMapLayout* Layout;
133  vtkTreeMapToPolyData* TreeMapToPolyData;
134  char *LabelField;
135  vtkIdType CurrentSelectedId;
136 };
137 
138 #endif
virtual void SetInteractor(vtkRenderWindowInteractor *interactor)
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:50
abstract specification for renderers
Definition: vtkRenderer.h:62
layout a vtkTree into a tree map
int vtkIdType
Definition: vtkType.h:247
static vtkInteractorStyleImage * New()
interactive manipulation of the camera specialized for images
platform-independent render window interaction including picking and frame rate control.
virtual void OnLeftButtonUp()
a simple class to control print indentation
Definition: vtkIndent.h:38
represent the vtkBalloonWidget
virtual void OnMouseMove()
converts a tree to a polygonal data representing a tree map
A rooted tree data structure.
Definition: vtkTree.h:59
void PrintSelf(ostream &os, vtkIndent indent)
find world x,y,z corresponding to display x,y,z
An interactor style for a tree map view.
#define VTKVIEWSINFOVIS_EXPORT
represent and manipulate 3D points
Definition: vtkPoints.h:38