1
0
Fork 0

Fix skipping of files when scanning polygons, to match previous behaviour.

This commit is contained in:
James Turner 2011-10-27 17:53:18 +01:00
parent a7054d72b3
commit 4914cb0645

View file

@ -89,8 +89,7 @@ static int actual_load_polys( const SGPath& dir,
TGConstruct& c,
TGClipper& clipper ) {
int counter = 0;
// string base = c.get_bucket().gen_base_path();
//string tile_str = c.get_bucket().gen_index_str();
string tile_str = c.get_bucket().gen_index_str();
simgear::Dir d(dir);
if (!d.exists()) {
@ -99,6 +98,10 @@ static int actual_load_polys( const SGPath& dir,
}
BOOST_FOREACH(const SGPath& p, d.children(simgear::Dir::TYPE_FILE)) {
if (p.file_base() != tile_str) {
continue;
}
string lext = p.complete_lower_extension();
if ((lext == "arr") || (lext == "arr.gz") || (lext == "btg.gz") ||
(lext == "fit") || (lext == "fit.gz") || (lext == "ind"))