This commit is contained in:
aap 2020-10-24 22:50:52 +02:00
parent edc77742c5
commit ee2a32e142
2 changed files with 6 additions and 1 deletions

View File

@ -427,7 +427,6 @@ bindTexture(uint32 texid)
void void
bindFramebuffer(uint32 fbo) bindFramebuffer(uint32 fbo)
{ {
//glBindFramebuffer(GL_FRAMEBUFFER, fbo);
if(currentFramebuffer != fbo){ if(currentFramebuffer != fbo){
glBindFramebuffer(GL_FRAMEBUFFER, fbo); glBindFramebuffer(GL_FRAMEBUFFER, fbo);
currentFramebuffer = fbo; currentFramebuffer = fbo;

View File

@ -527,6 +527,12 @@ destroyNativeRaster(void *object, int32 offset, int32)
break; break;
case Raster::CAMERA: case Raster::CAMERA:
if(natras->fboMate){
// Break apart from currently associated zbuffer
Gl3Raster *zras = PLUGINOFFSET(Gl3Raster, natras->fboMate, offset);
zras->fboMate = nil;
natras->fboMate = nil;
}
break; break;
} }
natras->texid = 0; natras->texid = 0;