Modified Files:
ephemeris.cxx ephemeris.hxx stardata.cxx: one must not do changes just before checkin, one most not do changes just before checkin, [ last message repeated 100 times ]
This commit is contained in:
@@ -31,7 +31,7 @@
|
|||||||
|
|
||||||
|
|
||||||
// Constructor
|
// Constructor
|
||||||
SGEphemeris::SGEphemeris( const string &path ) {
|
SGEphemeris::SGEphemeris( const std::string &path ) {
|
||||||
our_sun = new Star;
|
our_sun = new Star;
|
||||||
moon = new MoonPos;
|
moon = new MoonPos;
|
||||||
mercury = new Mercury;
|
mercury = new Mercury;
|
||||||
|
|||||||
@@ -29,6 +29,7 @@
|
|||||||
#ifndef _EPHEMERIS_HXX
|
#ifndef _EPHEMERIS_HXX
|
||||||
#define _EPHEMERIS_HXX
|
#define _EPHEMERIS_HXX
|
||||||
|
|
||||||
|
#include <string>
|
||||||
|
|
||||||
#include <simgear/ephemeris/star.hxx>
|
#include <simgear/ephemeris/star.hxx>
|
||||||
#include <simgear/ephemeris/moonpos.hxx>
|
#include <simgear/ephemeris/moonpos.hxx>
|
||||||
@@ -42,6 +43,7 @@
|
|||||||
#include <simgear/ephemeris/stardata.hxx>
|
#include <simgear/ephemeris/stardata.hxx>
|
||||||
|
|
||||||
#include <simgear/math/SGMath.hxx>
|
#include <simgear/math/SGMath.hxx>
|
||||||
|
#include <simgear/misc/sg_path.hxx>
|
||||||
|
|
||||||
|
|
||||||
/** Ephemeris class
|
/** Ephemeris class
|
||||||
@@ -95,7 +97,7 @@ public:
|
|||||||
* calling the constructor you need to provide a path pointing to
|
* calling the constructor you need to provide a path pointing to
|
||||||
* your star database file.
|
* your star database file.
|
||||||
* @param path path to your star database */
|
* @param path path to your star database */
|
||||||
SGEphemeris( const string &path );
|
SGEphemeris( const std::string &path );
|
||||||
|
|
||||||
/** Destructor */
|
/** Destructor */
|
||||||
~SGEphemeris( void );
|
~SGEphemeris( void );
|
||||||
|
|||||||
@@ -51,13 +51,14 @@ bool SGStarData::load( const SGPath& path ) {
|
|||||||
_stars.clear();
|
_stars.clear();
|
||||||
|
|
||||||
// build the full path name to the stars data base file
|
// build the full path name to the stars data base file
|
||||||
path.append( "stars" );
|
SGPath tmp = path;
|
||||||
SG_LOG( SG_ASTRO, SG_INFO, " Loading stars from " << path.str() );
|
tmp.append( "stars" );
|
||||||
|
SG_LOG( SG_ASTRO, SG_INFO, " Loading stars from " << tmp.str() );
|
||||||
|
|
||||||
sg_gzifstream in( path.str() );
|
sg_gzifstream in( tmp.str() );
|
||||||
if ( ! in.is_open() ) {
|
if ( ! in.is_open() ) {
|
||||||
SG_LOG( SG_ASTRO, SG_ALERT, "Cannot open star file: "
|
SG_LOG( SG_ASTRO, SG_ALERT, "Cannot open star file: "
|
||||||
<< path.str() );
|
<< tmp.str() );
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user