Stellarium 0.13.3
|
Models a single meteor. More...
#include <Meteor.hpp>
Classes | |
struct | MeteorModel |
Public Types | |
typedef QPair< QString, int > | colorPair |
<colorName, intensity> More... | |
Public Member Functions | |
Meteor (const StelCore *, float v) | |
Create a Meteor object. More... | |
bool | update (double deltaTime) |
Updates the position of the meteor, and expires it if necessary. More... | |
void | draw (const StelCore *core, StelPainter &sPainter) |
Draws the meteor. More... | |
Static Public Member Functions | |
static void | drawTrain (const StelCore *core, StelPainter &sPainter, const MeteorModel &mm, const Mat4d &viewMatrix, const float thickness, const int segments, QList< Vec4f > lineColorArray, QList< Vec4f > trainColorArray) |
Draws the meteor train. (useful to be reused in MeteorShowers plugin) More... | |
static void | drawBolide (const StelCore *core, StelPainter &sPainter, const MeteorModel &mm, const Mat4d &viewMatrix, const float bolideSize) |
Draws the meteor bolide. (useful to be reused in MeteorShowers plugin) More... | |
static void | calculateThickness (const StelCore *core, float &thickness, float &bolideSize) |
Calculates the train thickness and bolide size. More... | |
static bool | updateMeteorModel (double deltaTime, double speed, MeteorModel &mm) |
Updates parameters of meteor model. More... | |
static bool | initMeteorModel (const StelCore *core, const int segments, const Mat4d viewMatrix, MeteorModel &mm) |
Builds Meteor Model. More... | |
static void | buildColorArrays (const int segments, const QList< colorPair > colors, QList< Vec4f > &lineColorArray, QList< Vec4f > &trainColorArray) |
Determine color arrays of line and prism used to draw meteor train. More... | |
Static Public Attributes | |
static StelTextureSP | bolideTexture |
Models a single meteor.
Control of the meteor rate is performed in the MeteorMgr class. Once created, a meteor object only lasts for some amount of time, and then "dies", after which, the update() member returns false.
Definition at line 44 of file Meteor.hpp.
typedef QPair<QString, int> Meteor::colorPair |
<colorName, intensity>
Definition at line 85 of file Meteor.hpp.
Meteor::Meteor | ( | const StelCore * | , |
float | v | ||
) |
Create a Meteor object.
v | the velocity of the meteor in km/s. |
|
static |
Determine color arrays of line and prism used to draw meteor train.
|
static |
Calculates the train thickness and bolide size.
void Meteor::draw | ( | const StelCore * | core, |
StelPainter & | sPainter | ||
) |
Draws the meteor.
|
static |
Draws the meteor bolide. (useful to be reused in MeteorShowers plugin)
|
static |
Draws the meteor train. (useful to be reused in MeteorShowers plugin)
|
static |
Builds Meteor Model.
bool Meteor::update | ( | double | deltaTime | ) |
Updates the position of the meteor, and expires it if necessary.
|
static |
Updates parameters of meteor model.
(useful to be reused in MeteorShowers plugin)