File indexing completed on 2024-05-05 07:50:01
0001 // SPDX-License-Identifier: LGPL-2.1-or-later 0002 0003 #ifndef MARBLE_TILECOORDSPYRAMID_H 0004 #define MARBLE_TILECOORDSPYRAMID_H 0005 0006 #include <QtGlobal> 0007 #include "marble_export.h" 0008 0009 class QRect; 0010 0011 namespace Marble 0012 { 0013 0014 class MARBLE_EXPORT TileCoordsPyramid 0015 { 0016 public: 0017 TileCoordsPyramid( int const topLevel, int const bottomLevel ); 0018 TileCoordsPyramid( TileCoordsPyramid const & other ); 0019 TileCoordsPyramid(); 0020 TileCoordsPyramid & operator=( TileCoordsPyramid const & rhs ); 0021 ~TileCoordsPyramid(); 0022 0023 int topLevel() const; 0024 int bottomLevel() const; 0025 void setBottomLevelCoords( QRect const & coords ); 0026 QRect coords( int const level ) const; 0027 0028 void setValidTileLevels( const QVector<int> validLevels ); 0029 QVector<int> validTileLevels(); 0030 0031 /** 0032 * @brief returns the number of tiles covered by one pyramid 0033 **/ 0034 qint64 tilesCount() const; 0035 0036 private: 0037 void swap( TileCoordsPyramid & other ); 0038 class Private; 0039 Private * d; // not const, needs to be swapable 0040 }; 0041 0042 } 0043 0044 #endif