Coverage Report

Created: 2026-09-14 06:50

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/proj/src/projections/wag7.cpp
Line
Count
Source
1
2
3
#include <math.h>
4
5
#include "proj.h"
6
#include "proj_internal.h"
7
8
PROJ_HEAD(wag7, "Wagner VII") "\n\tMisc Sph, no inv";
9
10
0
static PJ_XY wag7_s_forward(PJ_LP lp, PJ *P) { /* Spheroidal, forward */
11
0
    PJ_XY xy = {0.0, 0.0};
12
13
0
    (void)P; /* Shut up compiler warnings about unused P */
14
15
0
    xy.y = 0.90630778703664996 * sin(lp.phi);
16
0
    const double theta = asin(xy.y);
17
0
    const double ct = cos(theta);
18
0
    lp.lam /= 3.;
19
0
    xy.x = 2.66723 * ct * sin(lp.lam);
20
0
    const double D = 1 / (sqrt(0.5 * (1 + ct * cos(lp.lam))));
21
0
    xy.y *= 1.24104 * D;
22
0
    xy.x *= D;
23
0
    return (xy);
24
0
}
25
26
0
PJ *PJ_PROJECTION(wag7) {
27
0
    P->fwd = wag7_s_forward;
28
0
    P->inv = nullptr;
29
0
    P->es = 0.;
30
0
    return P;
31
0
}