/usr/include/vtk-5.8/vtkConeSource.h is in libvtk5-dev 5.8.0-5.
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 | /*=========================================================================
Program: Visualization Toolkit
Module: vtkConeSource.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 vtkConeSource - generate polygonal cone
// .SECTION Description
// vtkConeSource creates a cone centered at a specified point and pointing in
// a specified direction. (By default, the center is the origin and the
// direction is the x-axis.) Depending upon the resolution of this object,
// different representations are created. If resolution=0 a line is created;
// if resolution=1, a single triangle is created; if resolution=2, two
// crossed triangles are created. For resolution > 2, a 3D cone (with
// resolution number of sides) is created. It also is possible to control
// whether the bottom of the cone is capped with a (resolution-sided)
// polygon, and to specify the height and radius of the cone.
#ifndef __vtkConeSource_h
#define __vtkConeSource_h
#include "vtkPolyDataAlgorithm.h"
#include "vtkCell.h" // Needed for VTK_CELL_SIZE
class VTK_GRAPHICS_EXPORT vtkConeSource : public vtkPolyDataAlgorithm
{
public:
vtkTypeMacro(vtkConeSource,vtkPolyDataAlgorithm);
void PrintSelf(ostream& os, vtkIndent indent);
// Description:
// Construct with default resolution 6, height 1.0, radius 0.5, and
// capping on. The cone is centered at the origin and points down
// the x-axis.
static vtkConeSource *New();
// Description:
// Set the height of the cone. This is the height along the cone in
// its specified direction.
vtkSetClampMacro(Height,double,0.0,VTK_DOUBLE_MAX)
vtkGetMacro(Height,double);
// Description:
// Set the base radius of the cone.
vtkSetClampMacro(Radius,double,0.0,VTK_DOUBLE_MAX)
vtkGetMacro(Radius,double);
// Description:
// Set the number of facets used to represent the cone.
vtkSetClampMacro(Resolution,int,0,VTK_CELL_SIZE)
vtkGetMacro(Resolution,int);
// Description:
// Set the center of the cone. It is located at the middle of the axis of
// the cone. Warning: this is not the center of the base of the cone!
// The default is 0,0,0.
vtkSetVector3Macro(Center,double);
vtkGetVectorMacro(Center,double,3);
// Description:
// Set the orientation vector of the cone. The vector does not have
// to be normalized. The direction goes from the center of the base toward
// the apex. The default is (1,0,0).
vtkSetVector3Macro(Direction,double);
vtkGetVectorMacro(Direction,double,3);
// Description:
// Set the angle of the cone. This is the angle between the axis of the cone
// and a generatrix. Warning: this is not the aperture! The aperture is
// twice this angle.
// As a side effect, the angle plus height sets the base radius of the cone.
// Angle is expressed in degrees.
void SetAngle (double angle);
double GetAngle ();
// Description:
// Turn on/off whether to cap the base of the cone with a polygon.
vtkSetMacro(Capping,int);
vtkGetMacro(Capping,int);
vtkBooleanMacro(Capping,int);
protected:
vtkConeSource(int res=6);
~vtkConeSource() {}
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *);
int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *);
double Height;
double Radius;
int Resolution;
int Capping;
double Center[3];
double Direction[3];
private:
vtkConeSource(const vtkConeSource&); // Not implemented.
void operator=(const vtkConeSource&); // Not implemented.
};
#endif
|