Fix OpenGL error when generating radiance
This commit is contained in:
parent
c79ec3951b
commit
2534e28918
|
@ -2177,7 +2177,7 @@ void RasterizerStorageGLES3::sky_set_texture(RID p_sky, RID p_panorama, int p_ra
|
|||
}
|
||||
|
||||
glBindFramebuffer(GL_DRAW_FRAMEBUFFER, tmp_fb);
|
||||
glFramebufferTextureLayer(GL_DRAW_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, sky->radiance, 0, lod);
|
||||
glFramebufferTexture2D(GL_DRAW_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, sky->radiance, lod);
|
||||
glBindFramebuffer(GL_READ_FRAMEBUFFER, tmp_fb2);
|
||||
glReadBuffer(GL_COLOR_ATTACHMENT0);
|
||||
glBlitFramebuffer(0, 0, size, size * 2, 0, 0, size, size * 2, GL_COLOR_BUFFER_BIT, GL_NEAREST);
|
||||
|
|
Loading…
Reference in New Issue