mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-03-15 07:29:15 +01:00
Depreciate Pergo maps
This commit is contained in:
parent
361bb26212
commit
13b0eac79f
@ -80,7 +80,6 @@ public:
|
|||||||
ArcGIS_MapsLT_Map_Labels = 1002,
|
ArcGIS_MapsLT_Map_Labels = 1002,
|
||||||
ArcGIS_MapsLT_Map_Hybrid = 1003,
|
ArcGIS_MapsLT_Map_Hybrid = 1003,
|
||||||
|
|
||||||
PergoTurkeyMap = 2001,
|
|
||||||
SigPacSpainMap = 3001,
|
SigPacSpainMap = 3001,
|
||||||
|
|
||||||
GoogleMapKorea = 4001,
|
GoogleMapKorea = 4001,
|
||||||
|
@ -121,7 +121,6 @@ QByteArray OPMaps::GetImageFrom(const MapType::Types &type, const Point &pos, co
|
|||||||
#ifdef DEBUG_TIMINGS
|
#ifdef DEBUG_TIMINGS
|
||||||
qDebug() << "opmaps after make image url" << time.elapsed();
|
qDebug() << "opmaps after make image url" << time.elapsed();
|
||||||
#endif // url "http://vec02.maps.yandex.ru/tiles?l=map&v=2.10.2&x=7&y=5&z=3" string
|
#endif // url "http://vec02.maps.yandex.ru/tiles?l=map&v=2.10.2&x=7&y=5&z=3" string
|
||||||
// "http://map3.pergo.com.tr/tile/02/000/000/007/000/000/002.png"
|
|
||||||
qheader.setUrl(QUrl(url));
|
qheader.setUrl(QUrl(url));
|
||||||
qheader.setRawHeader("User-Agent", UserAgent);
|
qheader.setRawHeader("User-Agent", UserAgent);
|
||||||
qheader.setRawHeader("Accept", "*/*");
|
qheader.setRawHeader("Accept", "*/*");
|
||||||
|
@ -460,30 +460,6 @@ QString UrlFactory::MakeImageUrl(const MapType::Types &type, const Point &pos, c
|
|||||||
//http://dc5.maps.lt/cache/mapslt_ortofoto_overlay/map/_alllayers/L01/R00000013/C0000001d.png
|
//http://dc5.maps.lt/cache/mapslt_ortofoto_overlay/map/_alllayers/L01/R00000013/C0000001d.png
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case MapType::PergoTurkeyMap:
|
|
||||||
{
|
|
||||||
// http://{domain}/{layerName}/{zoomLevel}/{first3LetterOfTileX}/{second3LetterOfTileX}/{third3LetterOfTileX}/{first3LetterOfTileY}/{second3LetterOfTileY}/{third3LetterOfTileXY}.png
|
|
||||||
|
|
||||||
// http://map3.pergo.com.tr/tile/00/000/000/001/000/000/000.png
|
|
||||||
// That means: Zoom Level: 0 TileX: 1 TileY: 0
|
|
||||||
|
|
||||||
// http://domain/tile/14/000/019/371/000/011/825.png
|
|
||||||
// That means: Zoom Level: 14 TileX: 19371 TileY:11825
|
|
||||||
|
|
||||||
// string x = pos.X().ToString("000000000").Insert(3, "/").Insert(7, "/"); // - 000/000/001
|
|
||||||
// string y = pos.Y().ToString("000000000").Insert(3, "/").Insert(7, "/"); // - 000/000/000
|
|
||||||
QString x = QString("%1").arg(QString::number(pos.X()), 9, (QChar)'0');
|
|
||||||
x.insert(3, "/").insert(7, "/");
|
|
||||||
QString y = QString("%1").arg(QString::number(pos.Y()), 9, (QChar)'0');
|
|
||||||
y.insert(3, "/").insert(7, "/");
|
|
||||||
// "http://map03.pergo.com.tr/tile/2/000/000/003/000/000/002.png"
|
|
||||||
// This has changed map03 does not exist. (neither does map3) Servers have changed to map1 and map2 or maps?
|
|
||||||
|
|
||||||
qDebug() << QString("http://maps.pergo.com.tr/tile/%1/%2/%3.png").arg(zoom, 2, 10, (QChar)'0').arg(x).arg(y);
|
|
||||||
return QString("http://maps.pergo.com.tr/tile/%1/%2/%3.png").arg(zoom, 2, 10, (QChar)'0').arg(x).arg(y);
|
|
||||||
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case MapType::SigPacSpainMap:
|
case MapType::SigPacSpainMap:
|
||||||
{
|
{
|
||||||
// http://sigpac.magrama.es/fega/h5visor/ is new server location
|
// http://sigpac.magrama.es/fega/h5visor/ is new server location
|
||||||
|
@ -111,11 +111,6 @@ void Core::run()
|
|||||||
do {
|
do {
|
||||||
QByteArray img;
|
QByteArray img;
|
||||||
|
|
||||||
// tile number inversion(BottomLeft -> TopLeft) for pergo maps
|
|
||||||
if (tl == MapType::PergoTurkeyMap) {
|
|
||||||
qDebug() << "inverting tiles for Pergo";
|
|
||||||
img = OPMaps::Instance()->GetImageFrom(tl, Point(task.Pos.X(), maxOfTiles.Height() - task.Pos.Y()), task.Zoom);
|
|
||||||
} else { // ok
|
|
||||||
#ifdef DEBUG_CORE
|
#ifdef DEBUG_CORE
|
||||||
qDebug() << "start getting image" << " ID=" << debug;
|
qDebug() << "start getting image" << " ID=" << debug;
|
||||||
#endif // DEBUG_CORE
|
#endif // DEBUG_CORE
|
||||||
@ -123,7 +118,6 @@ void Core::run()
|
|||||||
#ifdef DEBUG_CORE
|
#ifdef DEBUG_CORE
|
||||||
qDebug() << "Core::run:gotimage size:" << img.count() << " ID=" << debug << " time=" << t.elapsed();
|
qDebug() << "Core::run:gotimage size:" << img.count() << " ID=" << debug << " time=" << t.elapsed();
|
||||||
#endif // DEBUG_CORE
|
#endif // DEBUG_CORE
|
||||||
}
|
|
||||||
|
|
||||||
if (img.length() != 0) {
|
if (img.length() != 0) {
|
||||||
Moverlays.lock();
|
Moverlays.lock();
|
||||||
@ -291,15 +285,6 @@ void Core::SetMapType(const MapType::Types &value)
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case MapType::PergoTurkeyMap:
|
|
||||||
{
|
|
||||||
if (Projection()->Type() != "PlateCarreeProjectionPergo") {
|
|
||||||
SetProjection(new PlateCarreeProjectionPergo());
|
|
||||||
maxzoom = 18;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
|
|
||||||
case MapType::YandexMapRu:
|
case MapType::YandexMapRu:
|
||||||
{
|
{
|
||||||
if (Projection()->Type() != "MercatorProjectionYandex") {
|
if (Projection()->Type() != "MercatorProjectionYandex") {
|
||||||
|
@ -46,7 +46,6 @@
|
|||||||
#include "../internals/projections/mercatorprojection.h"
|
#include "../internals/projections/mercatorprojection.h"
|
||||||
#include "../internals/projections/mercatorprojectionyandex.h"
|
#include "../internals/projections/mercatorprojectionyandex.h"
|
||||||
#include "../internals/projections/platecarreeprojection.h"
|
#include "../internals/projections/platecarreeprojection.h"
|
||||||
#include "../internals/projections/platecarreeprojectionpergo.h"
|
|
||||||
#include "../core/geodecoderstatus.h"
|
#include "../core/geodecoderstatus.h"
|
||||||
#include "../core/opmaps.h"
|
#include "../core/opmaps.h"
|
||||||
#include "../core/diagnostics.h"
|
#include "../core/diagnostics.h"
|
||||||
|
@ -25,11 +25,9 @@ HEADERS += ./projections/lks94projection.h \
|
|||||||
./projections/mercatorprojection.h \
|
./projections/mercatorprojection.h \
|
||||||
./projections/mercatorprojectionyandex.h \
|
./projections/mercatorprojectionyandex.h \
|
||||||
./projections/platecarreeprojection.h \
|
./projections/platecarreeprojection.h \
|
||||||
./projections/platecarreeprojectionpergo.h
|
|
||||||
SOURCES += ./projections/lks94projection.cpp \
|
SOURCES += ./projections/lks94projection.cpp \
|
||||||
./projections/mercatorprojection.cpp \
|
./projections/mercatorprojection.cpp \
|
||||||
./projections/mercatorprojectionyandex.cpp \
|
./projections/mercatorprojectionyandex.cpp \
|
||||||
./projections/platecarreeprojection.cpp \
|
./projections/platecarreeprojection.cpp
|
||||||
./projections/platecarreeprojectionpergo.cpp
|
|
||||||
LIBS += -L../build \
|
LIBS += -L../build \
|
||||||
-lcore
|
-lcore
|
||||||
|
Loading…
x
Reference in New Issue
Block a user