• 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
  • projections
CylindricalProjection_p.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 2009 Patrick Spendrin <ps_ml@gmx.de>
9 // Copyright 2012 Cezar Mocan <mocancezar@gmail.com>
10 //
11 
12 #ifndef MARBLE_CYLINDRICALPROJECTIONPRIVATE_H
13 #define MARBLE_CYLINDRICALPROJECTIONPRIVATE_H
14 
15 #include "AbstractProjection_p.h"
16 
17 
18 namespace Marble
19 {
20 
21 class CylindricalProjection;
22 
23 class CylindricalProjectionPrivate : public AbstractProjectionPrivate
24 {
25  public:
26  explicit CylindricalProjectionPrivate( CylindricalProjection * parent );
27 
28  // This method tessellates a line segment in a way that the line segment
29  // follows great circles. The count parameter specifies the
30  // number of nodes generated for the polygon. If the
31  // clampToGround flag is added the polygon contains count + 2
32  // nodes as the clamped down start and end node get added.
33 
34  int tessellateLineSegment( const GeoDataCoordinates &aCoords,
35  qreal ax, qreal ay,
36  const GeoDataCoordinates &bCoords,
37  qreal bx, qreal by,
38  QVector<QPolygonF*> &polygons,
39  const ViewportParams *viewport,
40  TessellationFlags f = 0,
41  int mirrorCount = 0,
42  qreal repeatDistance = 0 ) const;
43 
44  int processTessellation( const GeoDataCoordinates &previousCoords,
45  const GeoDataCoordinates &currentCoords,
46  int count,
47  QVector<QPolygonF*> &polygons,
48  const ViewportParams *viewport,
49  TessellationFlags f = 0,
50  int mirrorCount = 0,
51  qreal repeatDistance = 0 ) const;
52 
53  static int crossDateLine( const GeoDataCoordinates & aCoord,
54  const GeoDataCoordinates & bCoord,
55  qreal bx,
56  qreal by,
57  QVector<QPolygonF*> &polygons,
58  int mirrorCount = 0,
59  qreal repeatDistance = 0 );
60 
61  bool lineStringToPolygon( const GeoDataLineString &lineString,
62  const ViewportParams *viewport,
63  QVector<QPolygonF*> &polygons ) const;
64 
65  static void translatePolygons( const QVector<QPolygonF *> &polygons,
66  QVector<QPolygonF *> &translatedPolygons,
67  qreal xOffset );
68 
69  void repeatPolygons( const ViewportParams *viewport,
70  QVector<QPolygonF *> &polygons ) const;
71 
72  qreal repeatDistance( const ViewportParams *viewport ) const;
73 
74  CylindricalProjection * const q_ptr;
75  Q_DECLARE_PUBLIC( CylindricalProjection )
76 };
77 
78 } // namespace Marble
79 
80 #endif
Marble::CylindricalProjectionPrivate::lineStringToPolygon
bool lineStringToPolygon(const GeoDataLineString &lineString, const ViewportParams *viewport, QVector< QPolygonF * > &polygons) const
Definition: CylindricalProjection.cpp:264
Marble::AbstractProjectionPrivate
Definition: AbstractProjection_p.h:20
Marble::GeoDataCoordinates
A 3d point representation.
Definition: GeoDataCoordinates.h:52
AbstractProjection_p.h
Marble::CylindricalProjectionPrivate
Definition: CylindricalProjection_p.h:23
Marble::CylindricalProjectionPrivate::repeatPolygons
void repeatPolygons(const ViewportParams *viewport, QVector< QPolygonF * > &polygons) const
Definition: CylindricalProjection.cpp:397
Marble::CylindricalProjectionPrivate::translatePolygons
static void translatePolygons(const QVector< QPolygonF * > &polygons, QVector< QPolygonF * > &translatedPolygons, qreal xOffset)
Definition: CylindricalProjection.cpp:380
Marble::CylindricalProjectionPrivate::repeatDistance
qreal repeatDistance(const ViewportParams *viewport) const
Definition: CylindricalProjection.cpp:464
Marble::CylindricalProjection
A base class for the Equirectangular and Mercator projections in Marble.
Definition: CylindricalProjection.h:33
Marble::CylindricalProjectionPrivate::crossDateLine
static int crossDateLine(const GeoDataCoordinates &aCoord, const GeoDataCoordinates &bCoord, qreal bx, qreal by, QVector< QPolygonF * > &polygons, int mirrorCount=0, qreal repeatDistance=0)
Definition: CylindricalProjection.cpp:239
Marble::CylindricalProjectionPrivate::q_ptr
CylindricalProjection *const q_ptr
Definition: CylindricalProjection_p.h:74
Marble::CylindricalProjectionPrivate::tessellateLineSegment
int tessellateLineSegment(const GeoDataCoordinates &aCoords, qreal ax, qreal ay, const GeoDataCoordinates &bCoords, qreal bx, qreal by, QVector< QPolygonF * > &polygons, const ViewportParams *viewport, TessellationFlags f=0, int mirrorCount=0, qreal repeatDistance=0) const
Definition: CylindricalProjection.cpp:100
Marble::GeoDataLineString
A LineString that allows to store a contiguous set of line segments.
Definition: GeoDataLineString.h:75
Marble::ViewportParams
A public class that controls what is visible in the viewport of a Marble map.
Definition: ViewportParams.h:44
Marble::CylindricalProjectionPrivate::processTessellation
int processTessellation(const GeoDataCoordinates &previousCoords, const GeoDataCoordinates &currentCoords, int count, QVector< QPolygonF * > &polygons, const ViewportParams *viewport, TessellationFlags f=0, int mirrorCount=0, qreal repeatDistance=0) const
Definition: CylindricalProjection.cpp:156
Marble::CylindricalProjectionPrivate::CylindricalProjectionPrivate
CylindricalProjectionPrivate(CylindricalProjection *parent)
Definition: CylindricalProjection.cpp:43
QVector
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:13:38 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