use doubles in mercartor projection functions
This commit is contained in:
parent
32c1fd082d
commit
d0198649f2
@ -35,11 +35,11 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
inline double y2lat(double a) {
|
inline double y2lat(double a) {
|
||||||
return 180/M_PI * (2 * atan(exp(a*M_PI/180)) - M_PI/2);
|
return 180./M_PI * (2. * atan(exp(a*M_PI/180.)) - M_PI/2.);
|
||||||
}
|
}
|
||||||
|
|
||||||
inline double lat2y(double a) {
|
inline double lat2y(double a) {
|
||||||
return 180/M_PI * log(tan(M_PI/4+a*(M_PI/180)/2));
|
return 180./M_PI * log(tan(M_PI/4.+a*(M_PI/180.)/2.));
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* MERCATORUTIL_H_ */
|
#endif /* MERCATORUTIL_H_ */
|
||||||
|
Loading…
Reference in New Issue
Block a user