OLD | NEW |
---|---|
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 <limits.h> | 7 #include <limits.h> |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 #include <stdio.h> | 10 #include <stdio.h> |
(...skipping 7128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
7139 GLenum GLES2DecoderImpl::DoCheckFramebufferStatus(GLenum target) { | 7139 GLenum GLES2DecoderImpl::DoCheckFramebufferStatus(GLenum target) { |
7140 Framebuffer* framebuffer = | 7140 Framebuffer* framebuffer = |
7141 GetFramebufferInfoForTarget(target); | 7141 GetFramebufferInfoForTarget(target); |
7142 if (!framebuffer) { | 7142 if (!framebuffer) { |
7143 return GL_FRAMEBUFFER_COMPLETE; | 7143 return GL_FRAMEBUFFER_COMPLETE; |
7144 } | 7144 } |
7145 GLenum completeness = framebuffer->IsPossiblyComplete(feature_info_.get()); | 7145 GLenum completeness = framebuffer->IsPossiblyComplete(feature_info_.get()); |
7146 if (completeness != GL_FRAMEBUFFER_COMPLETE) { | 7146 if (completeness != GL_FRAMEBUFFER_COMPLETE) { |
7147 return completeness; | 7147 return completeness; |
7148 } | 7148 } |
7149 | |
7150 if (framebuffer->HasDuplicateColorAttachments()) { | |
Zhenyao Mo
2016/07/19 20:39:15
This should go inside Framebuffer::IsPossiblyCompl
qiankun
2016/07/20 08:53:33
Done.
| |
7151 return GL_FRAMEBUFFER_UNSUPPORTED; | |
7152 } | |
7153 | |
7149 return framebuffer->GetStatus(texture_manager(), target); | 7154 return framebuffer->GetStatus(texture_manager(), target); |
7150 } | 7155 } |
7151 | 7156 |
7152 void GLES2DecoderImpl::DoFramebufferTexture2D( | 7157 void GLES2DecoderImpl::DoFramebufferTexture2D( |
7153 GLenum target, GLenum attachment, GLenum textarget, | 7158 GLenum target, GLenum attachment, GLenum textarget, |
7154 GLuint client_texture_id, GLint level) { | 7159 GLuint client_texture_id, GLint level) { |
7155 DoFramebufferTexture2DCommon( | 7160 DoFramebufferTexture2DCommon( |
7156 "glFramebufferTexture2D", target, attachment, | 7161 "glFramebufferTexture2D", target, attachment, |
7157 textarget, client_texture_id, level, 0); | 7162 textarget, client_texture_id, level, 0); |
7158 } | 7163 } |
(...skipping 10245 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
17404 } | 17409 } |
17405 | 17410 |
17406 // Include the auto-generated part of this file. We split this because it means | 17411 // Include the auto-generated part of this file. We split this because it means |
17407 // we can easily edit the non-auto generated parts right here in this file | 17412 // we can easily edit the non-auto generated parts right here in this file |
17408 // instead of having to edit some template or the code generator. | 17413 // instead of having to edit some template or the code generator. |
17409 #include "base/macros.h" | 17414 #include "base/macros.h" |
17410 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" | 17415 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" |
17411 | 17416 |
17412 } // namespace gles2 | 17417 } // namespace gles2 |
17413 } // namespace gpu | 17418 } // namespace gpu |
OLD | NEW |