SatDump 2.0.0-alpha-76a915210
Loading...
Searching...
No Matches
equirectangular.h
1#pragma once
2
3/*
4Implementation of a standard GEOS projection, adapted from libproj.
5Some variables are hardcoded for the intended usecase, making some
6degree of tuning unecessary.
7Uses the WGS84 ellipsoid.
8*/
9namespace satdump
10{
11 namespace projection
12 {
14 {
15 private:
16 int image_height;
17 int image_width;
18
19 float top_left_lat;
20 float top_left_lon;
21
22 float bottom_right_lat;
23 float bottom_right_lon;
24
25 float covered_lat;
26 float covered_lon;
27
28 float offset_lat;
29 float offset_lon;
30
31 public:
32 void init(int img_width, int img_height, float tl_lon, float tl_lat, float br_lon, float br_lat);
33 void forward(float lon, float lat, int &x, int &y, bool allow_oob = false);
34 void reverse(int x, int y, float &lon, float &lat);
35 };
36 };
37};
Definition equirectangular.h:14