diff options
| author | degasus <wickmarkus@web.de> | 2012-12-13 15:48:42 +0100 |
|---|---|---|
| committer | Ryan Houdek <Sonicadvance1@gmail.com> | 2012-12-13 15:28:52 -0600 |
| commit | 79a7ce4827de774bc0d454ad2e679f99e1da96fe (patch) | |
| tree | bce7fa6ced0b603b8405d5d4d4049aec16506dde /Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.cpp | |
| parent | 09274e2483abd7ea0ae26daa32f9cf3f7a3e2b16 (diff) | |
move glBindBuffer and glBindVertexArray out of VertexManager
Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
Diffstat (limited to 'Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.cpp')
| -rw-r--r-- | Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.cpp b/Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.cpp index 9c66396226..0220e54806 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.cpp +++ b/Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.cpp @@ -201,7 +201,11 @@ FramebufferManager::FramebufferManager(int targetWidth, int targetHeight, int ms glClientActiveTexture(GL_TEXTURE1); glEnableClientState(GL_TEXTURE_COORD_ARRAY); glTexCoordPointer(2, GL_FLOAT, 6*sizeof(GLfloat), (GLfloat*)NULL+4); - + + // TODO: this after merging with graphic_update + glBindBuffer(GL_ARRAY_BUFFER, 0); + glBindVertexArray(0); + // EFB framebuffer is currently bound, make sure to clear its alpha value to 1.f glViewport(0, 0, m_targetWidth, m_targetHeight); glScissor(0, 0, m_targetWidth, m_targetHeight); @@ -356,6 +360,9 @@ void XFBSource::Draw(const MathUtil::Rectangle<float> &sourcerc, }; glBindBuffer(GL_ARRAY_BUFFER, s_VBO); glBufferData(GL_ARRAY_BUFFER, 2*4*3*sizeof(GLfloat), vertices, GL_STREAM_DRAW); + + // TODO: this after merging with graphic_update + glBindBuffer(GL_ARRAY_BUFFER, 0); s_cached_sourcerc = sourcerc; s_cached_drawrc = drawrc; @@ -363,6 +370,9 @@ void XFBSource::Draw(const MathUtil::Rectangle<float> &sourcerc, glBindVertexArray(s_VAO); glDrawArrays(GL_TRIANGLE_FAN, 0, 4); + + // TODO: this after merging with graphic_update + glBindVertexArray(0); GL_REPORT_ERRORD(); } |
