mirror of
https://github.com/tumic0/GPXSee.git
synced 2025-04-20 12:19:11 +02:00
Compare commits
No commits in common. "67b91f62a0317a49174b0b8435a564d4a182ef6e" and "7f20e2e307a2a62f49f15eddd4b773a6b1ff5d09" have entirely different histories.
67b91f62a0
...
7f20e2e307
@ -206,7 +206,6 @@
|
||||
<file alias="kelp.png">icons/map/marine/kelp.png</file>
|
||||
<file alias="eddies.png">icons/map/marine/eddies.png</file>
|
||||
<file alias="dome.png">icons/map/marine/dome.png</file>
|
||||
<file alias="radar-reflector.png">icons/map/marine/radar-reflector.png</file>
|
||||
</qresource>
|
||||
|
||||
<!-- Patterns (Mapsforge) -->
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 236 B |
@ -63,17 +63,16 @@ static QMap<uint,uint> orderMapInit()
|
||||
map.insert(TYPE(PILPNT), 34);
|
||||
map.insert(TYPE(ACHBRT), 35);
|
||||
map.insert(TYPE(I_ACHBRT), 35);
|
||||
map.insert(TYPE(RADRFL), 36);
|
||||
map.insert(TYPE(CRANES), 37);
|
||||
map.insert(TYPE(I_CRANES), 37);
|
||||
map.insert(TYPE(I_WTWGAG), 38);
|
||||
map.insert(TYPE(PYLONS), 39);
|
||||
map.insert(TYPE(SLCONS), 40);
|
||||
map.insert(TYPE(LNDMRK), 41);
|
||||
map.insert(TYPE(SILTNK), 42);
|
||||
map.insert(TYPE(LNDELV), 43);
|
||||
map.insert(TYPE(SMCFAC), 44);
|
||||
map.insert(TYPE(BUISGL), 45);
|
||||
map.insert(TYPE(CRANES), 36);
|
||||
map.insert(TYPE(I_CRANES), 36);
|
||||
map.insert(TYPE(I_WTWGAG), 37);
|
||||
map.insert(TYPE(PYLONS), 38);
|
||||
map.insert(TYPE(SLCONS), 39);
|
||||
map.insert(TYPE(LNDMRK), 40);
|
||||
map.insert(TYPE(SILTNK), 41);
|
||||
map.insert(TYPE(LNDELV), 42);
|
||||
map.insert(TYPE(SMCFAC), 43);
|
||||
map.insert(TYPE(BUISGL), 44);
|
||||
|
||||
map.insert(TYPE(I_DISMAR), 0xFFFFFFFE);
|
||||
map.insert(TYPE(SOUNDG), 0xFFFFFFFF);
|
||||
@ -286,8 +285,7 @@ MapData::Point::Point(uint type, const Coordinates &c, const QString &label,
|
||||
else
|
||||
_label += "\n(" + QString::fromLatin1(params.at(0))
|
||||
+ "\xE2\x80\x89m)";
|
||||
} else if ((type == TYPE(TSSLPT) || type == TYPE(RCTLPT)) && params.size())
|
||||
_param = QVariant(params.at(0).toDouble());
|
||||
}
|
||||
}
|
||||
|
||||
MapData::Poly::Poly(uint type, const Polygon &path, const QString &label,
|
||||
@ -295,7 +293,7 @@ MapData::Poly::Poly(uint type, const Polygon &path, const QString &label,
|
||||
{
|
||||
if (type == TYPE(DEPARE) && params.size())
|
||||
_type = SUBTYPE(DEPARE, depthLevel(params.at(0)));
|
||||
else if ((type == TYPE(TSSLPT) || type == TYPE(RCTLPT)) && params.size())
|
||||
else if (type == TYPE(TSSLPT) && params.size())
|
||||
_param = QVariant(params.at(0).toDouble());
|
||||
else if ((type == TYPE(BRIDGE) || type == TYPE(I_BRIDGE))
|
||||
&& params.size()) {
|
||||
@ -597,9 +595,7 @@ MapData::Attr MapData::pointAttr(const ISO8211::Record &r, uint OBJL)
|
||||
|| (OBJL == RDOCAL && key == ORIENT)
|
||||
|| (OBJL == I_RDOCAL && key == ORIENT)
|
||||
|| (OBJL == CURENT && key == ORIENT)
|
||||
|| (OBJL == LNDELV && key == ELEVAT)
|
||||
|| (OBJL == TSSLPT && key == ORIENT)
|
||||
|| (OBJL == RCTLPT && key == ORIENT))
|
||||
|| (OBJL == LNDELV && key == ELEVAT))
|
||||
params[0] = av.at(1).toByteArray();
|
||||
if ((OBJL == I_RDOCAL && key == COMCHA)
|
||||
|| (OBJL == RDOCAL && key == COMCHA)
|
||||
@ -672,7 +668,6 @@ MapData::Attr MapData::polyAttr(const ISO8211::Record &r, uint OBJL)
|
||||
}
|
||||
|
||||
if ((OBJL == TSSLPT && key == ORIENT)
|
||||
|| (OBJL == RCTLPT && key == ORIENT)
|
||||
|| (OBJL == DEPARE && key == DRVAL1))
|
||||
params[0] = av.at(1).toByteArray();
|
||||
if ((OBJL == BRIDGE && key == VERCLR)
|
||||
|
@ -67,7 +67,6 @@
|
||||
#define PONTON 95
|
||||
#define PRCARE 96
|
||||
#define PYLONS 98
|
||||
#define RADRFL 101
|
||||
#define RADSTA 102
|
||||
#define RTPBCN 103
|
||||
#define RDOCAL 104
|
||||
@ -75,7 +74,6 @@
|
||||
#define RAILWY 106
|
||||
#define RCRTCL 108
|
||||
#define RECTRC 109
|
||||
#define RCTLPT 110
|
||||
#define RSCSTA 111
|
||||
#define RESARE 112
|
||||
#define RIVERS 114
|
||||
|
@ -150,42 +150,19 @@ QPolygonF RasterTile::tsslptArrow(const QPointF &p, qreal angle) const
|
||||
return polygon;
|
||||
}
|
||||
|
||||
static void drawArrow(QPainter *painter, const QPolygonF &polygon, uint type)
|
||||
{
|
||||
if (type>>16 == RCTLPT) {
|
||||
painter->setPen(QPen(tsslptPen, 1, Qt::DashLine));
|
||||
painter->setBrush(Qt::NoBrush);
|
||||
} else {
|
||||
painter->setPen(QPen(tsslptPen, 1));
|
||||
painter->setBrush(QBrush(tsslptBrush));
|
||||
}
|
||||
painter->drawPolygon(polygon);
|
||||
}
|
||||
|
||||
void RasterTile::drawArrows(QPainter *painter,
|
||||
const QList<MapData::Poly> &polygons)
|
||||
{
|
||||
for (int i = 0; i < polygons.size(); i++) {
|
||||
const MapData::Poly &poly = polygons.at(i);
|
||||
|
||||
if (poly.type()>>16 == TSSLPT || poly.type()>>16 == RCTLPT) {
|
||||
if (poly.type()>>16 == TSSLPT) {
|
||||
QPolygonF polygon(tsslptArrow(centroid(poly.path().first()),
|
||||
deg2rad(poly.param().toDouble())));
|
||||
drawArrow(painter, polygon, poly.type());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void RasterTile::drawArrows(QPainter *painter,
|
||||
const QList<MapData::Point> &points)
|
||||
{
|
||||
for (int i = 0; i < points.size(); i++) {
|
||||
const MapData::Point &point = points.at(i);
|
||||
|
||||
if (point.type()>>16 == TSSLPT || point.type()>>16 == RCTLPT) {
|
||||
QPolygonF polygon(tsslptArrow(ll2xy(point.pos()),
|
||||
deg2rad(point.param().toDouble())));
|
||||
drawArrow(painter, polygon, point.type());
|
||||
painter->setPen(QPen(tsslptPen, 1));
|
||||
painter->setBrush(QBrush(tsslptBrush));
|
||||
painter->drawPolygon(polygon);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -423,7 +400,6 @@ void RasterTile::render()
|
||||
drawPolygons(&painter, polygons);
|
||||
drawLines(&painter, lines);
|
||||
drawArrows(&painter, polygons);
|
||||
drawArrows(&painter, points);
|
||||
|
||||
drawTextItems(&painter, lights);
|
||||
drawTextItems(&painter, textItems);
|
||||
|
@ -52,7 +52,6 @@ private:
|
||||
void drawBitmapPath(QPainter *painter, const QImage &img,
|
||||
const Polygon &polygon);
|
||||
void drawArrows(QPainter *painter, const QList<MapData::Poly> &polygons);
|
||||
void drawArrows(QPainter *painter, const QList<MapData::Point> &points);
|
||||
void drawPolygons(QPainter *painter, const QList<MapData::Poly> &polygons);
|
||||
void drawLines(QPainter *painter, const QList<MapData::Line> &lines);
|
||||
void drawTextItems(QPainter *painter, const QList<TextItem*> &textItems);
|
||||
|
@ -335,7 +335,6 @@ void Style::pointStyle(qreal ratio)
|
||||
_points[SUBTYPE(WEDKLP, 0)] = Point(QImage(":/marine/kelp.png"));
|
||||
_points[SUBTYPE(WEDKLP, 1)] = Point(QImage(":/marine/kelp.png"));
|
||||
_points[TYPE(SEAARE)].setHaloColor(QColor());
|
||||
_points[TYPE(RADRFL)] = Point(QImage(":/marine/radar-reflector.png"));
|
||||
|
||||
_points[SUBTYPE(SMCFAC, 7)] = Point(svg2img(":/POI/restaurant-11.svg",
|
||||
ratio), Small);
|
||||
|
Loading…
x
Reference in New Issue
Block a user