Commit 588ba833 by Jonah Ryan-Davis Committed by Commit Bot

Keep state up to date after bindBufferBase/Range

Missing state tracking in StateManagerGL::bindBufferBase and bindBufferRange. Bug: angleprojects:3900 Change-Id: Ibaa4731962532f85b3e8a34d974c308d72b20a7f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1838452Reviewed-by: 's avatarGeoff Lang <geofflang@chromium.org> Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
parent c847a75f
...@@ -386,6 +386,7 @@ void StateManagerGL::bindBufferBase(gl::BufferBinding target, size_t index, GLui ...@@ -386,6 +386,7 @@ void StateManagerGL::bindBufferBase(gl::BufferBinding target, size_t index, GLui
binding.buffer = buffer; binding.buffer = buffer;
binding.offset = static_cast<size_t>(-1); binding.offset = static_cast<size_t>(-1);
binding.size = static_cast<size_t>(-1); binding.size = static_cast<size_t>(-1);
mBuffers[target] = buffer;
mFunctions->bindBufferBase(gl::ToGLenum(target), static_cast<GLuint>(index), buffer); mFunctions->bindBufferBase(gl::ToGLenum(target), static_cast<GLuint>(index), buffer);
} }
} }
...@@ -402,6 +403,7 @@ void StateManagerGL::bindBufferRange(gl::BufferBinding target, ...@@ -402,6 +403,7 @@ void StateManagerGL::bindBufferRange(gl::BufferBinding target,
binding.buffer = buffer; binding.buffer = buffer;
binding.offset = offset; binding.offset = offset;
binding.size = size; binding.size = size;
mBuffers[target] = buffer;
mFunctions->bindBufferRange(gl::ToGLenum(target), static_cast<GLuint>(index), buffer, mFunctions->bindBufferRange(gl::ToGLenum(target), static_cast<GLuint>(index), buffer,
offset, size); offset, size);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment