Stellarium 0.11.4
Home · All Namespaces · All Classes · Functions · Coding Style · Scripting · Plugins · File Structure

core/modules/MinorPlanet.hpp

00001 /*
00002  * Stellarium
00003  * Copyright (C) 2010 Bogdan Marinov
00004  *
00005  * This program is free software; you can redistribute it and/or
00006  * modify it under the terms of the GNU General Public License
00007  * as published by the Free Software Foundation; either version 2
00008  * of the License, or (at your option) any later version.
00009  *
00010  * This program is distributed in the hope that it will be useful,
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013  * GNU General Public License for more details.
00014  *
00015  * You should have received a copy of the GNU General Public License
00016  * along with this program; if not, write to the Free Software
00017  * Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA  02110-1335, USA.
00018  */
00019  
00020 #ifndef _MINOR_PLANET_HPP_
00021 #define _MINOR_PLANET_HPP_
00022 
00023 #include "Planet.hpp"
00024 
00037 class MinorPlanet : public Planet
00038 {
00039 public:
00040     MinorPlanet(const QString& englishName,
00041            int flagLighting,
00042            double radius,
00043            double oblateness,
00044            Vec3f color,
00045            float albedo,
00046            const QString& texMapName,
00047            posFuncType _coordFunc,
00048            void* userDataPtr,
00049            OsculatingFunctType *osculatingFunc,
00050            bool closeOrbit,
00051            bool hidden);
00052 
00053     ~MinorPlanet();
00054 
00055     //Inherited from StelObject via Planet
00068     virtual QString getInfoString(const StelCore *core, const InfoStringGroup &flags) const;
00069     //The Comet class inherits the "Planet" type because the SolarSystem class
00070     //was not designed to handle different types of objects.
00071     // \todo Decide if this is going to be "MinorPlanet" or "Asteroid"
00072     //virtual QString getType() const {return "MinorPlanet";}
00073     virtual float getVMagnitude(const StelCore* core, bool withExtinction=false) const;
00076     virtual void translateName(StelTranslator& trans);
00077 
00083     void setMinorPlanetNumber(int number);
00084 
00090     void setProvisionalDesignation(QString designation);
00091 
00092 
00097     void setAbsoluteMagnitudeAndSlope(double magnitude, double slope);
00098 
00102     static QString renderProvisionalDesignationinHtml(QString plainText);
00103 
00105     void setSemiMajorAxis(double value);
00106 
00107 private:
00108     int minorPlanetNumber;
00109     double absoluteMagnitude;
00110     double slopeParameter;
00111     double semiMajorAxis;
00112 
00113     bool nameIsProvisionalDesignation;
00114     QString provisionalDesignationHtml;
00115     QString properName;
00116 };
00117 
00118 #endif //_MINOR_PLANET_HPP_
Generated on Sat Aug 25 22:13:29 2012 for Stellarium by  doxygen 1.6.3