From 53f3a2220943f7f86f8296a6b39cd933ba4badf6 Mon Sep 17 00:00:00 2001 From: Jorge Acereda Date: Tue, 21 Jun 2022 10:00:50 +0200 Subject: [PATCH] Framebuffer object generation should use glGenFramebuffers() --- .../src/stageReadback.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Chapter 29 Fermi Asynchronous Texture Transfers/src/stageReadback.cpp b/Chapter 29 Fermi Asynchronous Texture Transfers/src/stageReadback.cpp index 742ad21..6703bba 100644 --- a/Chapter 29 Fermi Asynchronous Texture Transfers/src/stageReadback.cpp +++ b/Chapter 29 Fermi Asynchronous Texture Transfers/src/stageReadback.cpp @@ -51,7 +51,7 @@ StageReadback::init(const commandLineOptions *options) } glBindBuffer(GL_PIXEL_PACK_BUFFER_ARB, 0); //generate fbo - glGenBuffers(1, &_fboID); + glGenFramebuffers(1, &_fboID); if(glGetError() != GL_NO_ERROR) { @@ -168,7 +168,7 @@ StageReadback::execute(unsigned int stream) element = _inQueue[0]->dequeue(); { // got the texture, readback from texture to pbo - glBindBuffer(GL_PIXEL_PACK_BUFFER_ARB, _packPBOID[_pboIndex]); + glBindBuffer(GL_PIXEL_PACK_BUFFER_ARB, _packPBOID[_pboIndex]); //TODOCALIBRATION begin here glBindTexture(GL_TEXTURE_2D, element->_id); glGetTexImage(GL_TEXTURE_2D, 0, GL_RGBA, GL_UNSIGNED_BYTE, 0);