Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(496)

Side by Side Diff: gpu/command_buffer/service/buffer_manager.h

Issue 9582024: Revert 124702 - GPU: Buld most of the gpu as a single DLL. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « gpu/command_buffer/common/id_allocator.h ('k') | gpu/command_buffer/service/cmd_parser.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_SERVICE_BUFFER_MANAGER_H_ 5 #ifndef GPU_COMMAND_BUFFER_SERVICE_BUFFER_MANAGER_H_
6 #define GPU_COMMAND_BUFFER_SERVICE_BUFFER_MANAGER_H_ 6 #define GPU_COMMAND_BUFFER_SERVICE_BUFFER_MANAGER_H_
7 7
8 #include <map> 8 #include <map>
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/hash_tables.h" 10 #include "base/hash_tables.h"
11 #include "base/logging.h" 11 #include "base/logging.h"
12 #include "base/memory/ref_counted.h" 12 #include "base/memory/ref_counted.h"
13 #include "base/memory/scoped_ptr.h" 13 #include "base/memory/scoped_ptr.h"
14 #include "gpu/command_buffer/service/gl_utils.h" 14 #include "gpu/command_buffer/service/gl_utils.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 buffers and their sizes so we can do 19 // This class keeps track of the buffers and their sizes so we can do
21 // bounds checking. 20 // bounds checking.
22 // 21 //
23 // NOTE: To support shared resources an instance of this class will need to be 22 // NOTE: To support shared resources an instance of this class will need to be
24 // shared by multiple GLES2Decoders. 23 // shared by multiple GLES2Decoders.
25 class GPU_EXPORT BufferManager { 24 class BufferManager {
26 public: 25 public:
27 // Info about Buffers currently in the system. 26 // Info about Buffers currently in the system.
28 class GPU_EXPORT BufferInfo : public base::RefCounted<BufferInfo> { 27 class BufferInfo : public base::RefCounted<BufferInfo> {
29 public: 28 public:
30 typedef scoped_refptr<BufferInfo> Ref; 29 typedef scoped_refptr<BufferInfo> Ref;
31 30
32 BufferInfo(BufferManager* manager, GLuint service_id); 31 BufferInfo(BufferManager* manager, GLuint service_id);
33 32
34 GLuint service_id() const { 33 GLuint service_id() const {
35 return service_id_; 34 return service_id_;
36 } 35 }
37 36
38 GLsizeiptr size() const { 37 GLsizeiptr size() const {
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 size_t mem_represented_; 194 size_t mem_represented_;
196 size_t last_reported_mem_represented_; 195 size_t last_reported_mem_represented_;
197 196
198 DISALLOW_COPY_AND_ASSIGN(BufferManager); 197 DISALLOW_COPY_AND_ASSIGN(BufferManager);
199 }; 198 };
200 199
201 } // namespace gles2 200 } // namespace gles2
202 } // namespace gpu 201 } // namespace gpu
203 202
204 #endif // GPU_COMMAND_BUFFER_SERVICE_BUFFER_MANAGER_H_ 203 #endif // GPU_COMMAND_BUFFER_SERVICE_BUFFER_MANAGER_H_
OLDNEW
« no previous file with comments | « gpu/command_buffer/common/id_allocator.h ('k') | gpu/command_buffer/service/cmd_parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698