VTK  9.2.6
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 =========================================================================*/
35 #ifndef vtkProjectSphereFilter_h
36 #define vtkProjectSphereFilter_h
37 
38 #include "vtkFiltersGeometryModule.h" // For export macro
39 #include "vtkPointSetAlgorithm.h"
40 
41 class vtkCell;
42 class vtkCellArray;
44 class vtkIdList;
47 
48 class VTKFILTERSGEOMETRY_EXPORT vtkProjectSphereFilter : public vtkPointSetAlgorithm
49 {
50 public:
52  void PrintSelf(ostream& os, vtkIndent indent) override;
53 
55 
57 
60  vtkSetVector3Macro(Center, double);
61  vtkGetVectorMacro(Center, double, 3);
63 
65 
69  vtkGetMacro(KeepPolePoints, bool);
70  vtkSetMacro(KeepPolePoints, bool);
71  vtkBooleanMacro(KeepPolePoints, bool);
73 
75 
80  vtkGetMacro(TranslateZ, bool);
81  vtkSetMacro(TranslateZ, bool);
82  vtkBooleanMacro(TranslateZ, bool);
84 
85 protected:
88 
90 
92 
95  void TransformTensors(vtkIdType id, double* coord, vtkDataSetAttributes* arrays);
96 
102  virtual void ComputePointsClosestToCenterLine(double, vtkIdList*) {}
103 
108  virtual double GetZTranslation(vtkPointSet* input);
109 
114  void SplitCell(vtkPointSet* input, vtkPointSet* output, vtkIdType inputCellId,
115  vtkIncrementalPointLocator* locator, vtkCellArray* connectivity, int splitSide);
116 
117  void SetCellInformation(vtkUnstructuredGrid* output, vtkCell* cell, vtkIdType numberOfNewCells);
118 
119 private:
121  void operator=(const vtkProjectSphereFilter&) = delete;
122 
123  double Center[3];
124  const double SplitLongitude;
125  bool KeepPolePoints;
126  bool TranslateZ;
127 };
128 
129 #endif // vtkProjectSphereFilter_h
object to represent cell connectivity
Definition: vtkCellArray.h:196
abstract class to specify cell behavior
Definition: vtkCell.h:70
represent and manipulate attribute data in a dataset
list of point or cell ids
Definition: vtkIdList.h:43
Abstract class in support of both point location and point insertion.
a simple class to control print indentation
Definition: vtkIndent.h:49
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that produce output of the same type as input.
concrete class for storing a set of points
Definition: vtkPointSet.h:79
A filter to 'unroll' a sphere.
void TransformCellInformation(vtkPointSet *input, vtkPointSet *output, vtkIdList *)
virtual double GetZTranslation(vtkPointSet *input)
If TranslateZ is true then this is the method that computes the amount to translate.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkProjectSphereFilter * New()
void TransformTensors(vtkIdType id, double *coord, vtkDataSetAttributes *arrays)
virtual void ComputePointsClosestToCenterLine(double, vtkIdList *)
Parallel part of the algorithm to figure out the closest point to the centerline (i....
void TransformPointInformation(vtkPointSet *input, vtkPointSet *output, vtkIdList *)
~vtkProjectSphereFilter() override
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.
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
void SetCellInformation(vtkUnstructuredGrid *output, vtkCell *cell, vtkIdType numberOfNewCells)
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
dataset represents arbitrary combinations of all possible cell types
@ info
Definition: vtkX3D.h:382
@ port
Definition: vtkX3D.h:453
int vtkIdType
Definition: vtkType.h:332