Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(176)

Side by Side Diff: gpu/command_buffer/service/gles2_cmd_decoder.cc

Issue 1068573004: Disable framebuffer discarding on Mali-4xx and clean up. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Don't make old workaround more specific for safety Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" 5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h"
6 6
7 #include <stdio.h> 7 #include <stdio.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <list> 10 #include <list>
(...skipping 4503 matching lines...) Expand 10 before | Expand all | Expand 10 after
4514 } else { 4514 } else {
4515 LOCAL_SET_GL_ERROR( 4515 LOCAL_SET_GL_ERROR(
4516 GL_INVALID_VALUE, 4516 GL_INVALID_VALUE,
4517 "glDisableVertexAttribArray", "index out of range"); 4517 "glDisableVertexAttribArray", "index out of range");
4518 } 4518 }
4519 } 4519 }
4520 4520
4521 void GLES2DecoderImpl::DoDiscardFramebufferEXT(GLenum target, 4521 void GLES2DecoderImpl::DoDiscardFramebufferEXT(GLenum target,
4522 GLsizei numAttachments, 4522 GLsizei numAttachments,
4523 const GLenum* attachments) { 4523 const GLenum* attachments) {
4524 if (workarounds().disable_fbo_invalidations) 4524 if (workarounds().disable_discard_framebuffer)
4525 return; 4525 return;
4526 4526
4527 Framebuffer* framebuffer = 4527 Framebuffer* framebuffer =
4528 GetFramebufferInfoForTarget(GL_FRAMEBUFFER); 4528 GetFramebufferInfoForTarget(GL_FRAMEBUFFER);
4529 4529
4530 // Validates the attachments. If one of them fails 4530 // Validates the attachments. If one of them fails
4531 // the whole command fails. 4531 // the whole command fails.
4532 for (GLsizei i = 0; i < numAttachments; ++i) { 4532 for (GLsizei i = 0; i < numAttachments; ++i) {
4533 if ((framebuffer && 4533 if ((framebuffer &&
4534 !validators_->attachment.IsValid(attachments[i])) || 4534 !validators_->attachment.IsValid(attachments[i])) ||
(...skipping 8025 matching lines...) Expand 10 before | Expand all | Expand 10 after
12560 } 12560 }
12561 } 12561 }
12562 12562
12563 // Include the auto-generated part of this file. We split this because it means 12563 // Include the auto-generated part of this file. We split this because it means
12564 // we can easily edit the non-auto generated parts right here in this file 12564 // we can easily edit the non-auto generated parts right here in this file
12565 // instead of having to edit some template or the code generator. 12565 // instead of having to edit some template or the code generator.
12566 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" 12566 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h"
12567 12567
12568 } // namespace gles2 12568 } // namespace gles2
12569 } // namespace gpu 12569 } // namespace gpu
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698