mirror of
https://github.com/blender/blender
synced 2026-09-29 04:37:17 +03:00
Fix glCheckFramebufferStatusEXT
This commit is contained in:
parent
9fd3435a93
commit
e68b808564
1 changed files with 3 additions and 3 deletions
|
|
@ -468,14 +468,14 @@ void GPU_framebuffer_blit(GPUFrameBuffer *fb_read, int read_slot, GPUFrameBuffer
|
|||
glFramebufferTexture2D(
|
||||
GL_READ_FRAMEBUFFER, read_attach,
|
||||
GL_TEXTURE_2D, read_bind, 0);
|
||||
BLI_assert(glCheckFramebufferStatusEXT(GL_READ_FRAMEBUFFER) == GL_FRAMEBUFFER_COMPLETE);
|
||||
BLI_assert(glCheckFramebufferStatus(GL_READ_FRAMEBUFFER) == GL_FRAMEBUFFER_COMPLETE);
|
||||
|
||||
/* write into new single-sample buffer */
|
||||
glBindFramebuffer(GL_DRAW_FRAMEBUFFER, fb_write->object);
|
||||
glFramebufferTexture2D(
|
||||
GL_DRAW_FRAMEBUFFER, write_attach,
|
||||
GL_TEXTURE_2D, write_bind, 0);
|
||||
BLI_assert(glCheckFramebufferStatusEXT(GL_DRAW_FRAMEBUFFER) == GL_FRAMEBUFFER_COMPLETE);
|
||||
BLI_assert(glCheckFramebufferStatus(GL_DRAW_FRAMEBUFFER) == GL_FRAMEBUFFER_COMPLETE);
|
||||
|
||||
glBlitFramebuffer(0, 0, read_w, read_h, 0, 0, write_w, write_h, (use_depth) ? GL_DEPTH_BUFFER_BIT : GL_COLOR_BUFFER_BIT, GL_NEAREST);
|
||||
|
||||
|
|
@ -609,7 +609,7 @@ void GPU_offscreen_read_pixels(GPUOffScreen *ofs, int type, void *pixels)
|
|||
glFramebufferTexture2D(
|
||||
GL_READ_FRAMEBUFFER, GL_COLOR_ATTACHMENT0 + ofs->color->fb_attachment,
|
||||
GL_TEXTURE_2D_MULTISAMPLE, ofs->color->bindcode, 0);
|
||||
status = glCheckFramebufferStatusEXT(GL_READ_FRAMEBUFFER);
|
||||
status = glCheckFramebufferStatus(GL_READ_FRAMEBUFFER);
|
||||
if (status != GL_FRAMEBUFFER_COMPLETE) {
|
||||
goto finally;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue