OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 // This file is auto-generated from | 5 // This file is auto-generated from |
6 // gpu/command_buffer/build_gles2_cmd_buffer.py | 6 // gpu/command_buffer/build_gles2_cmd_buffer.py |
7 // It's formatted by clang-format using chromium coding style: | 7 // It's formatted by clang-format using chromium coding style: |
8 // clang-format -i -style=chromium filename | 8 // clang-format -i -style=chromium filename |
9 // DO NOT EDIT! | 9 // DO NOT EDIT! |
10 | 10 |
(...skipping 3643 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3654 } | 3654 } |
3655 const GLfloat* value = | 3655 const GLfloat* value = |
3656 GetImmediateDataAs<const GLfloat*>(c, data_size, immediate_data_size); | 3656 GetImmediateDataAs<const GLfloat*>(c, data_size, immediate_data_size); |
3657 if (value == NULL) { | 3657 if (value == NULL) { |
3658 return error::kOutOfBounds; | 3658 return error::kOutOfBounds; |
3659 } | 3659 } |
3660 DoUniformMatrix4x3fv(location, count, transpose, value); | 3660 DoUniformMatrix4x3fv(location, count, transpose, value); |
3661 return error::kNoError; | 3661 return error::kNoError; |
3662 } | 3662 } |
3663 | 3663 |
| 3664 error::Error |
| 3665 GLES2DecoderImpl::HandleUniformMatrix4fvWithCustomMatrixCHROMIUMImmediate( |
| 3666 uint32_t immediate_data_size, |
| 3667 const void* cmd_data) { |
| 3668 const gles2::cmds::UniformMatrix4fvWithCustomMatrixCHROMIUMImmediate& c = |
| 3669 *static_cast<const gles2::cmds:: |
| 3670 UniformMatrix4fvWithCustomMatrixCHROMIUMImmediate*>( |
| 3671 cmd_data); |
| 3672 (void)c; |
| 3673 GLint location = static_cast<GLint>(c.location); |
| 3674 GLsizei count = static_cast<GLsizei>(c.count); |
| 3675 GLint custom_matrix_id = static_cast<GLint>(c.custom_matrix_id); |
| 3676 GLboolean transpose = static_cast<GLboolean>(c.transpose); |
| 3677 uint32_t data_size; |
| 3678 if (!ComputeDataSize(count, sizeof(GLfloat), 16, &data_size)) { |
| 3679 return error::kOutOfBounds; |
| 3680 } |
| 3681 if (data_size > immediate_data_size) { |
| 3682 return error::kOutOfBounds; |
| 3683 } |
| 3684 const GLfloat* default_value = |
| 3685 GetImmediateDataAs<const GLfloat*>(c, data_size, immediate_data_size); |
| 3686 if (default_value == NULL) { |
| 3687 return error::kOutOfBounds; |
| 3688 } |
| 3689 DoUniformMatrix4fvWithCustomMatrixCHROMIUM(location, count, custom_matrix_id, |
| 3690 transpose, default_value); |
| 3691 return error::kNoError; |
| 3692 } |
| 3693 |
3664 error::Error GLES2DecoderImpl::HandleUseProgram(uint32_t immediate_data_size, | 3694 error::Error GLES2DecoderImpl::HandleUseProgram(uint32_t immediate_data_size, |
3665 const void* cmd_data) { | 3695 const void* cmd_data) { |
3666 const gles2::cmds::UseProgram& c = | 3696 const gles2::cmds::UseProgram& c = |
3667 *static_cast<const gles2::cmds::UseProgram*>(cmd_data); | 3697 *static_cast<const gles2::cmds::UseProgram*>(cmd_data); |
3668 (void)c; | 3698 (void)c; |
3669 GLuint program = c.program; | 3699 GLuint program = c.program; |
3670 DoUseProgram(program); | 3700 DoUseProgram(program); |
3671 return error::kNoError; | 3701 return error::kNoError; |
3672 } | 3702 } |
3673 | 3703 |
(...skipping 1442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5116 state_.enable_flags.cached_sample_alpha_to_one_ext = enabled; | 5146 state_.enable_flags.cached_sample_alpha_to_one_ext = enabled; |
5117 return true; | 5147 return true; |
5118 } | 5148 } |
5119 return false; | 5149 return false; |
5120 default: | 5150 default: |
5121 NOTREACHED(); | 5151 NOTREACHED(); |
5122 return false; | 5152 return false; |
5123 } | 5153 } |
5124 } | 5154 } |
5125 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_AUTOGEN_H_ | 5155 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_AUTOGEN_H_ |
OLD | NEW |