1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2025-01-18 11:52:08 +01:00

Copy only explicitly defined polygon center points

This commit is contained in:
Martin Tůma 2024-12-20 14:41:23 +01:00
parent a97dc3b6c2
commit 001fa34cdd

View File

@ -173,10 +173,13 @@ static bool polygonCb(const MapData::Poly *polygon, void *context)
static bool polygonPointCb(const MapData::Poly *polygon, void *context)
{
QList<MapData::Point> *points = (QList<MapData::Point>*)context;
if (!((polygon->type()>>16 == BUISGL && polygon->label().isEmpty())
|| polygon->type()>>16 == PYLONS))
uint baseType = polygon->type()>>16;
if (!polygon->label().isEmpty() || baseType == TSSLPT || baseType == RCTLPT
|| baseType == I_TRNBSN || polygon->type() == SUBTYPE(I_BERTHS, 6))
points->append(MapData::Point(polygon->type(), polygon->bounds().center(),
polygon->label(), polygon->param()));
return true;
}