1
0
Fork 0

Patch from Dave Luff:

Your 3D models cause a stackdump when the base is separate from the
root.  I've attached a patched newmat.cxx - you may want to test it
before committing!
This commit is contained in:
david 2002-07-31 18:44:30 +00:00
parent a5f251a5de
commit 4cb99e05ad

View file

@ -153,11 +153,20 @@ FGNewMat::Object::load_models () const
{
// Load model only on demand
if (!_models_loaded) {
for (unsigned int i = 0; i < _paths.size(); i++) {
for (int i = 0; i < _paths.size(); i++) {
// Original
// SGPath path = globals->get_fg_root();
// path.append(_paths[i]);
// ssgTexturePath((char *)path.dir().c_str());
// ssgEntity * entity = load_object((char *)path.c_str());
// DCL
SGPath path = globals->get_fg_root();
SGPath modelPath = _paths[i];
path.append(_paths[i]);
ssgTexturePath((char *)path.dir().c_str());
ssgEntity * entity = load_object((char *)path.c_str());
ssgEntity * entity = load_object((char *)modelPath.c_str());
if (entity != 0) {
// entity->ref();
float ranges[] = {0, _range_m};