ddt 1.4.0
 
Loading...
Searching...
No Matches
imageHelpers.hpp
Go to the documentation of this file.
1
10
11#ifndef IMAGEHELPERS_HPP_
12#define IMAGEHELPERS_HPP_
13
14//#include <algorithm>
15//#include <cctype>
16#include <tuple>
17#include <vector>
18#include <string>
19
20//#include <sys/stat.h>
21
22#include <cpl.h>
23
24// namespace ddt {
25
30
35std::vector<int> SubarrayLineInt(cpl_image *image, std::tuple<int, int> start,
36 std::tuple<int, int> end);
37
42std::vector<int> SubarrayLineInt(cpl_image *image, int x0, int y0, int x1,
43 int y1);
44
49std::vector<double> SubarrayLineDouble(cpl_image *image, int x0, int y0,
50 const int x1, const int y1);
51
56std::vector<std::vector<int>> SubarrayRectInt(cpl_image *image,
57 std::tuple<int, int> start,
58 std::tuple<int, int> end);
59
65std::vector<std::vector<int>> SubarrayRectInt(cpl_image *image, int llx,
66 int lly, int urx, int ury);
67
72cpl_image *SubImageRect(cpl_image *image, std::tuple<int, int> start,
73 std::tuple<int, int> end);
74
79cpl_image *SubImageRect(cpl_image *image, int llx, int lly, int urx, int ury);
80
89cpl_image *SubImageRectOutside(const cpl_image *const image, const int llx,
90 const int lly, const int urx, const int ury);
91
104cpl_image *SubImageCircular(const cpl_image *const image, const int xcenter,
105 const int ycenter, const int radius);
106
119cpl_image *SubImageCircularOutside(const cpl_image *const image,
120 const int xcenter, const int ycenter,
121 const int radius);
122
136double PixelDistance(const double startx, const double starty,
137 const double endx, const double endy,
138 double *const xoffset = nullptr,
139 double *const yoffset = nullptr);
140
156double PixelDistanceDegrees(const cpl_propertylist *const property_list,
157 const double startx, const double starty,
158 const double endx, const double endy,
159 double *const xoffsetdeg, double *const yoffsetdeg);
160
166double PixelToDegreesScalingFactor(const cpl_propertylist *const property_list);
167
174std::string ConvertDegreesToString(double deg);
175
176//} // namespace ddt
177
178#endif /* IMAGEHELPERS_HPP_ */
cpl_image * SubImageCircularOutside(const cpl_image *const image, const int xcenter, const int ycenter, const int radius)
Definition imageHelpers.cpp:261
cpl_image * SubImageCircular(const cpl_image *const image, const int xcenter, const int ycenter, const int radius)
Definition imageHelpers.cpp:222
cpl_image * SubImageRectOutside(const cpl_image *const image, const int llx, const int lly, const int urx, const int ury)
Definition imageHelpers.cpp:193
double PixelDistance(const double startx, const double starty, const double endx, const double endy, double *const xoffset=nullptr, double *const yoffset=nullptr)
Definition imageHelpers.cpp:294
std::vector< std::vector< int > > SubarrayRectInt(cpl_image *image, std::tuple< int, int > start, std::tuple< int, int > end)
Definition imageHelpers.cpp:117
double PixelDistanceDegrees(const cpl_propertylist *const property_list, const double startx, const double starty, const double endx, const double endy, double *const xoffsetdeg, double *const yoffsetdeg)
Definition imageHelpers.cpp:309
double PixelToDegreesScalingFactor(const cpl_propertylist *const property_list)
Definition imageHelpers.cpp:332
std::vector< int > SubarrayLineInt(cpl_image *image, std::tuple< int, int > start, std::tuple< int, int > end)
Definition imageHelpers.cpp:26
std::vector< double > SubarrayLineDouble(cpl_image *image, int x0, int y0, const int x1, const int y1)
Definition imageHelpers.cpp:79
cpl_image * SubImageRect(cpl_image *image, std::tuple< int, int > start, std::tuple< int, int > end)
Definition imageHelpers.cpp:165
std::string ConvertDegreesToString(double deg)
Definition imageHelpers.cpp:356