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 #ifndef GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_H_ | 5 #ifndef GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_H_ |
6 #define GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_H_ | 6 #define GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_H_ |
7 | 7 |
8 #include <GLES2/gl2.h> | 8 #include <GLES2/gl2.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
11 #include <queue> | 11 #include <queue> |
12 #include <set> | 12 #include <set> |
13 #include <string> | 13 #include <string> |
14 #include <vector> | 14 #include <vector> |
15 | 15 |
16 #include "../common/compiler_specific.h" | 16 #include "../common/compiler_specific.h" |
17 #include "../common/debug_marker_manager.h" | 17 #include "../common/debug_marker_manager.h" |
18 #include "../common/gles2_cmd_utils.h" | 18 #include "../common/gles2_cmd_utils.h" |
19 #include "../common/scoped_ptr.h" | 19 #include "../common/scoped_ptr.h" |
| 20 #include "../client/buffer_tracker.h" |
20 #include "../client/ref_counted.h" | 21 #include "../client/ref_counted.h" |
21 #include "../client/gles2_cmd_helper.h" | 22 #include "../client/gles2_cmd_helper.h" |
22 #include "../client/gles2_interface.h" | 23 #include "../client/gles2_interface.h" |
23 #include "../client/query_tracker.h" | 24 #include "../client/query_tracker.h" |
24 #include "../client/ring_buffer.h" | 25 #include "../client/ring_buffer.h" |
25 #include "../client/share_group.h" | 26 #include "../client/share_group.h" |
26 #include "gles2_impl_export.h" | 27 #include "gles2_impl_export.h" |
27 | 28 |
28 #if !defined(NDEBUG) && !defined(__native_client__) && !defined(GLES2_CONFORMANC
E_TESTS) // NOLINT | 29 #if !defined(NDEBUG) && !defined(__native_client__) && !defined(GLES2_CONFORMANC
E_TESTS) // NOLINT |
29 #if defined(GLES2_INLINE_OPTIMIZATION) | 30 #if defined(GLES2_INLINE_OPTIMIZATION) |
(...skipping 497 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
527 | 528 |
528 GLuint bound_framebuffer_; | 529 GLuint bound_framebuffer_; |
529 GLuint bound_renderbuffer_; | 530 GLuint bound_renderbuffer_; |
530 | 531 |
531 // The currently bound array buffer. | 532 // The currently bound array buffer. |
532 GLuint bound_array_buffer_id_; | 533 GLuint bound_array_buffer_id_; |
533 | 534 |
534 // The currently bound element array buffer. | 535 // The currently bound element array buffer. |
535 GLuint bound_element_array_buffer_id_; | 536 GLuint bound_element_array_buffer_id_; |
536 | 537 |
| 538 // The currently bound pixel transfer buffer. |
| 539 GLuint bound_pixel_unpack_transfer_buffer_id_; |
| 540 |
537 // GL names for the buffers used to emulate client side buffers. | 541 // GL names for the buffers used to emulate client side buffers. |
538 GLuint client_side_array_id_; | 542 GLuint client_side_array_id_; |
539 GLuint client_side_element_array_id_; | 543 GLuint client_side_element_array_id_; |
540 | 544 |
541 // Info for each vertex attribute saved so we can simulate client side | 545 // Info for each vertex attribute saved so we can simulate client side |
542 // buffers. | 546 // buffers. |
543 scoped_ptr<ClientSideBufferHelper> client_side_buffer_helper_; | 547 scoped_ptr<ClientSideBufferHelper> client_side_buffer_helper_; |
544 | 548 |
545 // The currently bound vertex array object (VAO) | 549 // The currently bound vertex array object (VAO) |
546 GLuint bound_vertex_array_id_; | 550 GLuint bound_vertex_array_id_; |
(...skipping 24 matching lines...) Expand all Loading... |
571 typedef std::map<const void*, MappedTexture> MappedTextureMap; | 575 typedef std::map<const void*, MappedTexture> MappedTextureMap; |
572 MappedTextureMap mapped_textures_; | 576 MappedTextureMap mapped_textures_; |
573 | 577 |
574 scoped_ptr<MappedMemoryManager> mapped_memory_; | 578 scoped_ptr<MappedMemoryManager> mapped_memory_; |
575 | 579 |
576 scoped_refptr<ShareGroup> share_group_; | 580 scoped_refptr<ShareGroup> share_group_; |
577 | 581 |
578 scoped_ptr<QueryTracker> query_tracker_; | 582 scoped_ptr<QueryTracker> query_tracker_; |
579 QueryTracker::Query* current_query_; | 583 QueryTracker::Query* current_query_; |
580 | 584 |
| 585 scoped_ptr<BufferTracker> buffer_tracker_; |
| 586 |
581 ErrorMessageCallback* error_message_callback_; | 587 ErrorMessageCallback* error_message_callback_; |
582 | 588 |
583 DISALLOW_COPY_AND_ASSIGN(GLES2Implementation); | 589 DISALLOW_COPY_AND_ASSIGN(GLES2Implementation); |
584 }; | 590 }; |
585 | 591 |
586 inline bool GLES2Implementation::GetBufferParameterivHelper( | 592 inline bool GLES2Implementation::GetBufferParameterivHelper( |
587 GLenum /* target */, GLenum /* pname */, GLint* /* params */) { | 593 GLenum /* target */, GLenum /* pname */, GLint* /* params */) { |
588 return false; | 594 return false; |
589 } | 595 } |
590 | 596 |
(...skipping 22 matching lines...) Expand all Loading... |
613 | 619 |
614 inline bool GLES2Implementation::GetTexParameterivHelper( | 620 inline bool GLES2Implementation::GetTexParameterivHelper( |
615 GLenum /* target */, GLenum /* pname */, GLint* /* params */) { | 621 GLenum /* target */, GLenum /* pname */, GLint* /* params */) { |
616 return false; | 622 return false; |
617 } | 623 } |
618 | 624 |
619 } // namespace gles2 | 625 } // namespace gles2 |
620 } // namespace gpu | 626 } // namespace gpu |
621 | 627 |
622 #endif // GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_H_ | 628 #endif // GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_H_ |
OLD | NEW |