| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 MOJO_UI_GL_RENDERER_H_ | 5 #ifndef MOJO_UI_GL_RENDERER_H_ |
| 6 #define MOJO_UI_GL_RENDERER_H_ | 6 #define MOJO_UI_GL_RENDERER_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <memory> | 9 #include <memory> |
| 10 | 10 |
| 11 #include "base/callback.h" | 11 #include "base/callback.h" |
| 12 #include "base/logging.h" |
| 12 #include "base/macros.h" | 13 #include "base/macros.h" |
| 13 #include "base/memory/ref_counted.h" | 14 #include "base/memory/ref_counted.h" |
| 14 #include "base/memory/weak_ptr.h" | 15 #include "base/memory/weak_ptr.h" |
| 15 #include "mojo/gpu/gl_context.h" | 16 #include "mojo/gpu/gl_context.h" |
| 16 #include "mojo/gpu/gl_texture.h" | 17 #include "mojo/gpu/gl_texture.h" |
| 17 #include "mojo/public/cpp/bindings/strong_binding.h" | 18 #include "mojo/public/cpp/bindings/strong_binding.h" |
| 18 #include "mojo/services/geometry/interfaces/geometry.mojom.h" | 19 #include "mojo/services/geometry/interfaces/geometry.mojom.h" |
| 19 #include "mojo/services/gfx/composition/interfaces/resources.mojom.h" | 20 #include "mojo/services/gfx/composition/interfaces/resources.mojom.h" |
| 20 | 21 |
| 21 namespace mojo { | 22 namespace mojo { |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 }; | 97 }; |
| 97 | 98 |
| 98 void ReleaseTexture(GLRecycledTextureInfo texture_info, bool recyclable); | 99 void ReleaseTexture(GLRecycledTextureInfo texture_info, bool recyclable); |
| 99 | 100 |
| 100 scoped_refptr<mojo::GLContext> gl_context_; | 101 scoped_refptr<mojo::GLContext> gl_context_; |
| 101 const uint32_t max_recycled_textures_; | 102 const uint32_t max_recycled_textures_; |
| 102 | 103 |
| 103 std::deque<GLRecycledTextureInfo> recycled_textures_; | 104 std::deque<GLRecycledTextureInfo> recycled_textures_; |
| 104 uint32_t bound_textures_ = 0u; | 105 uint32_t bound_textures_ = 0u; |
| 105 | 106 |
| 107 #if DCHECK_IS_ON() |
| 108 bool checked_framebuffer_status_ = false; |
| 109 #endif |
| 110 |
| 106 base::WeakPtrFactory<mojo::ui::GLRenderer> weak_factory_; | 111 base::WeakPtrFactory<mojo::ui::GLRenderer> weak_factory_; |
| 107 | 112 |
| 108 DISALLOW_COPY_AND_ASSIGN(GLRenderer); | 113 DISALLOW_COPY_AND_ASSIGN(GLRenderer); |
| 109 }; | 114 }; |
| 110 | 115 |
| 111 } // namespace ui | 116 } // namespace ui |
| 112 } // namespace mojo | 117 } // namespace mojo |
| 113 | 118 |
| 114 #endif // MOJO_UI_GL_RENDERER_H_ | 119 #endif // MOJO_UI_GL_RENDERER_H_ |
| OLD | NEW |