Stellarium 0.14.3
Main Page
Modules
Classes
Core API
File List
plugins
Pulsars
src
Pulsar.hpp
1
/*
2
* Copyright (C) 2012 Alexander Wolf
3
*
4
* This program is free software; you can redistribute it and/or
5
* modify it under the terms of the GNU General Public License
6
* as published by the Free Software Foundation; either version 2
7
* of the License, or (at your option) any later version.
8
*
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
13
*
14
* You should have received a copy of the GNU General Public License
15
* along with this program; if not, write to the Free Software
16
* Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA.
17
*/
18
19
#ifndef _PULSAR_HPP_
20
#define _PULSAR_HPP_ 1
21
22
#include <QVariant>
23
#include <QString>
24
#include <QStringList>
25
#include <QFont>
26
#include <QList>
27
#include <QDateTime>
28
29
#include "StelObject.hpp"
30
#include "
StelTextureTypes.hpp
"
31
#include "StelFader.hpp"
32
33
class
StelPainter
;
34
40
41
class
Pulsar
:
public
StelObject
42
{
43
friend
class
Pulsars
;
44
public
:
46
Pulsar
(
const
QVariantMap& map);
47
~
Pulsar
();
48
51
QVariantMap
getMap
(
void
);
52
54
virtual
QString
getType
(
void
)
const
55
{
56
return
"Pulsar"
;
57
}
58
59
virtual
float
getSelectPriority(
const
StelCore
* core)
const
;
60
64
virtual
QString
getInfoString
(
const
StelCore
* core,
const
InfoStringGroup& flags)
const
;
65
virtual
Vec3f getInfoColor(
void
)
const
;
66
virtual
Vec3d getJ2000EquatorialPos(
const
StelCore
*)
const
67
{
68
return
XYZ;
69
}
71
virtual
float
getVMagnitude
(
const
StelCore
* core)
const
;
72
virtual
float
getVMagnitudeWithExtinction(
const
StelCore
*core)
const
;
74
virtual
double
getAngularSize
(
const
StelCore
* core)
const
;
76
virtual
QString
getNameI18n
(
void
)
const
77
{
78
return
designation;
79
}
81
virtual
QString
getEnglishName
(
void
)
const
82
{
83
return
designation;
84
}
85
86
void
update(
double
deltaTime);
87
88
private
:
89
bool
initialized;
90
91
Vec3d XYZ;
// holds J2000 position
92
93
static
StelTextureSP
hintTexture;
94
static
StelTextureSP
markerTexture;
95
static
bool
distributionMode;
96
static
bool
glitchFlag;
97
static
Vec3f markerColor;
98
static
Vec3f glitchColor;
99
100
void
draw(
StelCore
* core,
StelPainter
*painter);
101
103
QString designation;
104
float
RA;
105
float
DE;
106
float
parallax;
107
double
period;
108
double
frequency;
109
double
pfrequency;
110
double
pderivative;
111
double
dmeasure;
112
double
bperiod;
113
double
eccentricity;
114
float
w50;
115
float
s400;
116
float
s600;
117
float
s1400;
118
float
distance;
119
int
glitch;
120
QString notes;
121
122
LinearFader
labelsFader;
123
127
double
getEdot(
double
p0,
double
p1)
const
;
128
132
double
getP1(
double
p0,
double
f1)
const
;
133
136
QString getPulsarTypeInfoString(QString pcode)
const
;
137
138
};
139
140
#endif // _PULSAR_HPP_
Pulsar::getNameI18n
virtual QString getNameI18n(void) const
Get the localized name of pulsar.
Definition:
Pulsar.hpp:76
LinearFader
Pulsar::getMap
QVariantMap getMap(void)
Get a QVariantMap which describes the pulsar.
StelObject
StelTextureTypes.hpp
Pulsars
Main class of the Pulsars plugin.
Definition:
Pulsars.hpp:73
Pulsar::getAngularSize
virtual double getAngularSize(const StelCore *core) const
Get the angular size of pulsar.
StelCore
Pulsar
A Pulsar object represents one pulsar on the sky.
Definition:
Pulsar.hpp:41
Pulsar::getType
virtual QString getType(void) const
Get the type of object.
Definition:
Pulsar.hpp:54
StelPainter
Pulsar::getVMagnitude
virtual float getVMagnitude(const StelCore *core) const
Get the visual magnitude of pulsar.
StelTextureSP
QSharedPointer< StelTexture > StelTextureSP
Pulsar::getEnglishName
virtual QString getEnglishName(void) const
Get the english name of pulsar.
Definition:
Pulsar.hpp:81
Pulsar::Pulsar
Pulsar(const QVariantMap &map)
Pulsar::getInfoString
virtual QString getInfoString(const StelCore *core, const InfoStringGroup &flags) const
Get an HTML string to describe the object.
Generated on Sun Mar 20 2016 15:06:43 for Stellarium by
1.8.8