Replaced some debugging structure David inadvertantly removed.
This commit is contained in:
parent
d0eaafb1e1
commit
ac99a82b98
1 changed files with 15 additions and 0 deletions
|
@ -478,8 +478,10 @@ ssgBranch *fgAsciiObjLoad( const string& path, FGTileEntry *t,
|
||||||
string file = path;
|
string file = path;
|
||||||
int pos = file.rfind( "/" );
|
int pos = file.rfind( "/" );
|
||||||
file = file.substr( 0, pos );
|
file = file.substr( 0, pos );
|
||||||
|
// cout << "current file = " << file << endl;
|
||||||
file += "/";
|
file += "/";
|
||||||
file += material;
|
file += material;
|
||||||
|
// cout << "current file = " << file << endl;
|
||||||
if ( ! material_lib.add_item( file ) ) {
|
if ( ! material_lib.add_item( file ) ) {
|
||||||
SG_LOG( SG_TERRAIN, SG_ALERT,
|
SG_LOG( SG_TERRAIN, SG_ALERT,
|
||||||
"Ack! unknown usemtl name = " << material
|
"Ack! unknown usemtl name = " << material
|
||||||
|
@ -502,6 +504,8 @@ ssgBranch *fgAsciiObjLoad( const string& path, FGTileEntry *t,
|
||||||
tex_height = newmat->get_ysize();
|
tex_height = newmat->get_ysize();
|
||||||
state = newmat->get_state();
|
state = newmat->get_state();
|
||||||
coverage = newmat->get_light_coverage();
|
coverage = newmat->get_light_coverage();
|
||||||
|
// cout << "(w) = " << tex_width << " (h) = "
|
||||||
|
// << tex_width << endl;
|
||||||
} else {
|
} else {
|
||||||
coverage = -1;
|
coverage = -1;
|
||||||
}
|
}
|
||||||
|
@ -516,6 +520,8 @@ ssgBranch *fgAsciiObjLoad( const string& path, FGTileEntry *t,
|
||||||
|
|
||||||
in >> token;
|
in >> token;
|
||||||
|
|
||||||
|
// cout << "token = " << token << endl;
|
||||||
|
|
||||||
if ( token == "vn" ) {
|
if ( token == "vn" ) {
|
||||||
// vertex normal
|
// vertex normal
|
||||||
if ( vncount < FG_MAX_NODES ) {
|
if ( vncount < FG_MAX_NODES ) {
|
||||||
|
@ -628,6 +634,10 @@ ssgBranch *fgAsciiObjLoad( const string& path, FGTileEntry *t,
|
||||||
|
|
||||||
in >> n3;
|
in >> n3;
|
||||||
fan_vertices.push_back( n3 );
|
fan_vertices.push_back( n3 );
|
||||||
|
// cout << " triangle = "
|
||||||
|
// << n1 << "," << n2 << "," << n3
|
||||||
|
// << endl;
|
||||||
|
// xglNormal3dv(normals[n3]);
|
||||||
if ( in.get( c ) && c == '/' ) {
|
if ( in.get( c ) && c == '/' ) {
|
||||||
in >> tex;
|
in >> tex;
|
||||||
fan_tex_coords.push_back( tex );
|
fan_tex_coords.push_back( tex );
|
||||||
|
@ -757,8 +767,10 @@ ssgLeaf *gen_leaf( const string& path,
|
||||||
string file = path;
|
string file = path;
|
||||||
int pos = file.rfind( "/" );
|
int pos = file.rfind( "/" );
|
||||||
file = file.substr( 0, pos );
|
file = file.substr( 0, pos );
|
||||||
|
// cout << "current file = " << file << endl;
|
||||||
file += "/";
|
file += "/";
|
||||||
file += material;
|
file += material;
|
||||||
|
// cout << "current file = " << file << endl;
|
||||||
if ( ! material_lib.add_item( file ) ) {
|
if ( ! material_lib.add_item( file ) ) {
|
||||||
SG_LOG( SG_TERRAIN, SG_ALERT,
|
SG_LOG( SG_TERRAIN, SG_ALERT,
|
||||||
"Ack! unknown usemtl name = " << material
|
"Ack! unknown usemtl name = " << material
|
||||||
|
@ -781,6 +793,8 @@ ssgLeaf *gen_leaf( const string& path,
|
||||||
tex_height = newmat->get_ysize();
|
tex_height = newmat->get_ysize();
|
||||||
state = newmat->get_state();
|
state = newmat->get_state();
|
||||||
coverage = newmat->get_light_coverage();
|
coverage = newmat->get_light_coverage();
|
||||||
|
// cout << "(w) = " << tex_width << " (h) = "
|
||||||
|
// << tex_width << endl;
|
||||||
} else {
|
} else {
|
||||||
coverage = -1;
|
coverage = -1;
|
||||||
}
|
}
|
||||||
|
@ -919,6 +933,7 @@ bool fgBinObjLoad( const string& path, const bool is_base,
|
||||||
group_list pts_v = obj.get_pts_v();
|
group_list pts_v = obj.get_pts_v();
|
||||||
group_list pts_n = obj.get_pts_n();
|
group_list pts_n = obj.get_pts_n();
|
||||||
for ( i = 0; i < (int)pts_v.size(); ++i ) {
|
for ( i = 0; i < (int)pts_v.size(); ++i ) {
|
||||||
|
// cout << "pts_v.size() = " << pts_v.size() << endl;
|
||||||
tmp_mat = pt_materials[i];
|
tmp_mat = pt_materials[i];
|
||||||
if ( tmp_mat.substr(0, 3) == "RWY" ) {
|
if ( tmp_mat.substr(0, 3) == "RWY" ) {
|
||||||
material = "LIGHTS";
|
material = "LIGHTS";
|
||||||
|
|
Loading…
Add table
Reference in a new issue