I haven't signed up for write access to the CVS dirs, as I probably won't be a regular contributor. However, I've created a patch file based on the Mandrake celestia 1.2.4 patches for the CVS version I checked out on 10/29. It also includes a temporary fix for the ringed planet crashing problem. It's not long, so I'm including it below.
I'm also working on packaging it for RedHat 8.0. If anyone wants the SPEC file when It's ready, or if you want to host the package, let me know via e-mail at
whraven@worldnet.att.net.
Here's the patch:
--- ./src/celengine/render.cpp.orig 2002-10-29 18:30:24.000000000 -0600
+++ ./src/celengine/render.cpp 2002-10-29 18:31:08.000000000 -0600
@@ -380,6 +380,7 @@
DPRINTF(1, "Renderer: multi-texture supported.\n");
glGetIntegerv(GL_MAX_TEXTURE_UNITS_ARB,
(GLint*) &nSimultaneousTextures);
+ nSimultaneousTextures = 1;
}
if (ExtensionSupported("GL_EXT_texture_env_combine"))
{
--- ./src/celestia/celestiacore.cpp.orig 2002-10-29 18:20:45.000000000 -0600
+++ ./src/celestia/celestiacore.cpp 2002-10-29 18:23:18.000000000 -0600
@@ -205,7 +205,7 @@
sim->setFrame(fav.coordSys, sim->getSelection());
}
-void CelestiaCore::addFavorite(string name, string parentFolder, FavoritesList::iterator*iter)
+void CelestiaCore::addFavorite(string const & name, string const & parentFolder, const FavoritesList::iterator* iter)
{
FavoritesList::iterator pos;
if(!iter)
@@ -225,7 +225,7 @@
favorites->insert(pos, fav);
}
-void CelestiaCore::addFavoriteFolder(string name, FavoritesList::iterator* iter)
+void CelestiaCore::addFavoriteFolder(string const & name, const FavoritesList::iterator* iter)
{
FavoritesList::iterator pos;
if(!iter)
@@ -1297,7 +1297,7 @@
{
double distFromSun = body.getHeliocentricPosition(t).distanceFromOrigin();
float planetTemp = sun->getTemperature() *
- (float) (pow(1 - body.getAlbedo(), 0.25) *
+ (float) (pow(1.0 - body.getAlbedo(), 0.25) *
sqrt(sun->getRadius() / (2 * distFromSun)));
overlay << setprecision(0);
overlay << "Temperature: " << planetTemp << " K\n";
--- ./src/celestia/celestiacore.h.orig 2002-10-29 18:23:37.000000000 -0600
+++ ./src/celestia/celestiacore.h 2002-10-29 18:25:40.000000000 -0600
@@ -145,8 +145,8 @@
void readFavoritesFile();
void writeFavoritesFile();
void activateFavorite(FavoritesEntry&);
- void addFavorite(std::string, std::string, FavoritesList::iterator* iter=NULL);
- void addFavoriteFolder(std::string, FavoritesList::iterator* iter=NULL);
+ void addFavorite(std::string const&, std::string const&, const FavoritesList::iterator* iter=NULL);
+ void addFavoriteFolder(std::string const&, const FavoritesList::iterator* iter=NULL);
FavoritesList* getFavorites();
const DestinationList* getDestinations();
--- ./src/celestia/gtkmain.cpp.orig 2002-10-29 18:25:52.000000000 -0600
+++ ./src/celestia/gtkmain.cpp 2002-10-29 18:26:17.000000000 -0600
@@ -43,6 +43,8 @@
#include "celengine/simulation.h"
#include <libgnomeui/gnome-init.h>
+using namespace std;
+
char AppName[] = "Celestia";
--- ./src/buildstardb.cpp.orig 2002-10-29 18:26:26.000000000 -0600
+++ ./src/buildstardb.cpp 2002-10-29 18:29:41.000000000 -0600
@@ -923,7 +923,8 @@
{
MultistarSystem* multiSystem = new MultistarSystem();
multiSystem->nStars = 1;
- multiSystem->stars[0] = iter;
+ // (gb) stars[] could have been an array of iterators
+ multiSystem->stars[0] = &(*iter);
starSystems.insert(MultistarSystemCatalog::value_type(iter->CCDMIdentifier, multiSystem));
}
else
@@ -935,7 +936,7 @@
}
else
{
- multiSystem->stars[multiSystem->nStars] = iter;
+ multiSystem->stars[multiSystem->nStars] = &(*iter);
multiSystem->nStars++;
}
}
@@ -1164,7 +1165,7 @@
for (vector<HipparcosStar>::iterator iter = stars.begin();
iter != stars.end(); iter++)
{
- starIndex.insert(starIndex.end(), iter);
+ starIndex.insert(starIndex.end(), &(*iter));
}
HIPCatalogComparePredicate pred;