VTK
vtkGeoGraticule.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkGeoGraticule.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-------------------------------------------------------------------------*/
37#ifndef vtkGeoGraticule_h
38#define vtkGeoGraticule_h
39
40#include "vtkGeovisCoreModule.h" // For export macro
42
43class vtkPolyData;
44
45class VTKGEOVISCORE_EXPORT vtkGeoGraticule : public vtkPolyDataAlgorithm
46{
47public:
49 virtual void PrintSelf( ostream& os, vtkIndent indent );
51
53
56 vtkSetVector2Macro(LatitudeBounds,double);
57 vtkGetVector2Macro(LatitudeBounds,double);
59
61
64 vtkSetVector2Macro(LongitudeBounds,double);
65 vtkGetVector2Macro(LongitudeBounds,double);
67
69 LEVEL_MIN = 0,
70 LEVEL_MAX = 11,
71 NUMBER_OF_LEVELS = ( LEVEL_MAX - LEVEL_MIN + 1 )
72 };
73
75
78 vtkSetClampMacro(LatitudeLevel,int,LEVEL_MIN,LEVEL_MAX);
79 vtkGetMacro(LatitudeLevel,int);
81
83
86 vtkSetClampMacro(LongitudeLevel,int,LEVEL_MIN,LEVEL_MAX);
87 vtkGetMacro(LongitudeLevel,int);
89
93 static double GetLatitudeDelta(int level)
94 { return LatitudeLevelTics[level]; }
95
99 static double GetLongitudeDelta(int level)
100 { return LongitudeLevelTics[level]; }
101
103
110 vtkGetMacro(GeometryType,int);
112
114 POLYLINES = 0x1,
115 QUADRILATERALS = 0x2
116 };
117
118protected:
121
123 double LatitudeBounds[2];
124 double LongitudeBounds[2];
127
129
132 static double LatitudeLevelTics[NUMBER_OF_LEVELS];
133 static double LongitudeLevelTics[NUMBER_OF_LEVELS];
135
137
138 void GenerateGraticule( vtkPolyData* output, double latbds[2], double lngbds[2] );
139 int ComputeLineLevel( int ticId, int baseLevel, const double* levelIncrements );
140
141private:
142 vtkGeoGraticule( const vtkGeoGraticule& ) VTK_DELETE_FUNCTION;
143 void operator = ( const vtkGeoGraticule& ) VTK_DELETE_FUNCTION;
144};
145
146#endif // vtkGeoGraticule_h
Create a polygonal lat-long grid.
int ComputeLineLevel(int ticId, int baseLevel, const double *levelIncrements)
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.
static double GetLatitudeDelta(int level)
The latitude delta at a certain frequency level.
virtual void PrintSelf(ostream &os, vtkIndent indent)
Methods invoked by print to print information about the object including superclasses.
virtual ~vtkGeoGraticule()
void GenerateGraticule(vtkPolyData *output, double latbds[2], double lngbds[2])
static vtkGeoGraticule * New()
static double GetLongitudeDelta(int level)
The longitude delta at a certain frequency level.
a simple class to control print indentation
Definition: vtkIndent.h:40
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that produce only polydata as output.
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:86
@ level
Definition: vtkX3D.h:395
vtkSetMacro(IgnoreDriverBugs, bool)
Updates the extensions string.