Isis 3.0
Back | Home
ProcessPolygons.h
Go to the documentation of this file.
1 #ifndef ProcessPolygons_h
2 #define ProcessPolygons_h
3 
4 #include <geos/geom/Coordinate.h>
5 #include <geos/geom/MultiPolygon.h>
6 #include <geos/geom/Polygon.h>
7 
8 #include "Brick.h"
9 #include "FileName.h"
10 #include "Process.h"
11 #include "ProjectionFactory.h"
12 
13 namespace Isis {
14 
40  class ProcessPolygons : public Isis::Process {
41 
42  public:
44 
45  void SetStatCubes(const QString &parameter, const int nsamps,
46  const int nlines, int nbands = 1);
47 
48  void SetStatCubes(const QString &avgFileName, const QString
49  &countFileName, Isis::CubeAttributeOutput &atts,
50  const int nsamps, const int nlines, int nbands = 1);
51  void SetIntersectAlgorithm(const bool useCenter);
52 
53  Isis::Cube *AppendOutputCube(const QString &avgFileName,
54  const QString &countFileName = "");
55 
56  void Rasterize(std::vector<double> &samples,
57  std::vector<double> &lines,
58  std::vector<double> &values);
59 
60  void Rasterize(std::vector<double> &samples,
61  std::vector<double> &lines,
62  int &band, double &value);
63 
64  void EndProcess();
65  void Finalize();
66 
67  private:
68  void FillPolygon(int Flag);
69  void GetPolygonCoords();
70 
71  bool m_useCenter;
72  std::vector<double> m_sampleVertices, m_lineVertices, m_dns;
73  int m_band;
74  Brick *m_average;
75  Brick *m_count;
76  geos::geom::Polygon *m_imagePoly;
77 
78  };
79 
80 };
81 
82 #endif
void SetIntersectAlgorithm(const bool useCenter)
Sets the algorithm for how output pixels are rasterized.
Definition: ProcessPolygons.cpp:374
void EndProcess()
Definition: ProcessPolygons.cpp:239
void Finalize()
Cleans up by closing cubes and freeing memory for owned cubes.
Definition: ProcessPolygons.cpp:252
void Rasterize(std::vector< double > &samples, std::vector< double > &lines, std::vector< double > &values)
Definition: ProcessPolygons.cpp:38
ProcessPolygons()
Definition: ProcessPolygons.cpp:22
Buffer for containing a three dimensional section of an image.
Definition: Brick.h:60
Isis::Cube * AppendOutputCube(const QString &avgFileName, const QString &countFileName="")
This gives the option to append to the cube.
Definition: ProcessPolygons.cpp:269
void SetStatCubes(const QString &parameter, const int nsamps, const int nlines, int nbands=1)
Definition: ProcessPolygons.cpp:349
Manipulate and parse attributes of output cube filenames.
Definition: CubeAttribute.h:485
Definition: ProcessPolygons.h:40
Base class for all cube processing derivatives.
Definition: Process.h:157
IO Handler for Isis Cubes.
Definition: Cube.h:158

U.S. Department of the Interior | U.S. Geological Survey
ISIS | Privacy & Disclaimers | Astrogeology Research Program
To contact us, please post comments and questions on the ISIS Support Center
File Modified: 07/12/2023 23:26:16