• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeedu API Reference
  • KDE Home
  • Contact Us
 

marble

  • sources
  • kde-4.14
  • kdeedu
  • marble
  • src
  • lib
  • marble
  • geodata
  • scene
GeoSceneTiled.h
Go to the documentation of this file.
1 /*
2  This file is part of the Marble Virtual Globe.
3 
4  This program is free software licensed under the GNU LGPL. You can
5  find a copy of this license in LICENSE.txt in the top directory of
6  the source code.
7 
8  Copyright (C) 2008 Torsten Rahn <rahn@kde.org>
9 
10  Copyright (C) 2008 Jens-Michael Hoffmann <jensmh@gmx.de>
11 
12  Copyright 2012 Ander Pijoan <ander.pijoan@deusto.es>
13 */
14 
15 #ifndef MARBLE_GEOSCENETILED_H
16 #define MARBLE_GEOSCENETILED_H
17 
18 #include <QList>
19 #include <QStringList>
20 #include <QUrl>
21 #include <QVector>
22 #include <QSize>
23 
24 #include "GeoSceneAbstractDataset.h"
25 #include "MarbleGlobal.h"
26 
31 /* In order to make Marble able to manage vector tiles,
32  * now there is GeoSceneTiled and then GeoSceneTiled
33  * (for the tag <texture> in dgml) or GeoSceneVectorTile
34  * (for <vectortile>) are created, which inherit from this class */
35 
36 namespace Marble
37 {
38 class Blending;
39 class DownloadPolicy;
40 class ServerLayout;
41 class TileId;
42 
43 class GEODATA_EXPORT GeoSceneTiled : public GeoSceneAbstractDataset
44 {
45  public:
46  enum StorageLayout { Marble, OpenStreetMap, TileMapService };
47  enum Projection { Equirectangular, Mercator };
48 
49  explicit GeoSceneTiled( const QString& name );
50  ~GeoSceneTiled();
51  virtual const char* nodeType() const;
52 
53  QString sourceDir() const;
54  void setSourceDir( const QString& sourceDir );
55 
56  QString installMap() const;
57  void setInstallMap( const QString& installMap );
58 
59  StorageLayout storageLayout() const;
60  void setStorageLayout( const StorageLayout );
61 
62  void setServerLayout( const ServerLayout * );
63  const ServerLayout *serverLayout() const;
64 
65  int levelZeroColumns() const;
66  void setLevelZeroColumns( const int );
67 
68  int levelZeroRows() const;
69  void setLevelZeroRows( const int );
70 
71  bool hasMaximumTileLevel() const;
72  int maximumTileLevel() const;
73  void setMaximumTileLevel( const int );
74 
75  QVector<QUrl> downloadUrls() const;
76 
77  const QSize tileSize() const;
78  void setTileSize( const QSize &tileSize );
79 
80  Projection projection() const;
81  void setProjection( const Projection );
82 
83  QString blending() const;
84  void setBlending( const QString &name );
85 
92  QUrl downloadUrl( const TileId & ) const;
93  void addDownloadUrl( const QUrl & );
94 
95  QString relativeTileFileName( const TileId & ) const;
96 
97  QString themeStr() const;
98 
99  QList<const DownloadPolicy *> downloadPolicies() const;
100  void addDownloadPolicy( const DownloadUsage usage, const int maximumConnections );
101 
102  private:
103  Q_DISABLE_COPY( GeoSceneTiled )
104  QStringList hostNames() const;
105 
106  QString m_sourceDir;
107  QString m_installMap;
108  StorageLayout m_storageLayoutMode;
109  const ServerLayout *m_serverLayout;
110  int m_levelZeroColumns;
111  int m_levelZeroRows;
112  int m_maximumTileLevel;
113  mutable QSize m_tileSize;
114  Projection m_projection;
115  QString m_blending;
116 
118  QVector<QUrl> m_downloadUrls;
119 
121  mutable QVector<QUrl>::const_iterator m_nextUrl;
122  QList<const DownloadPolicy *> m_downloadPolicies;
123 };
124 
125 inline bool GeoSceneTiled::hasMaximumTileLevel() const
126 {
127  return m_maximumTileLevel != -1;
128 }
129 
130 inline QString GeoSceneTiled::blending() const
131 {
132  return m_blending;
133 }
134 
135 inline void GeoSceneTiled::setBlending( const QString &name )
136 {
137  m_blending = name;
138 }
139 
140 }
141 
142 #endif
Marble::DownloadPolicy
Definition: DownloadPolicy.h:55
Marble::DownloadUsage
DownloadUsage
This enum is used to describe the type of download.
Definition: MarbleGlobal.h:164
Marble::GeoSceneTiled::Projection
Projection
Definition: GeoSceneTiled.h:47
Marble::GeoSceneTiled
Definition: GeoSceneTiled.h:43
Marble::GeoSceneAbstractDataset
Contents used inside a layer.
Definition: GeoSceneAbstractDataset.h:37
Marble::Equirectangular
Flat projection ("plate carree")
Definition: MarbleGlobal.h:46
Marble::Mercator
Mercator projection.
Definition: MarbleGlobal.h:47
Marble::GeoSceneTiled::setBlending
void setBlending(const QString &name)
Definition: GeoSceneTiled.h:135
QString
QList
MarbleGlobal.h
Marble::GeoSceneTiled::blending
QString blending() const
Definition: GeoSceneTiled.h:130
QStringList
Marble::ServerLayout
Definition: ServerLayout.h:21
QSize
QUrl
GeoSceneAbstractDataset.h
Marble::TileId
Definition: TileId.h:27
QVector< QUrl >
Marble::Projection
Projection
This enum is used to choose the projection shown in the view.
Definition: MarbleGlobal.h:44
Marble::GeoSceneTiled::StorageLayout
StorageLayout
Definition: GeoSceneTiled.h:46
GEODATA_EXPORT
#define GEODATA_EXPORT
Definition: geodata_export.h:22
usage
void usage(const QString &app)
Definition: merge_ts_po.cpp:16
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:13:39 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

marble

Skip menu "marble"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal