Skip to content

Commit

Permalink
Reverted c8cf6cb and try another place to unbind buffer instead
Browse files Browse the repository at this point in the history
  • Loading branch information
ptitSeb committed Mar 28, 2024
1 parent e39434a commit 1a0b4f2
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
1 change: 1 addition & 0 deletions src/gl/buffers.c
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ void APIENTRY_GL4ES gl4es_glBindBuffer(GLenum target, GLuint buffer) {
// if buffer = 0 => unbind buffer!
if (buffer == 0) {
// unbind buffer
bindBuffer(target, 0);
unbind_buffer(target);
} else {
// search for an existing buffer
Expand Down
4 changes: 0 additions & 4 deletions src/gl/fpe.c
Original file line number Diff line number Diff line change
Expand Up @@ -815,10 +815,6 @@ void APIENTRY_GL4ES fpe_glDrawElements(GLenum mode, GLsizei count, GLenum type,
indices = (GLvoid*)((uintptr_t)indices - (uintptr_t)(glstate->vao->elements->data));
DBG(printf("Using VBO %d for indices\n", glstate->vao->elements->real_buffer);)
}
if (!glstate->vao->elements) {
bindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0);
DBG(printf("Unloading EBO\n"));
}
realize_bufferIndex();
gles_glDrawElements(mode, count, type, indices);
if(use_vbo)
Expand Down

0 comments on commit 1a0b4f2

Please # to comment.