Nebula.hpp   Nebula.hpp 
skipping to change at line 45 skipping to change at line 45
class Nebula : public StelObject class Nebula : public StelObject
{ {
friend class NebulaMgr; friend class NebulaMgr;
//Required for the correct working of the Q_FLAGS macro (which requi res a MOC pass) //Required for the correct working of the Q_FLAGS macro (which requi res a MOC pass)
Q_GADGET Q_GADGET
Q_FLAGS(CatalogGroup) Q_FLAGS(CatalogGroup)
Q_FLAGS(TypeGroup) Q_FLAGS(TypeGroup)
Q_ENUMS(NebulaType) Q_ENUMS(NebulaType)
public: public:
static const QString NEBULA_TYPE;
enum CatalogGroupFlags enum CatalogGroupFlags
{ {
CatNGC = 0x00000001, //!< New General Catalogue (NG C) CatNGC = 0x00000001, //!< New General Catalogue (NG C)
CatIC = 0x00000002, //!< Index Catalogue (IC) CatIC = 0x00000002, //!< Index Catalogue (IC)
CatM = 0x00000004, //!< Messier Catalog (M) CatM = 0x00000004, //!< Messier Catalog (M)
CatC = 0x00000008, //!< Caldwell Catalogue (C) CatC = 0x00000008, //!< Caldwell Catalogue (C)
CatB = 0x00000010, //!< Barnard Catalogue (B) CatB = 0x00000010, //!< Barnard Catalogue (B)
CatSh2 = 0x00000020, //!< Sharpless Catalogue (Sh 2 ) CatSh2 = 0x00000020, //!< Sharpless Catalogue (Sh 2 )
CatLBN = 0x00000040, //!< Lynds' Catalogue of Brigh t Nebulae (LBN) CatLBN = 0x00000040, //!< Lynds' Catalogue of Brigh t Nebulae (LBN)
CatLDN = 0x00000080, //!< Lynds' Catalogue of Dark Nebulae (LDN) CatLDN = 0x00000080, //!< Lynds' Catalogue of Dark Nebulae (LDN)
CatRCW = 0x00000100, //!< A catalogue of Hα-emissio n regions in the southern Milky Way (RCW) CatRCW = 0x00000100, //!< A catalogue of Hα-emissio n regions in the southern Milky Way (RCW)
CatVdB = 0x00000200, //!< Van den Bergh Catalogue o f reflection nebulae (VdB) CatVdB = 0x00000200, //!< Van den Bergh Catalogue o f reflection nebulae (VdB)
CatCr = 0x00000400, //!< Collinder Catalogue (Cr o r Col) CatCr = 0x00000400, //!< Collinder Catalogue (Cr o r Col)
CatMel = 0x00000800, //!< Melotte Catalogue of Deep Sky Objects (Mel) CatMel = 0x00000800, //!< Melotte Catalogue of Deep Sky Objects (Mel)
CatPGC = 0x00001000, //!< HYPERLEDA. I. Catalog of galaxies (PGC) CatPGC = 0x00001000, //!< HYPERLEDA. I. Catalog of galaxies (PGC)
CatUGC = 0x00002000, //!< The Uppsala General Catal ogue of Galaxies CatUGC = 0x00002000, //!< The Uppsala General Catal ogue of Galaxies
CatCed = 0x00004000 //!< Cederblad Catalog of brig CatCed = 0x00004000, //!< Cederblad Catalog of brig
ht diffuse Galactic nebulae (Ced) ht diffuse Galactic nebulae (Ced)
CatArp = 0x00008000, //!< Atlas of Peculiar Galaxie
s (Arp)
CatVV = 0x00010000, //!< Interacting galaxies cata
logue by Vorontsov-Velyaminov (VV)
CatPK = 0x00020000 //!< Catalogue of Galactic Pla
netary Nebulae (PK)
}; };
Q_DECLARE_FLAGS(CatalogGroup, CatalogGroupFlags) Q_DECLARE_FLAGS(CatalogGroup, CatalogGroupFlags)
enum TypeGroupFlags enum TypeGroupFlags
{ {
TypeGalaxies = 0x00000001, //!< Galaxies TypeGalaxies = 0x00000001, //!< Galaxies
TypeActiveGalaxies = 0x00000002, //!< Different Active Galaxies TypeActiveGalaxies = 0x00000002, //!< Different Active Galaxies
TypeInteractingGalaxies = 0x00000004, //!< Interacting Galax ies TypeInteractingGalaxies = 0x00000004, //!< Interacting Galax ies
TypeStarClusters = 0x00000008, //!< Star Clusters TypeStarClusters = 0x00000008, //!< Star Clusters
TypeHydrogenRegions = 0x00000010, //!< Hydrogen Regions TypeHydrogenRegions = 0x00000010, //!< Hydrogen Regions
TypeBrightNebulae = 0x00000020, //!< Bright Nebulae TypeBrightNebulae = 0x00000020, //!< Bright Nebulae
TypeDarkNebulae = 0x00000040, //!< Dark Nebulae TypeDarkNebulae = 0x00000040, //!< Dark Nebulae
TypePlanetaryNebulae = 0x00000080, //!< Planetary Nebulae TypePlanetaryNebulae = 0x00000080, //!< Planetary Nebulae
TypeSupernovaRemnants = 0x00000100, //!< Supernova Remnant s TypeSupernovaRemnants = 0x00000100, //!< Supernova Remnant s
TypeOther = 0x00000200 //!< Other objects TypeOther = 0x00000200 //!< Other objects
}; };
Q_DECLARE_FLAGS(TypeGroup, TypeGroupFlags) Q_DECLARE_FLAGS(TypeGroup, TypeGroupFlags)
//! A pre-defined set of specifiers for the catalogs filter //! A pre-defined set of specifiers for the catalogs filter
static const CatalogGroupFlags AllCatalogs = (CatalogGroupFlags)(Cat NGC|CatIC|CatM|CatC|CatB|CatSh2|CatLBN|CatLDN|CatRCW|CatVdB|CatCr|CatMel|Ca tPGC|CatUGC|CatCed); static const CatalogGroupFlags AllCatalogs = (CatalogGroupFlags)(Cat NGC|CatIC|CatM|CatC|CatB|CatSh2|CatLBN|CatLDN|CatRCW|CatVdB|CatCr|CatMel|Ca tPGC|CatUGC|CatCed|CatArp|CatVV|CatPK);
static const TypeGroupFlags AllTypes = (TypeGroupFlags)(TypeGalaxies |TypeActiveGalaxies|TypeInteractingGalaxies|TypeStarClusters|TypeHydrogenRe gions|TypeBrightNebulae|TypeDarkNebulae|TypePlanetaryNebulae|TypeSupernovaR emnants|TypeOther); static const TypeGroupFlags AllTypes = (TypeGroupFlags)(TypeGalaxies |TypeActiveGalaxies|TypeInteractingGalaxies|TypeStarClusters|TypeHydrogenRe gions|TypeBrightNebulae|TypeDarkNebulae|TypePlanetaryNebulae|TypeSupernovaR emnants|TypeOther);
//! @enum NebulaType Nebula types //! @enum NebulaType Nebula types
enum NebulaType enum NebulaType
{ {
NebGx = 0, //!< Galaxy NebGx = 0, //!< Galaxy
NebAGx = 1, //!< Active galaxy NebAGx = 1, //!< Active galaxy
NebRGx = 2, //!< Radio galaxy NebRGx = 2, //!< Radio galaxy
NebIGx = 3, //!< Interacting galaxy NebIGx = 3, //!< Interacting galaxy
NebQSO = 4, //!< Quasar NebQSO = 4, //!< Quasar
skipping to change at line 144 skipping to change at line 149
//! @return a QString containing an HMTL encoded description of the Nebula. //! @return a QString containing an HMTL encoded description of the Nebula.
virtual QString getInfoString(const StelCore *core, const InfoString Group& flags) const; virtual QString getInfoString(const StelCore *core, const InfoString Group& flags) const;
//! In addition to the entries from StelObject::getInfoMap(), Nebula objects provide //! In addition to the entries from StelObject::getInfoMap(), Nebula objects provide
//! - bmag (photometric B magnitude. 99 if unknown) //! - bmag (photometric B magnitude. 99 if unknown)
//! - morpho (longish description; translated!) //! - morpho (longish description; translated!)
//! - surface-brightness //! - surface-brightness
//! A few entries are optional //! A few entries are optional
//! - bV (B-V index) //! - bV (B-V index)
//! - redshift //! - redshift
virtual QVariantMap getInfoMap(const StelCore *core) const; virtual QVariantMap getInfoMap(const StelCore *core) const;
virtual QString getType() const {return "Nebula";} virtual QString getType() const {return NEBULA_TYPE;}
virtual QString getID() const {return getDSODesignation(); } //this
depends on the currently shown catalog flags, should this be changed?
virtual Vec3d getJ2000EquatorialPos(const StelCore*) const {return X YZ;} virtual Vec3d getJ2000EquatorialPos(const StelCore*) const {return X YZ;}
virtual double getCloseViewFov(const StelCore* core = NULL) const; virtual double getCloseViewFov(const StelCore* core = Q_NULLPTR) con st;
virtual float getVMagnitude(const StelCore* core) const; virtual float getVMagnitude(const StelCore* core) const;
virtual float getSelectPriority(const StelCore* core) const; virtual float getSelectPriority(const StelCore* core) const;
virtual Vec3f getInfoColor() const; virtual Vec3f getInfoColor() const;
virtual QString getNameI18n() const {return nameI18;} virtual QString getNameI18n() const {return nameI18;}
virtual QString getEnglishName() const {return englishName;} virtual QString getEnglishName() const {return englishName;}
QString getEnglishAliases() const; QString getEnglishAliases() const;
QString getI18nAliases() const; QString getI18nAliases() const;
virtual double getAngularSize(const StelCore*) const; virtual double getAngularSize(const StelCore*) const;
virtual SphericalRegionP getRegion() const {return pointRegion;} virtual SphericalRegionP getRegion() const {return pointRegion;}
skipping to change at line 171 skipping to change at line 177
//! Get the printable nebula Type. //! Get the printable nebula Type.
//! @return the nebula type code. //! @return the nebula type code.
QString getTypeString() const; QString getTypeString() const;
NebulaType getDSOType() const {return nType;} NebulaType getDSOType() const {return nType;}
//! Get the printable morphological nebula Type. //! Get the printable morphological nebula Type.
//! @return the nebula morphological type string. //! @return the nebula morphological type string.
QString getMorphologicalTypeString() const; QString getMorphologicalTypeString() const;
float getSurfaceBrightness(const StelCore* core) const; float getSurfaceBrightness(const StelCore* core, bool arcsec=false)
float getSurfaceBrightnessWithExtinction(const StelCore* core) const const;
; float getSurfaceBrightnessWithExtinction(const StelCore* core, bool
arcsec=false) const;
//! Compute an extended object's contrast index
float getContrastIndex(const StelCore* core) const;
//! Get the surface area. //! Get the surface area.
//! @return surface area in square degrees. //! @return surface area in square degrees.
float getSurfaceArea(void) const; float getSurfaceArea(void) const;
void setProperName(QString name) { englishName = name; } void setProperName(QString name) { englishName = name; }
void addNameAlias(QString name) { englishAliases.append(name); } void addNameAlias(QString name) { englishAliases.append(name); }
void removeAllNames() { englishName=""; englishAliases.clear(); } void removeAllNames() { englishName=""; englishAliases.clear(); }
//! Get designation for DSO (with priority: M, C, NGC, IC, B, Sh2, V dB, RCW, LDN, LBN, Cr, Mel, PGC, UGC, Ced) //! Get designation for DSO (with priority: M, C, NGC, IC, B, Sh2, V dB, RCW, LDN, LBN, Cr, Mel, PGC, UGC, Ced)
//! @return a designation //! @return a designation
QString getDSODesignation(); QString getDSODesignation() const;
private: private:
friend struct DrawNebulaFuncObject; friend struct DrawNebulaFuncObject;
//! Translate nebula name using the passed translator //! Translate nebula name using the passed translator
void translateName(const StelTranslator& trans) void translateName(const StelTranslator& trans)
{ {
nameI18 = trans.qtranslate(englishName); nameI18 = trans.qtranslate(englishName);
nameI18Aliases.clear(); nameI18Aliases.clear();
foreach(QString alias, englishAliases) foreach(QString alias, englishAliases)
nameI18Aliases.append(trans.qtranslate(alias)); nameI18Aliases.append(trans.qtranslate(alias));
} }
void readDSO(QDataStream& in); void readDSO(QDataStream& in);
void drawLabel(StelPainter& sPainter, float maxMagLabel); void drawLabel(StelPainter& sPainter, float maxMagLabel) const;
void drawHints(StelPainter& sPainter, float maxMagHints); void drawHints(StelPainter& sPainter, float maxMagHints) const;
bool objectInDisplayedType() const; bool objectInDisplayedType() const;
//! Get the printable description of morphological nebula type. //! Get the printable description of morphological nebula type.
//! @return the nebula morphological type string. //! @return the nebula morphological type string.
QString getMorphologicalTypeDescription() const; QString getMorphologicalTypeDescription() const;
unsigned int DSO_nb; unsigned int DSO_nb;
unsigned int M_nb; // Messier Catalog number unsigned int M_nb; // Messier Catalog number
unsigned int NGC_nb; // New General Catalog number unsigned int NGC_nb; // New General Catalog number
skipping to change at line 224 skipping to change at line 232
unsigned int B_nb; // Barnard Catalog number (Dark Nebu lae) unsigned int B_nb; // Barnard Catalog number (Dark Nebu lae)
unsigned int Sh2_nb; // Sharpless Catalog number (Catalog ue of HII Regions (Sharpless, 1959)) unsigned int Sh2_nb; // Sharpless Catalog number (Catalog ue of HII Regions (Sharpless, 1959))
unsigned int VdB_nb; // Van den Bergh Catalog number (Cat alogue of Reflection Nebulae (Van den Bergh, 1966)) unsigned int VdB_nb; // Van den Bergh Catalog number (Cat alogue of Reflection Nebulae (Van den Bergh, 1966))
unsigned int RCW_nb; // RCW Catalog number (H-α emission regions in Southern Milky Way (Rodgers+, 1960)) unsigned int RCW_nb; // RCW Catalog number (H-α emission regions in Southern Milky Way (Rodgers+, 1960))
unsigned int LDN_nb; // LDN Catalog number (Lynds' Catalo gue of Dark Nebulae (Lynds, 1962)) unsigned int LDN_nb; // LDN Catalog number (Lynds' Catalo gue of Dark Nebulae (Lynds, 1962))
unsigned int LBN_nb; // LBN Catalog number (Lynds' Catalo gue of Bright Nebulae (Lynds, 1965)) unsigned int LBN_nb; // LBN Catalog number (Lynds' Catalo gue of Bright Nebulae (Lynds, 1965))
unsigned int Cr_nb; // Collinder Catalog number unsigned int Cr_nb; // Collinder Catalog number
unsigned int Mel_nb; // Melotte Catalog number unsigned int Mel_nb; // Melotte Catalog number
unsigned int PGC_nb; // PGC number (Catalog of galaxies) unsigned int PGC_nb; // PGC number (Catalog of galaxies)
unsigned int UGC_nb; // UGC number (The Uppsala General C atalogue of Galaxies) unsigned int UGC_nb; // UGC number (The Uppsala General C atalogue of Galaxies)
unsigned int Arp_nb; // Arp number (Atlas of Peculiar Gal
axies (Arp, 1966))
unsigned int VV_nb; // VV number (The Catalogue of Inter
acting Galaxies (Vorontsov-Velyaminov+, 2001))
QString Ced_nb; // Ced number (Cederblad Catalog of bright diffuse Galactic nebulae) QString Ced_nb; // Ced number (Cederblad Catalog of bright diffuse Galactic nebulae)
QString PK_nb; // PK number (Catalogue of Galactic
Planetary Nebulae)
bool withoutID;
QString englishName; // English name QString englishName; // English name
QStringList englishAliases; // English aliases QStringList englishAliases; // English aliases
QString nameI18; // Nebula name QString nameI18; // Nebula name
QStringList nameI18Aliases; // Nebula aliases QStringList nameI18Aliases; // Nebula aliases
QString mTypeString; // Morphological type of object (as string) QString mTypeString; // Morphological type of object (as string)
float bMag; // B magnitude float bMag; // B magnitude
float vMag; // V magnitude. For Dark Nebulae, op acity is stored here. float vMag; // V magnitude. For Dark Nebulae, op acity is stored here.
float majorAxisSize; // Major axis size in degrees float majorAxisSize; // Major axis size in degrees
float minorAxisSize; // Minor axis size in degrees float minorAxisSize; // Minor axis size in degrees
int orientationAngle; // Orientation angle in degrees int orientationAngle; // Orientation angle in degrees
skipping to change at line 296 skipping to change at line 308
static Vec3f protoplanetaryNebulaColor; // The color of prot oplanetary nebula marker texture (NebPPN) static Vec3f protoplanetaryNebulaColor; // The color of prot oplanetary nebula marker texture (NebPPN)
static Vec3f starColor; // The color of star marker texture (NebStar) static Vec3f starColor; // The color of star marker texture (NebStar)
static bool drawHintProportional; // scale hint with nebula size ? static bool drawHintProportional; // scale hint with nebula size ?
static bool surfaceBrightnessUsage; static bool surfaceBrightnessUsage;
static bool designationUsage; static bool designationUsage;
static bool flagUseTypeFilters; static bool flagUseTypeFilters;
static CatalogGroup catalogFilters; static CatalogGroup catalogFilters;
static TypeGroup typeFilters; static TypeGroup typeFilters;
static bool flagUseArcsecSurfaceBrightness;
}; };
Q_DECLARE_OPERATORS_FOR_FLAGS(Nebula::CatalogGroup) Q_DECLARE_OPERATORS_FOR_FLAGS(Nebula::CatalogGroup)
Q_DECLARE_OPERATORS_FOR_FLAGS(Nebula::TypeGroup) Q_DECLARE_OPERATORS_FOR_FLAGS(Nebula::TypeGroup)
#endif // _NEBULA_HPP_ #endif // _NEBULA_HPP_
 End of changes. 11 change blocks. 
11 lines changed or deleted 33 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/