OLD | NEW |
1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2009 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 // A class to emluate GLES2 over command buffers. | 5 // A class to emluate GLES2 over command buffers. |
6 | 6 |
7 #include "gpu/command_buffer/client/gles2_implementation.h" | 7 #include "gpu/command_buffer/client/gles2_implementation.h" |
8 // TODO(gman): remove when all functions have been implemented. | 8 // TODO(gman): remove when all functions have been implemented. |
9 #include "gpu/command_buffer/client/gles2_implementation_gen.h" | 9 #include "gpu/command_buffer/client/gles2_implementation_gen.h" |
10 #include "gpu/command_buffer/common/gles2_cmd_utils.h" | 10 #include "gpu/command_buffer/common/gles2_cmd_utils.h" |
11 | 11 |
12 namespace command_buffer { | 12 namespace gpu { |
13 namespace gles2 { | 13 namespace gles2 { |
14 | 14 |
15 // A 32-bit and 64-bit compatible way of converting a pointer to a GLuint. | 15 // A 32-bit and 64-bit compatible way of converting a pointer to a GLuint. |
16 static GLuint ToGLuint(const void* ptr) { | 16 static GLuint ToGLuint(const void* ptr) { |
17 return static_cast<GLuint>(reinterpret_cast<size_t>(ptr)); | 17 return static_cast<GLuint>(reinterpret_cast<size_t>(ptr)); |
18 } | 18 } |
19 | 19 |
20 GLES2Implementation::GLES2Implementation( | 20 GLES2Implementation::GLES2Implementation( |
21 GLES2CmdHelper* helper, | 21 GLES2CmdHelper* helper, |
22 size_t transfer_buffer_size, | 22 size_t transfer_buffer_size, |
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
246 temp_width -= num_pixels; | 246 temp_width -= num_pixels; |
247 } | 247 } |
248 ++yoffset; | 248 ++yoffset; |
249 source += padded_row_size; | 249 source += padded_row_size; |
250 } | 250 } |
251 } | 251 } |
252 } | 252 } |
253 | 253 |
254 | 254 |
255 } // namespace gles2 | 255 } // namespace gles2 |
256 } // namespace command_buffer | 256 } // namespace gpu |
OLD | NEW |