Skip to content

Commit

Permalink
Cache render buffer extents when no depth/stencil buffer (flutter#4801)
Browse files Browse the repository at this point in the history
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.
  • Loading branch information
cbracken authored Mar 16, 2018
1 parent ac7b81f commit c9fe399
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion shell/platform/darwin/ios/ios_gl_context.mm
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@
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);
Expand Down

0 comments on commit c9fe399

Please sign in to comment.