Check for the plib version when using display lists, just to be sure.

This commit is contained in:
ehofman
2004-10-10 19:05:25 +00:00
parent d769a9936b
commit 3a48c3de7a
2 changed files with 5 additions and 2 deletions

View File

@@ -332,9 +332,11 @@ sgLoad3DModel( const string &fg_root, const string &path,
sim_time_sec);
}
#if PLIB_VERSION > 183
if ( model != 0 ) {
makeDList( model );
}
#endif
return alignmainmodel;
}

View File

@@ -177,6 +177,9 @@ bool sgGenTile( const string& path, SGBucket b,
new ssgVtxTable ( GL_TRIANGLE_FAN, vl, nl, tl, cl );
leaf->setState( state );
#if PLIB_VERSION > 183
leaf->makeDList();
#endif
geometry->addKid( leaf );
@@ -448,7 +451,6 @@ bool sgBinObjLoad( const string& path, const bool is_base,
nodes, normals, texcoords,
tris_v[ind], tris_n[ind], tris_tc[ind],
is_base, ground_lights );
if ( use_random_objects ) {
SGMaterial *mat = matlib->find( tri_materials[ind] );
if ( mat == NULL ) {
@@ -467,7 +469,6 @@ bool sgBinObjLoad( const string& path, const bool is_base,
nodes, normals, texcoords,
strips_v[ind], strips_n[ind], strips_tc[ind],
is_base, ground_lights );
if ( use_random_objects ) {
SGMaterial *mat = matlib->find( strip_materials[ind] );
if ( mat == NULL ) {