VTK
vtkProjectSphereFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkProjectSphereFilter.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 =========================================================================*/
26 #ifndef vtkProjectSphereFilter_h
27 #define vtkProjectSphereFilter_h
28 
29 #include "vtkFiltersGeometryModule.h" // For export macro
30 #include "vtkPointSetAlgorithm.h"
31 
32 class vtkCell;
33 class vtkCellArray;
35 class vtkIdList;
38 
39 class VTKFILTERSGEOMETRY_EXPORT vtkProjectSphereFilter :
41 {
42 public:
44  void PrintSelf(ostream &os, vtkIndent indent) VTK_OVERRIDE;
45 
47 
49 
52  vtkSetVector3Macro(Center,double);
53  vtkGetVectorMacro(Center,double,3);
55 
57 
61  vtkGetMacro(KeepPolePoints, bool);
62  vtkSetMacro(KeepPolePoints, bool);
63  vtkBooleanMacro(KeepPolePoints, bool);
65 
67 
72  vtkGetMacro(TranslateZ, bool);
73  vtkSetMacro(TranslateZ, bool);
74  vtkBooleanMacro(TranslateZ, bool);
76 
77 protected:
79  ~vtkProjectSphereFilter() VTK_OVERRIDE;
80 
81  int FillInputPortInformation(int port, vtkInformation *info) VTK_OVERRIDE;
82 
83  int RequestData(vtkInformation *, vtkInformationVector **,
84  vtkInformationVector *) VTK_OVERRIDE;
85 
86  void TransformPointInformation(vtkPointSet* input, vtkPointSet* output, vtkIdList*);
87  void TransformCellInformation(vtkPointSet* input, vtkPointSet* output, vtkIdList*);
88  void TransformTensors(vtkIdType id, double* coord, vtkDataSetAttributes* arrays);
89 
95  virtual void ComputePointsClosestToCenterLine(double, vtkIdList*)
96  {}
97 
102  virtual double GetZTranslation(vtkPointSet* input);
103 
108  void SplitCell( vtkPointSet* input, vtkPointSet* output, vtkIdType inputCellId,
109  vtkIncrementalPointLocator* locator, vtkCellArray* connectivity,
110  int splitSide);
111 
113  vtkUnstructuredGrid* output, vtkCell* cell, vtkIdType numberOfNewCells);
114 
115 private:
116  vtkProjectSphereFilter(const vtkProjectSphereFilter &) VTK_DELETE_FUNCTION;
117  void operator=(const vtkProjectSphereFilter &) VTK_DELETE_FUNCTION;
118 
119  double Center[3];
120  const double SplitLongitude;
121  bool KeepPolePoints;
122  bool TranslateZ;
123 };
124 
125 #endif // vtkProjectSphereFilter_h
vtkProjectSphereFilter::GetZTranslation
virtual double GetZTranslation(vtkPointSet *input)
If TranslateZ is true then this is the method that computes the amount to translate.
vtkProjectSphereFilter::SplitCell
void SplitCell(vtkPointSet *input, vtkPointSet *output, vtkIdType inputCellId, vtkIncrementalPointLocator *locator, vtkCellArray *connectivity, int splitSide)
Split a cell into multiple cells because it stretches across the SplitLongitude.
vtkPointSetAlgorithm
Superclass for algorithms that produce output of the same type as input.
Definition: vtkPointSetAlgorithm.h:44
vtkIdType
int vtkIdType
Definition: vtkType.h:287
vtkDataSetAttributes
represent and manipulate attribute data in a dataset
Definition: vtkDataSetAttributes.h:59
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:42
vtkPointSetAlgorithm.h
vtkX3D::port
@ port
Definition: vtkX3D.h:447
vtkProjectSphereFilter::vtkProjectSphereFilter
vtkProjectSphereFilter()
vtkCell
abstract class to specify cell behavior
Definition: vtkCell.h:60
vtkProjectSphereFilter
A filter to 'unroll' a sphere.
Definition: vtkProjectSphereFilter.h:41
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:40
vtkCellArray
object to represent cell connectivity
Definition: vtkCellArray.h:51
vtkProjectSphereFilter::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkIncrementalPointLocator
Abstract class in support of both point location and point insertion.
Definition: vtkIncrementalPointLocator.h:52
vtkIdList
list of point or cell ids
Definition: vtkIdList.h:37
vtkBooleanMacro
vtkBooleanMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:87
vtkSetMacro
vtkSetMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
vtkX3D::info
@ info
Definition: vtkX3D.h:376
vtkPointSet
abstract class for specifying dataset behavior
Definition: vtkPointSet.h:43
vtkProjectSphereFilter::New
static vtkProjectSphereFilter * New()
vtkProjectSphereFilter::~vtkProjectSphereFilter
~vtkProjectSphereFilter() override
vtkUnstructuredGrid
dataset represents arbitrary combinations of all possible cell types
Definition: vtkUnstructuredGrid.h:83
vtkProjectSphereFilter::SetCellInformation
void SetCellInformation(vtkUnstructuredGrid *output, vtkCell *cell, vtkIdType numberOfNewCells)