X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FObjects%2Fmaterialmgr.cxx;h=30495b8f2a831452171fa987e1bb45887a4c5980;hb=243b73c10b5385374a2d4bdfe48e5a85521c0bb3;hp=ece3f4d65763de2d17ab7a1c045d67ef4cb42f74;hpb=aa27214f65bbb35055863d579fd303ec9ce5ff41;p=flightgear.git diff --git a/src/Objects/materialmgr.cxx b/src/Objects/materialmgr.cxx index ece3f4d65..30495b8f2 100644 --- a/src/Objects/materialmgr.cxx +++ b/src/Objects/materialmgr.cxx @@ -76,6 +76,10 @@ fgMATERIAL_MGR::fgMATERIAL_MGR ( void ) { void FGMaterialSlot::render_fragments() { + FG_LOG( FG_GENERAL, FG_ALERT, + "FGMaterialSlot::render_fragments() is depricated ... " << + "we shouldn't be here!" ); + int tris_rendered = current_view.get_tris_rendered(); // cout << "rendering " + texture_name + " = " << list_size << "\n"; @@ -117,7 +121,7 @@ FGMaterialSlot::render_fragments() // Woohoo!!! We finally get to draw something! // printf(" display_list = %d\n", frag_ptr->display_list); - xglCallList( frag_ptr->display_list ); + // xglCallList( frag_ptr->display_list ); } current_view.set_tris_rendered( tris_rendered ); @@ -135,12 +139,18 @@ fgMATERIAL_MGR::load_lib ( void ) mpath.append( "materials" ); fg_gzifstream in( mpath.str() ); - if ( ! in ) { + if ( ! in.is_open() ) { FG_LOG( FG_GENERAL, FG_ALERT, "Cannot open file: " << mpath.str() ); exit(-1); } +#ifndef __MWERKS__ while ( ! in.eof() ) { +#else + char c = '\0'; + while ( in.get(c) && c != '\0' ) { + in.putback(c); +#endif // printf("%s", line); // strip leading white space and comments