OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_SERVICE_FRAMEBUFFER_MANAGER_H_ | 5 #ifndef GPU_COMMAND_BUFFER_SERVICE_FRAMEBUFFER_MANAGER_H_ |
6 #define GPU_COMMAND_BUFFER_SERVICE_FRAMEBUFFER_MANAGER_H_ | 6 #define GPU_COMMAND_BUFFER_SERVICE_FRAMEBUFFER_MANAGER_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/hash_tables.h" | 9 #include "base/hash_tables.h" |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
11 #include "base/memory/scoped_ptr.h" | 11 #include "base/memory/scoped_ptr.h" |
12 #include "gpu/command_buffer/service/gl_utils.h" | 12 #include "gpu/command_buffer/service/gl_utils.h" |
13 #include "gpu/command_buffer/service/renderbuffer_manager.h" | 13 #include "gpu/command_buffer/service/renderbuffer_manager.h" |
14 #include "gpu/command_buffer/service/texture_manager.h" | 14 #include "gpu/command_buffer/service/texture_manager.h" |
15 #include "gpu/gpu_export.h" | |
16 | 15 |
17 namespace gpu { | 16 namespace gpu { |
18 namespace gles2 { | 17 namespace gles2 { |
19 | 18 |
20 // This class keeps track of the frambebuffers and their attached renderbuffers | 19 // This class keeps track of the frambebuffers and their attached renderbuffers |
21 // so we can correctly clear them. | 20 // so we can correctly clear them. |
22 class GPU_EXPORT FramebufferManager { | 21 class FramebufferManager { |
23 public: | 22 public: |
24 // Info about Framebuffers currently in the system. | 23 // Info about Framebuffers currently in the system. |
25 class GPU_EXPORT FramebufferInfo : public base::RefCounted<FramebufferInfo> { | 24 class FramebufferInfo : public base::RefCounted<FramebufferInfo> { |
26 public: | 25 public: |
27 typedef scoped_refptr<FramebufferInfo> Ref; | 26 typedef scoped_refptr<FramebufferInfo> Ref; |
28 | 27 |
29 class Attachment : public base::RefCounted<Attachment> { | 28 class Attachment : public base::RefCounted<Attachment> { |
30 public: | 29 public: |
31 typedef scoped_refptr<Attachment> Ref; | 30 typedef scoped_refptr<Attachment> Ref; |
32 | 31 |
33 virtual ~Attachment() { } | 32 virtual ~Attachment() { } |
34 virtual GLsizei width() const = 0; | 33 virtual GLsizei width() const = 0; |
35 virtual GLsizei height() const = 0; | 34 virtual GLsizei height() const = 0; |
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
181 // state. | 180 // state. |
182 unsigned framebuffer_state_change_count_; | 181 unsigned framebuffer_state_change_count_; |
183 | 182 |
184 DISALLOW_COPY_AND_ASSIGN(FramebufferManager); | 183 DISALLOW_COPY_AND_ASSIGN(FramebufferManager); |
185 }; | 184 }; |
186 | 185 |
187 } // namespace gles2 | 186 } // namespace gles2 |
188 } // namespace gpu | 187 } // namespace gpu |
189 | 188 |
190 #endif // GPU_COMMAND_BUFFER_SERVICE_FRAMEBUFFER_MANAGER_H_ | 189 #endif // GPU_COMMAND_BUFFER_SERVICE_FRAMEBUFFER_MANAGER_H_ |
OLD | NEW |