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 
43 
45 class vtkPoints;
46 class vtkRenderer;
47 class vtkTree;
48 class vtkTreeMapLayout;
51 
53 {
54 public:
57  void PrintSelf(ostream& os, vtkIndent indent);
58 
60 
62  void SetLayout(vtkTreeMapLayout* layout);
63  vtkGetObjectMacro(Layout, vtkTreeMapLayout);
65 
67 
69  void SetTreeMapToPolyData(vtkTreeMapToPolyData* filter);
70  vtkGetObjectMacro(TreeMapToPolyData, vtkTreeMapToPolyData);
72 
74 
76  vtkSetStringMacro(LabelField);
77  vtkGetStringMacro(LabelField);
79 
81 
83  void OnMouseMove();
84  void OnLeftButtonUp();
86 
88 
89  void HighLightItem(vtkIdType id);
90  void HighLightCurrentSelectedItem();
92 
93  virtual void SetInteractor(vtkRenderWindowInteractor *rwi);
94 
96  void SetHighLightColor(double r, double g, double b);
97 
99  void SetSelectionLightColor(double r, double g, double b);
100 
102 
103  void SetHighLightWidth(double lw);
104  double GetHighLightWidth();
106 
108 
109  void SetSelectionWidth(double lw);
110  double GetSelectionWidth();
112 
113 protected:
116 
117 private:
119  void operator=(const vtkInteractorStyleTreeMapHover&); // Not implemented
120 
121  // These methods are used internally
122  vtkIdType GetTreeMapIdAtPos(int x, int y);
123  void GetBoundingBoxForTreeMapItem(vtkIdType id, float *binfo);
124 
125  vtkWorldPointPicker* Picker;
126  vtkBalloonRepresentation* Balloon;
127  vtkActor *HighlightActor;
128  vtkActor *SelectionActor;
129  vtkPoints *HighlightPoints;
130  vtkPoints *SelectionPoints;
131  vtkTreeMapLayout* Layout;
132  vtkTreeMapToPolyData* TreeMapToPolyData;
133  char *LabelField;
134  vtkIdType CurrentSelectedId;
135 };
136 
137 #endif
virtual void SetInteractor(vtkRenderWindowInteractor *interactor)
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:49
abstract specification for renderers
Definition: vtkRenderer.h:69
layout a vtkTree into a tree map
int vtkIdType
Definition: vtkType.h:255
static vtkInteractorStyleImage * New()
#define VTK_VIEWS_EXPORT
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:37
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:58
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.
represent and manipulate 3D points
Definition: vtkPoints.h:38