Browse Source

minor assert

David Rose 19 years ago
parent
commit
49301354b5
1 changed files with 2 additions and 0 deletions
  1. 2 0
      panda/src/display/graphicsStateGuardian.cxx

+ 2 - 0
panda/src/display/graphicsStateGuardian.cxx

@@ -1955,6 +1955,8 @@ determine_effective_texture() {
     _effective_tex_gen = DCAST(TexGenAttrib, _effective_tex_gen->add_stage
                                (stage, TexGenAttrib::M_constant, TexCoord3f(_current_color_scale[3], 0.0f, 0.0f)));
   }
+
+  nassertv(_effective_texture->get_num_on_stages() <= _max_texture_stages);
 }
 
 ////////////////////////////////////////////////////////////////////