Marble

GeoDataImagePyramid.cpp
1 // SPDX-License-Identifier: LGPL-2.1-or-later
2 //
3 // SPDX-FileCopyrightText: 2013 Mohammed Nafees <[email protected]>
4 //
5 
6 #include "GeoDataImagePyramid.h"
7 
8 #include "GeoDataTypes.h"
9 
10 namespace Marble
11 {
12 
13 class GeoDataImagePyramidPrivate
14 {
15 public:
16  GeoDataImagePyramidPrivate();
17 
18  int m_tileSize;
19  int m_maxWidth;
20  int m_maxHeight;
21  GeoDataImagePyramid::GridOrigin m_gridOrigin;
22 };
23 
24 GeoDataImagePyramidPrivate::GeoDataImagePyramidPrivate() :
25  m_tileSize( 256 ),
26  m_maxWidth(),
27  m_maxHeight(),
28  m_gridOrigin()
29 {
30  // nothing to do
31 }
32 
33 GeoDataImagePyramid::GeoDataImagePyramid() : d( new GeoDataImagePyramidPrivate )
34 {
35  // nothing to do
36 }
37 
38 GeoDataImagePyramid::GeoDataImagePyramid( const Marble::GeoDataImagePyramid &other ) :
39  GeoDataObject(), d( new GeoDataImagePyramidPrivate( *other.d ) )
40 {
41  // nothing to do
42 }
43 
44 GeoDataImagePyramid &GeoDataImagePyramid::operator=( const GeoDataImagePyramid &other )
45 {
46  GeoDataObject::operator=( other );
47  *d = *other.d;
48  return *this;
49 }
50 
51 bool GeoDataImagePyramid::operator==( const GeoDataImagePyramid& other ) const
52 {
53  return equals(other) &&
54  d->m_tileSize == other.d->m_tileSize &&
55  d->m_maxWidth == other.d->m_maxWidth &&
56  d->m_maxHeight == other.d->m_maxHeight &&
57  d->m_gridOrigin == other.d->m_gridOrigin;
58 }
59 
60 bool GeoDataImagePyramid::operator!=( const GeoDataImagePyramid& other ) const
61 {
62  return !this->operator==(other);
63 }
64 
65 GeoDataImagePyramid::~GeoDataImagePyramid()
66 {
67  delete d;
68 }
69 
70 const char *GeoDataImagePyramid::nodeType() const
71 {
72  return GeoDataTypes::GeoDataImagePyramidType;
73 }
74 
75 int GeoDataImagePyramid::tileSize() const
76 {
77  return d->m_tileSize;
78 }
79 
80 void GeoDataImagePyramid::setTileSize(int tileSize)
81 {
82  d->m_tileSize = tileSize;
83 }
84 
85 int GeoDataImagePyramid::maxWidth() const
86 {
87  return d->m_maxWidth;
88 }
89 
90 void GeoDataImagePyramid::setMaxWidth(int maxWidth)
91 {
92  d->m_maxWidth = maxWidth;
93 }
94 
95 int GeoDataImagePyramid::maxHeight() const
96 {
97  return d->m_maxHeight;
98 }
99 
100 void GeoDataImagePyramid::setMaxHeight(int maxHeight)
101 {
102  d->m_maxHeight = maxHeight;
103 }
104 
105 GeoDataImagePyramid::GridOrigin GeoDataImagePyramid::gridOrigin() const
106 {
107  return d->m_gridOrigin;
108 }
109 
110 void GeoDataImagePyramid::setGridOrigin(GridOrigin gridOrigin)
111 {
112  d->m_gridOrigin = gridOrigin;
113 }
114 
115 }
bool operator==(const Qt3DRender::QGraphicsApiFilter &reference, const Qt3DRender::QGraphicsApiFilter &sample)
Binds a QML item to a specific geodetic location in screen coordinates.
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Mon Oct 2 2023 03:52:08 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.