Fix crash when no texture is assigned

This commit is contained in:
rdb 2009-02-20 19:56:03 +00:00
parent 02b2b9eacc
commit c0b420a74a
1 changed files with 4 additions and 1 deletions

View File

@ -189,7 +189,10 @@ rebuild_bitplanes() {
// Bind the FBO
Texture *tex = get_texture(0);
if (tex == 0) {
return;
}
if (tex->get_texture_type() != Texture::TT_cube_map) {
if (_fbo == 0) {
glgsg->_glGenFramebuffers(1, &_fbo);