2008-02-28 02:34:29 -07:00
|
|
|
// body.h
|
|
|
|
//
|
|
|
|
// Copyright (C) 2001-2006 Chris Laurel <claurel@shatters.net>
|
|
|
|
//
|
|
|
|
// This program is free software; you can redistribute it and/or
|
|
|
|
// modify it under the terms of the GNU General Public License
|
|
|
|
// as published by the Free Software Foundation; either version 2
|
|
|
|
// of the License, or (at your option) any later version.
|
|
|
|
|
|
|
|
#ifndef _CELENGINE_BODY_H_
|
|
|
|
#define _CELENGINE_BODY_H_
|
|
|
|
|
2020-03-05 00:38:35 -07:00
|
|
|
#include <celengine/astroobj.h>
|
2008-02-28 02:34:29 -07:00
|
|
|
#include <celengine/surface.h>
|
|
|
|
#include <celengine/star.h>
|
|
|
|
#include <celengine/location.h>
|
|
|
|
#include <celengine/timeline.h>
|
2009-11-02 13:30:18 -07:00
|
|
|
#include <celephem/rotation.h>
|
|
|
|
#include <celephem/orbit.h>
|
|
|
|
#include <celutil/utf8.h>
|
2009-07-16 17:37:48 -06:00
|
|
|
#include <Eigen/Core>
|
|
|
|
#include <Eigen/Geometry>
|
2009-11-02 13:30:18 -07:00
|
|
|
#include <string>
|
|
|
|
#include <vector>
|
|
|
|
#include <map>
|
2020-04-03 05:20:23 -06:00
|
|
|
#include <memory>
|
2009-11-02 13:30:18 -07:00
|
|
|
#include <list>
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2018-12-03 09:41:31 -07:00
|
|
|
class Selection;
|
2008-02-28 02:34:29 -07:00
|
|
|
class ReferenceFrame;
|
|
|
|
class Body;
|
|
|
|
class FrameTree;
|
2008-03-20 15:36:17 -06:00
|
|
|
class ReferenceMark;
|
2009-07-22 21:11:40 -06:00
|
|
|
class Atmosphere;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
|
|
|
class PlanetarySystem
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
PlanetarySystem(Body* _primary);
|
|
|
|
PlanetarySystem(Star* _star);
|
2018-09-22 07:13:49 -06:00
|
|
|
~PlanetarySystem() = default;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
|
|
|
Star* getStar() const { return star; };
|
|
|
|
Body* getPrimaryBody() const { return primary; };
|
|
|
|
int getSystemSize() const { return satellites.size(); };
|
|
|
|
Body* getBody(int i) const { return satellites[i]; };
|
2018-03-11 07:12:58 -06:00
|
|
|
|
2008-07-19 15:41:30 -06:00
|
|
|
void addAlias(Body* body, const std::string& alias);
|
|
|
|
void removeAlias(const Body* body, const std::string& alias);
|
2008-02-28 02:34:29 -07:00
|
|
|
void addBody(Body* body);
|
|
|
|
void removeBody(Body* body);
|
|
|
|
void replaceBody(Body* oldBody, Body* newBody);
|
|
|
|
|
|
|
|
int getOrder(const Body* body) const;
|
|
|
|
|
|
|
|
enum TraversalResult
|
|
|
|
{
|
|
|
|
ContinueTraversal = 0,
|
|
|
|
StopTraversal = 1
|
|
|
|
};
|
|
|
|
|
|
|
|
typedef bool (*TraversalFunc)(Body*, void*);
|
|
|
|
|
|
|
|
bool traverse(TraversalFunc, void*) const;
|
|
|
|
Body* find(const std::string&, bool deepSearch = false, bool i18n = false) const;
|
2021-05-12 23:39:40 -06:00
|
|
|
std::vector<std::string> getCompletion(const std::string& _name, bool i18n, bool rec = true) const;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2008-07-19 15:41:30 -06:00
|
|
|
private:
|
2008-07-19 18:26:50 -06:00
|
|
|
void addBodyToNameIndex(Body* body);
|
2008-07-19 15:41:30 -06:00
|
|
|
void removeBodyFromNameIndex(const Body* body);
|
2018-03-11 07:12:58 -06:00
|
|
|
|
2008-02-28 02:34:29 -07:00
|
|
|
private:
|
|
|
|
typedef std::map<std::string, Body*, UTF8StringOrderingPredicate> ObjectIndex;
|
|
|
|
|
|
|
|
private:
|
|
|
|
Star* star;
|
2018-09-22 07:13:49 -06:00
|
|
|
Body* primary{nullptr};
|
2008-02-28 02:34:29 -07:00
|
|
|
std::vector<Body*> satellites;
|
|
|
|
ObjectIndex objectIndex; // index of bodies by name
|
|
|
|
};
|
|
|
|
|
|
|
|
|
2020-04-03 05:20:23 -06:00
|
|
|
class RingRenderData
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
RingRenderData() = default;
|
|
|
|
virtual ~RingRenderData() = default;
|
|
|
|
RingRenderData(const RingRenderData&) = delete;
|
|
|
|
RingRenderData(RingRenderData&&) = delete;
|
|
|
|
RingRenderData& operator=(const RingRenderData&) = delete;
|
|
|
|
RingRenderData& operator=(RingRenderData&&) = delete;
|
|
|
|
};
|
|
|
|
|
|
|
|
|
2018-03-11 07:12:58 -06:00
|
|
|
class RingSystem
|
2008-02-28 02:34:29 -07:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
float innerRadius;
|
|
|
|
float outerRadius;
|
|
|
|
Color color;
|
|
|
|
MultiResTexture texture;
|
2020-04-03 05:20:23 -06:00
|
|
|
std::shared_ptr<RingRenderData> renderData;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
|
|
|
RingSystem(float inner, float outer) :
|
2008-03-24 18:23:16 -06:00
|
|
|
innerRadius(inner), outerRadius(outer),
|
|
|
|
#ifdef HDR_COMPRESS
|
|
|
|
color(0.5f, 0.5f, 0.5f),
|
|
|
|
#else
|
|
|
|
color(1.0f, 1.0f, 1.0f),
|
|
|
|
#endif
|
|
|
|
texture()
|
2008-02-28 02:34:29 -07:00
|
|
|
{ };
|
|
|
|
RingSystem(float inner, float outer, Color _color, int _loTexture = -1, int _texture = -1) :
|
|
|
|
innerRadius(inner), outerRadius(outer), color(_color), texture(_loTexture, _texture)
|
|
|
|
{ };
|
|
|
|
RingSystem(float inner, float outer, Color _color, const MultiResTexture& _texture) :
|
|
|
|
innerRadius(inner), outerRadius(outer), color(_color), texture(_texture)
|
|
|
|
{ };
|
|
|
|
};
|
|
|
|
|
|
|
|
|
2020-03-05 00:38:35 -07:00
|
|
|
class Body : public AstroObject
|
2008-02-28 02:34:29 -07:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
Body(PlanetarySystem*, const std::string& name);
|
2018-12-07 11:25:13 -07:00
|
|
|
virtual ~Body();
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2008-04-14 12:48:13 -06:00
|
|
|
// Object class enumeration:
|
|
|
|
// All of these values must be powers of two so that they can
|
|
|
|
// be used in an object type bit mask.
|
|
|
|
//
|
|
|
|
// The values of object class enumerants cannot be modified
|
|
|
|
// without consequence. The object orbit mask is a stored user
|
|
|
|
// setting, so there will be unexpected results when the user
|
|
|
|
// upgrades if the orbit mask values mean something different
|
|
|
|
// in the new version.
|
|
|
|
//
|
|
|
|
// * Planet, Moon, Asteroid, DwarfPlanet, and MinorMoon all behave
|
|
|
|
// essentially the same. They're distinguished from each other for
|
|
|
|
// user convenience, so that it's possible to assign them different
|
|
|
|
// orbit and label colors, and to categorize them in the solar
|
|
|
|
// system browser.
|
|
|
|
//
|
|
|
|
// * Comet is identical to the asteroid class except that comets may
|
|
|
|
// be rendered with dust and ion tails.
|
|
|
|
//
|
|
|
|
// Other classes have different default settings for the properties
|
|
|
|
// Clickable, VisibleAsPoint, Visible, and SecondaryIlluminator. These
|
|
|
|
// defaults are assigned in the ssc file parser and may be overridden
|
|
|
|
// for a particular body.
|
|
|
|
//
|
|
|
|
// * Invisible is used for barycenters and other reference points.
|
|
|
|
// An invisible object is not clickable, visibleAsPoint, visible, or
|
|
|
|
// a secondary illuminator.
|
|
|
|
//
|
|
|
|
// * SurfaceFeature is meant to be used for buildings and landscape.
|
|
|
|
// SurfaceFeatures is clickable and visible, but not visibleAsPoint or
|
|
|
|
// a secondary illuminator.
|
|
|
|
//
|
|
|
|
// * Component should be used for parts of spacecraft or buildings that
|
|
|
|
// are separate ssc objects. A component is clickable and visible, but
|
|
|
|
// not visibleAsPoint or a secondary illuminator.
|
|
|
|
//
|
|
|
|
// * Diffuse is used for gas clouds, dust plumes, and the like. They are
|
|
|
|
// visible, but other properties are false by default. It is expected
|
|
|
|
// that an observer will move through a diffuse object, so there's no
|
|
|
|
// need for any sort of collision detection to be applied.
|
|
|
|
//
|
|
|
|
// * Stellar is a pseudo-class used only for orbit rendering.
|
|
|
|
//
|
|
|
|
// * Barycenter and SmallBody are not used currently. Invisible is used
|
|
|
|
// instead of barycenter.
|
2008-02-28 02:34:29 -07:00
|
|
|
enum
|
|
|
|
{
|
2008-04-14 12:48:13 -06:00
|
|
|
Planet = 0x01,
|
|
|
|
Moon = 0x02,
|
|
|
|
Asteroid = 0x04,
|
|
|
|
Comet = 0x08,
|
|
|
|
Spacecraft = 0x10,
|
|
|
|
Invisible = 0x20,
|
|
|
|
Barycenter = 0x40, // Not used (invisible is used instead)
|
|
|
|
SmallBody = 0x80, // Not used
|
|
|
|
DwarfPlanet = 0x100,
|
|
|
|
Stellar = 0x200, // only used for orbit mask
|
|
|
|
SurfaceFeature = 0x400,
|
|
|
|
Component = 0x800,
|
|
|
|
MinorMoon = 0x1000,
|
|
|
|
Diffuse = 0x2000,
|
|
|
|
Unknown = 0x10000,
|
2008-02-28 02:34:29 -07:00
|
|
|
};
|
|
|
|
|
|
|
|
enum VisibilityPolicy
|
|
|
|
{
|
|
|
|
NeverVisible = 0,
|
|
|
|
UseClassVisibility = 1,
|
|
|
|
AlwaysVisible = 2,
|
|
|
|
};
|
|
|
|
|
2018-12-03 09:41:31 -07:00
|
|
|
virtual Selection toSelection();
|
2008-03-20 15:36:17 -06:00
|
|
|
void setDefaultProperties();
|
|
|
|
|
2008-02-28 02:34:29 -07:00
|
|
|
PlanetarySystem* getSystem() const;
|
2008-07-19 15:41:30 -06:00
|
|
|
const std::vector<std::string>& getNames() const;
|
2008-02-28 02:34:29 -07:00
|
|
|
std::string getName(bool i18n = false) const;
|
2008-07-19 15:41:30 -06:00
|
|
|
std::string getLocalizedName() const;
|
|
|
|
bool hasLocalizedName() const;
|
|
|
|
void addAlias(const std::string& alias);
|
2008-02-28 02:34:29 -07:00
|
|
|
|
|
|
|
void setTimeline(Timeline* timeline);
|
|
|
|
const Timeline* getTimeline() const;
|
|
|
|
|
|
|
|
FrameTree* getFrameTree() const;
|
|
|
|
FrameTree* getOrCreateFrameTree();
|
|
|
|
|
2019-08-05 11:31:02 -06:00
|
|
|
const ReferenceFrame::SharedConstPtr& getOrbitFrame(double tdb) const;
|
2008-02-28 02:34:29 -07:00
|
|
|
const Orbit* getOrbit(double tdb) const;
|
2019-08-05 11:31:02 -06:00
|
|
|
const ReferenceFrame::SharedConstPtr& getBodyFrame(double tdb) const;
|
2008-02-28 02:34:29 -07:00
|
|
|
const RotationModel* getRotationModel(double tdb) const;
|
2018-03-11 07:12:58 -06:00
|
|
|
|
2008-02-28 02:34:29 -07:00
|
|
|
// Size methods
|
2009-07-16 17:37:48 -06:00
|
|
|
void setSemiAxes(const Eigen::Vector3f&);
|
|
|
|
Eigen::Vector3f getSemiAxes() const;
|
2008-02-28 02:34:29 -07:00
|
|
|
float getRadius() const;
|
|
|
|
|
|
|
|
bool isSphere() const;
|
|
|
|
bool isEllipsoid() const;
|
|
|
|
|
|
|
|
float getMass() const;
|
|
|
|
void setMass(float);
|
2018-12-09 14:27:38 -07:00
|
|
|
float getDensity() const;
|
|
|
|
void setDensity(float);
|
|
|
|
|
|
|
|
// Albedo functions and temperature
|
2021-03-08 03:36:31 -07:00
|
|
|
[[deprecated]] float getAlbedo() const;
|
|
|
|
[[deprecated]] void setAlbedo(float);
|
2018-12-09 14:27:38 -07:00
|
|
|
float getGeomAlbedo() const;
|
|
|
|
void setGeomAlbedo(float);
|
|
|
|
float getBondAlbedo() const;
|
|
|
|
void setBondAlbedo(float);
|
2021-03-08 03:36:31 -07:00
|
|
|
float getReflectivity() const;
|
|
|
|
void setReflectivity(float);
|
2018-12-09 14:27:38 -07:00
|
|
|
float getTemperature(double t = 0) const;
|
|
|
|
void setTemperature(float);
|
|
|
|
float getTempDiscrepancy() const;
|
|
|
|
void setTempDiscrepancy(float);
|
|
|
|
|
2008-02-28 02:34:29 -07:00
|
|
|
int getClassification() const;
|
|
|
|
void setClassification(int);
|
2018-11-19 10:54:32 -07:00
|
|
|
const std::string& getInfoURL() const;
|
2008-02-28 02:34:29 -07:00
|
|
|
void setInfoURL(const std::string&);
|
|
|
|
|
|
|
|
PlanetarySystem* getSatellites() const;
|
|
|
|
void setSatellites(PlanetarySystem*);
|
|
|
|
|
|
|
|
float getBoundingRadius() const;
|
2008-04-03 11:46:45 -06:00
|
|
|
float getCullingRadius() const;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
|
|
|
RingSystem* getRings() const;
|
|
|
|
void setRings(const RingSystem&);
|
|
|
|
const Atmosphere* getAtmosphere() const;
|
|
|
|
Atmosphere* getAtmosphere();
|
|
|
|
void setAtmosphere(const Atmosphere&);
|
|
|
|
|
2008-09-22 14:59:04 -06:00
|
|
|
ResourceHandle getGeometry() const { return geometry; }
|
2008-07-23 15:54:53 -06:00
|
|
|
void setGeometry(ResourceHandle);
|
2009-07-16 17:37:48 -06:00
|
|
|
Eigen::Quaternionf getGeometryOrientation() const;
|
|
|
|
void setGeometryOrientation(const Eigen::Quaternionf& orientation);
|
2008-09-22 14:59:04 -06:00
|
|
|
float getGeometryScale() const { return geometryScale; }
|
|
|
|
void setGeometryScale(float scale);
|
|
|
|
|
2008-02-28 02:34:29 -07:00
|
|
|
void setSurface(const Surface&);
|
|
|
|
const Surface& getSurface() const;
|
|
|
|
Surface& getSurface();
|
|
|
|
|
|
|
|
float getLuminosity(const Star& sun,
|
|
|
|
float distanceFromSun) const;
|
|
|
|
float getLuminosity(float sunLuminosity,
|
|
|
|
float distanceFromSun) const;
|
|
|
|
|
|
|
|
float getApparentMagnitude(const Star& sun,
|
|
|
|
float distanceFromSun,
|
|
|
|
float distanceFromViewer) const;
|
|
|
|
float getApparentMagnitude(float sunLuminosity,
|
|
|
|
float distanceFromSun,
|
|
|
|
float distanceFromViewer) const;
|
|
|
|
float getApparentMagnitude(const Star& sun,
|
2009-07-16 17:37:48 -06:00
|
|
|
const Eigen::Vector3d& sunPosition,
|
|
|
|
const Eigen::Vector3d& viewerPosition) const;
|
2008-02-28 02:34:29 -07:00
|
|
|
float getApparentMagnitude(float sunLuminosity,
|
2009-07-16 17:37:48 -06:00
|
|
|
const Eigen::Vector3d& sunPosition,
|
|
|
|
const Eigen::Vector3d& viewerPosition) const;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2008-02-20 19:25:48 -07:00
|
|
|
UniversalCoord getPosition(double tdb) const;
|
2009-07-16 17:37:48 -06:00
|
|
|
Eigen::Quaterniond getOrientation(double tdb) const;
|
|
|
|
Eigen::Vector3d getVelocity(double tdb) const;
|
|
|
|
Eigen::Vector3d getAngularVelocity(double tdb) const;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2009-07-16 17:37:48 -06:00
|
|
|
Eigen::Matrix4d getLocalToAstrocentric(double) const;
|
|
|
|
Eigen::Vector3d getAstrocentricPosition(double) const;
|
|
|
|
Eigen::Quaterniond getEquatorialToBodyFixed(double) const;
|
|
|
|
Eigen::Quaterniond getEclipticToFrame(double) const;
|
|
|
|
Eigen::Quaterniond getEclipticToEquatorial(double) const;
|
|
|
|
Eigen::Quaterniond getEclipticToBodyFixed(double) const;
|
|
|
|
Eigen::Matrix4d getBodyFixedToAstrocentric(double) const;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2009-07-16 17:37:48 -06:00
|
|
|
Eigen::Vector3d planetocentricToCartesian(double lon, double lat, double alt) const;
|
|
|
|
Eigen::Vector3d planetocentricToCartesian(const Eigen::Vector3d& lonLatAlt) const;
|
|
|
|
Eigen::Vector3d cartesianToPlanetocentric(const Eigen::Vector3d& v) const;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2009-07-16 17:37:48 -06:00
|
|
|
Eigen::Vector3d eclipticToPlanetocentric(const Eigen::Vector3d& ecl, double tdb) const;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
|
|
|
bool extant(double) const;
|
|
|
|
void setLifespan(double, double);
|
|
|
|
void getLifespan(double&, double&) const;
|
|
|
|
|
|
|
|
Surface* getAlternateSurface(const std::string&) const;
|
|
|
|
void addAlternateSurface(const std::string&, Surface*);
|
|
|
|
std::vector<std::string>* getAlternateSurfaceNames() const;
|
|
|
|
|
|
|
|
std::vector<Location*>* getLocations() const;
|
|
|
|
void addLocation(Location*);
|
|
|
|
Location* findLocation(const std::string&, bool i18n = false) const;
|
|
|
|
void computeLocations();
|
|
|
|
|
2019-06-17 06:18:47 -06:00
|
|
|
bool isVisible() const { return visible; }
|
2008-02-28 02:34:29 -07:00
|
|
|
void setVisible(bool _visible);
|
2019-06-17 06:18:47 -06:00
|
|
|
bool isClickable() const { return clickable; }
|
2008-02-28 02:34:29 -07:00
|
|
|
void setClickable(bool _clickable);
|
2019-06-17 06:18:47 -06:00
|
|
|
bool isVisibleAsPoint() const { return visibleAsPoint; }
|
2008-02-28 02:34:29 -07:00
|
|
|
void setVisibleAsPoint(bool _visibleAsPoint);
|
2019-06-17 06:18:47 -06:00
|
|
|
bool isOrbitColorOverridden() const { return overrideOrbitColor; }
|
2008-02-28 02:34:29 -07:00
|
|
|
void setOrbitColorOverridden(bool override);
|
2008-04-03 11:46:45 -06:00
|
|
|
bool isSecondaryIlluminator() const { return secondaryIlluminator; }
|
|
|
|
void setSecondaryIlluminator(bool enable);
|
|
|
|
|
2019-06-17 06:18:47 -06:00
|
|
|
bool hasVisibleGeometry() const { return classification != Invisible && visible; }
|
2008-10-01 16:50:38 -06:00
|
|
|
|
2008-02-28 02:34:29 -07:00
|
|
|
VisibilityPolicy getOrbitVisibility() const { return orbitVisibility; }
|
|
|
|
void setOrbitVisibility(VisibilityPolicy _orbitVisibility);
|
|
|
|
|
|
|
|
Color getOrbitColor() const { return orbitColor; }
|
|
|
|
void setOrbitColor(const Color&);
|
|
|
|
|
2019-03-10 16:36:47 -06:00
|
|
|
Color getCometTailColor() const { return cometTailColor; }
|
|
|
|
void setCometTailColor(const Color& c);
|
|
|
|
|
2008-04-03 11:46:45 -06:00
|
|
|
int getOrbitClassification() const;
|
|
|
|
|
2008-02-28 02:34:29 -07:00
|
|
|
enum
|
|
|
|
{
|
|
|
|
BodyAxes = 0x01,
|
|
|
|
FrameAxes = 0x02,
|
|
|
|
LongLatGrid = 0x04,
|
|
|
|
SunDirection = 0x08,
|
|
|
|
VelocityVector = 0x10,
|
|
|
|
};
|
2018-03-11 07:12:58 -06:00
|
|
|
|
2018-07-03 10:52:34 -06:00
|
|
|
bool referenceMarkVisible(uint32_t) const;
|
|
|
|
uint32_t getVisibleReferenceMarks() const;
|
|
|
|
void setVisibleReferenceMarks(uint32_t);
|
2008-03-20 15:36:17 -06:00
|
|
|
void addReferenceMark(ReferenceMark* refMark);
|
|
|
|
void removeReferenceMark(const std::string& tag);
|
|
|
|
ReferenceMark* findReferenceMark(const std::string& tag) const;
|
|
|
|
const std::list<ReferenceMark*>* getReferenceMarks() const;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
|
|
|
Star* getReferenceStar() const;
|
|
|
|
Star* getFrameReferenceStar() const;
|
|
|
|
|
|
|
|
void markChanged();
|
|
|
|
void markUpdated();
|
|
|
|
|
2008-04-03 11:46:45 -06:00
|
|
|
private:
|
2018-09-22 07:13:49 -06:00
|
|
|
void setName(const std::string& name);
|
2008-04-03 11:46:45 -06:00
|
|
|
void recomputeCullingRadius();
|
|
|
|
|
2008-02-28 02:34:29 -07:00
|
|
|
private:
|
2018-09-22 07:13:49 -06:00
|
|
|
std::vector<std::string> names{ 1 };
|
2021-10-18 08:59:35 -06:00
|
|
|
std::string localizedName;
|
2008-02-28 02:34:29 -07:00
|
|
|
|
|
|
|
// Parent in the name hierarchy
|
|
|
|
PlanetarySystem* system;
|
|
|
|
// Children in the name hierarchy
|
2018-09-22 07:13:49 -06:00
|
|
|
PlanetarySystem* satellites{ nullptr };
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2018-09-22 07:13:49 -06:00
|
|
|
Timeline* timeline{ nullptr };
|
2008-02-28 02:34:29 -07:00
|
|
|
// Children in the frame hierarchy
|
2018-09-22 07:13:49 -06:00
|
|
|
FrameTree* frameTree{ nullptr };
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2018-09-22 07:13:49 -06:00
|
|
|
float radius{ 1.0f };
|
2018-10-17 11:28:37 -06:00
|
|
|
Eigen::Vector3f semiAxes{ Eigen::Vector3f::Ones() };
|
2018-09-22 07:13:49 -06:00
|
|
|
float mass{ 0.0f };
|
2018-12-09 14:27:38 -07:00
|
|
|
float density{ 0.0f };
|
|
|
|
float geomAlbedo{ 0.5f };
|
|
|
|
float bondAlbedo{ 0.5f };
|
2021-03-08 03:36:31 -07:00
|
|
|
float reflectivity{ 0.5f };
|
2018-12-09 14:27:38 -07:00
|
|
|
float temperature{ 0.0f };
|
|
|
|
float tempDiscrepancy{ 0.0f };
|
|
|
|
|
2018-09-22 07:13:49 -06:00
|
|
|
Eigen::Quaternionf geometryOrientation{ Eigen::Quaternionf::Identity() };
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2018-09-22 07:13:49 -06:00
|
|
|
float cullingRadius{ 0.0f };
|
2008-04-03 11:46:45 -06:00
|
|
|
|
2018-09-22 07:13:49 -06:00
|
|
|
ResourceHandle geometry{ InvalidResource };
|
|
|
|
float geometryScale{ 1.0f };
|
|
|
|
Surface surface{ Color(1.0f, 1.0f, 1.0f) };
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2018-09-22 07:13:49 -06:00
|
|
|
Atmosphere* atmosphere{ nullptr };
|
|
|
|
RingSystem* rings{ nullptr };
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2018-09-22 07:13:49 -06:00
|
|
|
int classification{ Unknown };
|
2008-02-28 02:34:29 -07:00
|
|
|
|
|
|
|
std::string infoURL;
|
|
|
|
|
|
|
|
typedef std::map<std::string, Surface*> AltSurfaceTable;
|
2018-09-22 07:13:49 -06:00
|
|
|
AltSurfaceTable *altSurfaces{ nullptr };
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2018-09-22 07:13:49 -06:00
|
|
|
std::vector<Location*>* locations{ nullptr };
|
|
|
|
mutable bool locationsComputed{ false };
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2018-09-22 07:13:49 -06:00
|
|
|
std::list<ReferenceMark*>* referenceMarks{ nullptr };
|
2008-02-28 02:34:29 -07:00
|
|
|
|
|
|
|
Color orbitColor;
|
2019-03-10 16:36:47 -06:00
|
|
|
Color cometTailColor{ 0.5f, 0.5f, 0.75f };
|
2008-02-28 02:34:29 -07:00
|
|
|
|
2018-09-22 07:13:49 -06:00
|
|
|
bool visible{ true };
|
|
|
|
bool clickable{ true };
|
|
|
|
bool visibleAsPoint{ true };
|
|
|
|
bool overrideOrbitColor{ false };
|
2008-02-28 02:34:29 -07:00
|
|
|
VisibilityPolicy orbitVisibility : 3;
|
2018-09-22 07:13:49 -06:00
|
|
|
bool secondaryIlluminator{ true };
|
2021-10-18 08:59:35 -06:00
|
|
|
bool primaryNameLocalized { false };
|
2008-02-28 02:34:29 -07:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // _CELENGINE_BODY_H_
|