1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2025-02-12 14:20:48 +01:00
GPXSee/src/common/garmin.h

19 lines
284 B
C
Raw Normal View History

#ifndef GARMIN_H
#define GARMIN_H
#include <QtGlobal>
#define LS(val, bits) ((qint32)(((quint32)(val))<<(bits)))
inline double toWGS32(qint32 v)
{
return ((double)v / (double)(1U<<31)) * 180.0;
}
2019-11-10 19:48:17 +01:00
inline double toWGS24(qint32 v)
{
return toWGS32(LS(v, 8));
}
#endif // GARMIN_H