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

kstars

  • sources
  • kde-4.12
  • kdeedu
  • kstars
  • kstars
  • skyobjects
ksmoon.h
Go to the documentation of this file.
1 /***************************************************************************
2  ksmoon.h - K Desktop Planetarium
3  -------------------
4  begin : Sun Aug 26 2001
5  copyright : (C) 2001 by Jason Harris
6  email : kstars@30doradus.org
7  ***************************************************************************/
8 
9 /***************************************************************************
10  * *
11  * This program is free software; you can redistribute it and/or modify *
12  * it under the terms of the GNU General Public License as published by *
13  * the Free Software Foundation; either version 2 of the License, or *
14  * (at your option) any later version. *
15  * *
16  ***************************************************************************/
17 
18 #ifndef KSMOON_H_
19 #define KSMOON_H_
20 
21 #include "ksplanetbase.h"
22 #include "dms.h"
23 
34 class KSSun;
35 
36 class KSMoon : public KSPlanetBase {
37 public:
39  KSMoon();
41  KSMoon(const KSMoon& o);
42 
43  virtual KSMoon* clone() const;
44  virtual SkyObject::UID getUID() const;
45 
47  ~KSMoon();
48 
55  virtual void findPhase( const KSSun *Sun = 0 );
56 
58  double illum() const { return 0.5*(1.0 - cos( Phase * dms::PI / 180.0 ) ); }
59 
61  QString phaseName() const;
62 
64  virtual bool loadData();
65 
67  inline short int getIPhase() { return iPhase; }
68 
81  virtual bool findGeocentricPosition( const KSNumbers *num, const KSPlanetBase* );
82 
83 private:
84  virtual void initPopupMenu( KSPopupMenu* pmenu );
85  virtual void findMagnitude(const KSNumbers*);
86 
87  static bool data_loaded;
88  static int instance_count;
89 
97  struct MoonLRData {
98  int nd;
99  int nm;
100  int nm1;
101  int nf;
102  double Li;
103  double Ri;
104  };
105 
106  static QList<MoonLRData> LRData;
107 
115  struct MoonBData {
116  int nd;
117  int nm;
118  int nm1;
119  int nf;
120  double Bi;
121  };
122 
123  static QList<MoonBData> BData;
124  unsigned int iPhase;
125 };
126 
127 #endif
KSPlanetBase::findPhase
virtual void findPhase()
Determine the phase of the planet.
Definition: ksplanetbase.cpp:277
KSMoon::illum
double illum() const
Definition: ksmoon.h:58
ksplanetbase.h
KSPopupMenu
The KStars Popup Menu.
Definition: kspopupmenu.h:43
KSSun
Child class of KSPlanetBase; encapsulates information about the Sun.
Definition: kssun.h:31
KSMoon::~KSMoon
~KSMoon()
Destructor (empty).
Definition: ksmoon.cpp:84
dms.h
KSPlanetBase::Phase
double Phase
Definition: ksplanetbase.h:244
KSMoon::getUID
virtual SkyObject::UID getUID() const
Return UID for object.
Definition: ksmoon.cpp:281
SkyObject::UID
qint64 UID
Type for Unique object IDenticator.
Definition: skyobject.h:53
KSMoon::getIPhase
short int getIPhase()
Definition: ksmoon.h:67
KSMoon::loadData
virtual bool loadData()
reimplemented from KSPlanetBase
Definition: ksmoon.cpp:99
KSMoon::clone
virtual KSMoon * clone() const
Create copy of object.
Definition: ksmoon.cpp:79
KSMoon::phaseName
QString phaseName() const
Definition: ksmoon.cpp:256
KSNumbers
There are several time-dependent values used in position calculations, that are not specific to an ob...
Definition: ksnumbers.h:43
KSMoon
A subclass of SkyObject that provides information needed for the Moon.
Definition: ksmoon.h:36
PI
#define PI
Definition: satellite.cpp:43
KSPlanetBase
A subclass of TrailObject that provides additional information needed for most solar system objects...
Definition: ksplanetbase.h:63
KSMoon::KSMoon
KSMoon()
Default constructor.
Definition: ksmoon.cpp:65
KSMoon::findGeocentricPosition
virtual bool findGeocentricPosition(const KSNumbers *num, const KSPlanetBase *)
Reimplemented from KSPlanetBase, this function employs unique algorithms for estimating the lunar coo...
Definition: ksmoon.cpp:147
QList
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:36:20 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kstars

Skip menu "kstars"
  • 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
  • kstars
  • libkdeedu
  •   keduvocdocument
  • 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