未验证 提交 c9fe3997 编写于 作者: C Chris Bracken 提交者: GitHub

Cache render buffer extents when no depth/stencil buffer (#4801)

Previously iOS render buffer storage width and height were not cached if
not using a depth/stencil buffer. This adds a similar check for
colorBuffer to avoid reallocating render buffer storage.
上级 ac7b81f7
......@@ -193,7 +193,7 @@ bool IOSGLContext::UpdateStorageSizeIfNecessary() {
bool rebind_color_buffer = false;
if (depthbuffer_ != GL_NONE || stencilbuffer_ != GL_NONE ||
depth_stencil_packed_buffer_ != GL_NONE) {
depth_stencil_packed_buffer_ != GL_NONE || colorbuffer_ != GL_NONE) {
// Fetch the dimensions of the color buffer whose backing was just updated
// so that backing of the attachments can be updated
glGetRenderbufferParameteriv(GL_RENDERBUFFER, GL_RENDERBUFFER_WIDTH, &width);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册