/usr/include/vtk-5.10/vtkProp3DButtonRepresentation.h is in libvtk5-dev 5.10.1+dfsg-2.1build1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 | /*=========================================================================
Program: Visualization Toolkit
Module: vtkProp3DButtonRepresentation.h
Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
All rights reserved.
See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the above copyright notice for more information.
=========================================================================*/
// .NAME vtkProp3DButtonRepresentation - defines a representation for a vtkButtonWidget
// .SECTION Description
// This class implements one type of vtkButtonRepresentation. Each button
// state can be represented with a separate instance of vtkProp3D. Thus
// buttons can be represented with vtkActor, vtkImageActor, volumes (e.g.,
// vtkVolume) and/or any other vtkProp3D. Also, the class invokes events when
// highlighting occurs (i.e., hovering, selecting) so that appropriate action
// can be taken to highlight the button (if desired).
//
// To use this representation, always begin by specifying the number of
// button states. Then provide, for each state, an instance of vtkProp3D.
//
// This widget representation uses the conventional placement method. The
// button is placed inside the bounding box defined by PlaceWidget by translating
// and scaling the vtkProp3D to fit (each vtkProp3D is transformed). Therefore,
// you must define the number of button states and each state (i.e., vtkProp3D)
// prior to calling vtkPlaceWidget.
// .SECTION See Also
// vtkButtonWidget vtkButtonRepresentation vtkButtonSource vtkEllipticalButtonSource
// vtkRectangularButtonSource
#ifndef __vtkProp3DButtonRepresentation_h
#define __vtkProp3DButtonRepresentation_h
#include "vtkButtonRepresentation.h"
class vtkPropPicker;
class vtkProp3D;
class vtkProp3DFollower;
class vtkPropArray; //PIMPLd
class VTK_WIDGETS_EXPORT vtkProp3DButtonRepresentation : public vtkButtonRepresentation
{
public:
// Description:
// Instantiate the class.
static vtkProp3DButtonRepresentation *New();
// Description:
// Standard methods for instances of the class.
vtkTypeMacro(vtkProp3DButtonRepresentation,vtkButtonRepresentation);
void PrintSelf(ostream& os, vtkIndent indent);
// Description:
// Add the ith texture corresponding to the ith button state.
// The parameter i should be (0 <= i < NumberOfStates).
void SetButtonProp(int i, vtkProp3D *prop);
vtkProp3D *GetButtonProp(int i);
// Description:
// Specify whether the button should always face the camera. If enabled,
// the button reorients itself towards the camera as the camera moves.
vtkSetMacro(FollowCamera,int);
vtkGetMacro(FollowCamera,int);
vtkBooleanMacro(FollowCamera,int);
// Description:
// Extend the vtkButtonRepresentation::SetState() method.
virtual void SetState(int state);
// Description:
// Provide the necessary methods to satisfy the vtkWidgetRepresentation API.
virtual int ComputeInteractionState(int X, int Y, int modify=0);
virtual void BuildRepresentation();
// Description:
// This method positions (translates and scales the props) into the
// bounding box specified. Note all the button props are scaled.
virtual void PlaceWidget(double bounds[6]);
// Description:
// Provide the necessary methods to satisfy the rendering API.
virtual void ShallowCopy(vtkProp *prop);
virtual double *GetBounds();
virtual void GetActors(vtkPropCollection *pc);
virtual void ReleaseGraphicsResources(vtkWindow*);
virtual int RenderOpaqueGeometry(vtkViewport*);
virtual int RenderVolumetricGeometry(vtkViewport*);
virtual int RenderTranslucentPolygonalGeometry(vtkViewport*);
virtual int HasTranslucentPolygonalGeometry();
protected:
vtkProp3DButtonRepresentation();
~vtkProp3DButtonRepresentation();
// The current vtkProp3D used to represent the button
vtkProp3D *CurrentProp;
// Follow the camera if requested
vtkProp3DFollower *Follower;
int FollowCamera;
// Keep track of the props associated with the N
// states of the button. This is a PIMPLd stl map.
vtkPropArray *PropArray;
// For picking the button
vtkPropPicker *Picker;
private:
vtkProp3DButtonRepresentation(const vtkProp3DButtonRepresentation&); //Not implemented
void operator=(const vtkProp3DButtonRepresentation&); //Not implemented
};
#endif
|