25class Q_POSITIONING_EXPORT QGeoPolygonPrivate :
public QGeoPathPrivateBase
29 QGeoPolygonPrivate(
const QList<QGeoCoordinate> &path);
30 QGeoPolygonPrivate(
const QGeoPolygonPrivate &other);
31 ~QGeoPolygonPrivate();
34 QGeoShapePrivate *clone()
const override;
35 bool isValid()
const override;
36 bool contains(
const QGeoCoordinate &coordinate)
const override;
37 void translate(
double degreesLatitude,
double degreesLongitude) override;
38 bool operator==(
const QGeoShapePrivate &other)
const override;
39 size_t hash(size_t seed)
const override;
42 void markDirty() override;
45 qsizetype holesCount()
const;
46 bool polygonContains(
const QGeoCoordinate &coordinate)
const;
47 const QList<QGeoCoordinate> holePath(qsizetype index)
const;
49 void addHole(
const QList<QGeoCoordinate> &holePath);
50 void removeHole(qsizetype index);
51 void ensureClipperPathUpdated()
const;
54 QList<QList<QGeoCoordinate>> m_holesList;
55 mutable QClipperUtils m_clipperWrapper;
56 mutable double m_leftBoundWrapped = 0.0;
57 mutable std::atomic<
bool> m_clipperDirty =
true;
60class Q_POSITIONING_EXPORT QGeoPolygonPrivateEager final :
public QGeoPolygonPrivate
63 QGeoPolygonPrivateEager();
64 QGeoPolygonPrivateEager(
const QList<QGeoCoordinate> &path);
65 QGeoPolygonPrivateEager(
const QGeoPolygonPrivateEager &other);
66 ~QGeoPolygonPrivateEager();
69 QGeoShapePrivate *clone()
const override;
70 void translate(
double degreesLatitude,
double degreesLongitude) override;
73 void markDirty() override;
74 void addCoordinate(
const QGeoCoordinate &coordinate) override;
79 void updateBoundingBox();
82 QList<
double> m_deltaXs;
static void translatePoly(QList< QGeoCoordinate > &m_path, QList< QList< QGeoCoordinate > > &m_holesList, QGeoRectangle &m_bbox, double degreesLatitude, double degreesLongitude, double m_maxLati, double m_minLati)