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 <stdio.h> | 7 #include <stdio.h> |
8 | 8 |
9 #include <algorithm> | 9 #include <algorithm> |
10 #include <list> | 10 #include <list> |
(...skipping 4004 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4015 texture_manager(), | 4015 texture_manager(), |
4016 attachments[i], | 4016 attachments[i], |
4017 false); | 4017 false); |
4018 } else { | 4018 } else { |
4019 switch (attachments[i]) { | 4019 switch (attachments[i]) { |
4020 case GL_COLOR_EXT: | 4020 case GL_COLOR_EXT: |
4021 backbuffer_needs_clear_bits_ |= GL_COLOR_BUFFER_BIT; | 4021 backbuffer_needs_clear_bits_ |= GL_COLOR_BUFFER_BIT; |
4022 break; | 4022 break; |
4023 case GL_DEPTH_EXT: | 4023 case GL_DEPTH_EXT: |
4024 backbuffer_needs_clear_bits_ |= GL_DEPTH_BUFFER_BIT; | 4024 backbuffer_needs_clear_bits_ |= GL_DEPTH_BUFFER_BIT; |
| 4025 break; // FIXME is this right |
4025 case GL_STENCIL_EXT: | 4026 case GL_STENCIL_EXT: |
4026 backbuffer_needs_clear_bits_ |= GL_STENCIL_BUFFER_BIT; | 4027 backbuffer_needs_clear_bits_ |= GL_STENCIL_BUFFER_BIT; |
4027 break; | 4028 break; |
4028 default: | 4029 default: |
4029 NOTREACHED(); | 4030 NOTREACHED(); |
4030 break; | 4031 break; |
4031 } | 4032 } |
4032 } | 4033 } |
4033 } | 4034 } |
4034 | 4035 |
(...skipping 1023 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5058 *params = renderbuffer->height(); | 5059 *params = renderbuffer->height(); |
5059 break; | 5060 break; |
5060 case GL_RENDERBUFFER_SAMPLES_EXT: | 5061 case GL_RENDERBUFFER_SAMPLES_EXT: |
5061 if (features().use_img_for_multisampled_render_to_texture) { | 5062 if (features().use_img_for_multisampled_render_to_texture) { |
5062 glGetRenderbufferParameterivEXT(target, GL_RENDERBUFFER_SAMPLES_IMG, | 5063 glGetRenderbufferParameterivEXT(target, GL_RENDERBUFFER_SAMPLES_IMG, |
5063 params); | 5064 params); |
5064 } else { | 5065 } else { |
5065 glGetRenderbufferParameterivEXT(target, GL_RENDERBUFFER_SAMPLES_EXT, | 5066 glGetRenderbufferParameterivEXT(target, GL_RENDERBUFFER_SAMPLES_EXT, |
5066 params); | 5067 params); |
5067 } | 5068 } |
| 5069 break; // FIXME is this right |
5068 default: | 5070 default: |
5069 glGetRenderbufferParameterivEXT(target, pname, params); | 5071 glGetRenderbufferParameterivEXT(target, pname, params); |
5070 break; | 5072 break; |
5071 } | 5073 } |
5072 } | 5074 } |
5073 | 5075 |
5074 void GLES2DecoderImpl::DoBlitFramebufferCHROMIUM( | 5076 void GLES2DecoderImpl::DoBlitFramebufferCHROMIUM( |
5075 GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, | 5077 GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, |
5076 GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, | 5078 GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, |
5077 GLbitfield mask, GLenum filter) { | 5079 GLbitfield mask, GLenum filter) { |
(...skipping 5563 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10641 DoDidUseTexImageIfNeeded(texture, texture->target()); | 10643 DoDidUseTexImageIfNeeded(texture, texture->target()); |
10642 } | 10644 } |
10643 | 10645 |
10644 // Include the auto-generated part of this file. We split this because it means | 10646 // Include the auto-generated part of this file. We split this because it means |
10645 // we can easily edit the non-auto generated parts right here in this file | 10647 // we can easily edit the non-auto generated parts right here in this file |
10646 // instead of having to edit some template or the code generator. | 10648 // instead of having to edit some template or the code generator. |
10647 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" | 10649 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" |
10648 | 10650 |
10649 } // namespace gles2 | 10651 } // namespace gles2 |
10650 } // namespace gpu | 10652 } // namespace gpu |
OLD | NEW |