Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
OpenGL: also remove VAO from xfb convertion
We use attributeless rendering, so officially we have to bind _any_ VAO.
As the state of this VAO doesn't matter, we don't have to switch it.

Also fix an AMD issue as they don't like to render from an empty VAO.
  • Loading branch information
degasus committed Nov 25, 2013
1 parent 7ed8e6a commit 230e12a
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions Source/Core/VideoBackends/OGL/Src/TextureConverter.cpp
Expand Up @@ -42,7 +42,6 @@ static SHADER s_encodingPrograms[NUM_ENCODING_PROGRAMS];

static GLuint s_encode_VBO = 0;
static GLuint s_encode_VAO = 0;
static GLuint s_decode_VAO = 0;
static TargetRectangle s_cached_sourceRc;

static const char *VProgram =
Expand Down Expand Up @@ -177,9 +176,6 @@ void Init()
s_cached_sourceRc.left = -1;
s_cached_sourceRc.right = -1;

glGenVertexArrays(1, &s_decode_VAO );
glBindVertexArray( s_decode_VAO );

glActiveTexture(GL_TEXTURE0 + 9);
glGenTextures(1, &s_srcTexture);
glBindTexture(getFbType(), s_srcTexture);
Expand All @@ -200,7 +196,6 @@ void Shutdown()
glDeleteFramebuffers(1, &s_texConvFrameBuffer);
glDeleteBuffers(1, &s_encode_VBO );
glDeleteVertexArrays(1, &s_encode_VAO );
glDeleteVertexArrays(1, &s_decode_VAO );

s_rgbToYuyvProgram.Destroy();
s_yuyvToRgbProgram.Destroy();
Expand Down Expand Up @@ -405,7 +400,6 @@ void DecodeToTexture(u32 xfbAddr, int srcWidth, int srcHeight, GLuint destTextur
glViewport(0, 0, srcWidth, srcHeight);
s_yuyvToRgbProgram.Bind();

glBindVertexArray( s_decode_VAO );
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);

FramebufferManager::SetFramebuffer(0);
Expand Down

0 comments on commit 230e12a

Please sign in to comment.