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

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

Issue 2880013: Free the resources used by a context group. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years, 5 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
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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_CONTEXT_GROUP_H_ 5 #ifndef GPU_COMMAND_BUFFER_SERVICE_CONTEXT_GROUP_H_
6 #define GPU_COMMAND_BUFFER_SERVICE_CONTEXT_GROUP_H_ 6 #define GPU_COMMAND_BUFFER_SERVICE_CONTEXT_GROUP_H_
7 7
8 #include <map> 8 #include <map>
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/linked_ptr.h" 10 #include "base/linked_ptr.h"
(...skipping 17 matching lines...) Expand all
28 // A Context Group helps manage multiple GLES2Decoders that share 28 // A Context Group helps manage multiple GLES2Decoders that share
29 // resources. 29 // resources.
30 class ContextGroup { 30 class ContextGroup {
31 public: 31 public:
32 ContextGroup(); 32 ContextGroup();
33 ~ContextGroup(); 33 ~ContextGroup();
34 34
35 // This should only be called by GLES2Decoder. 35 // This should only be called by GLES2Decoder.
36 bool Initialize(); 36 bool Initialize();
37 37
38 // Destroys all the resources. MUST be called before destruction.
39 void Destroy(bool have_context);
40
38 uint32 max_vertex_attribs() const { 41 uint32 max_vertex_attribs() const {
39 return max_vertex_attribs_; 42 return max_vertex_attribs_;
40 } 43 }
41 44
42 uint32 max_texture_units() const { 45 uint32 max_texture_units() const {
43 return max_texture_units_; 46 return max_texture_units_;
44 } 47 }
45 48
46 uint32 max_texture_image_units() const { 49 uint32 max_texture_image_units() const {
47 return max_texture_image_units_; 50 return max_texture_image_units_;
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 127
125 DISALLOW_COPY_AND_ASSIGN(ContextGroup); 128 DISALLOW_COPY_AND_ASSIGN(ContextGroup);
126 }; 129 };
127 130
128 } // namespace gles2 131 } // namespace gles2
129 } // namespace gpu 132 } // namespace gpu
130 133
131 #endif // GPU_COMMAND_BUFFER_SERVICE_CONTEXT_GROUP_H_ 134 #endif // GPU_COMMAND_BUFFER_SERVICE_CONTEXT_GROUP_H_
132 135
133 136
OLDNEW
« no previous file with comments | « gpu/command_buffer/service/buffer_manager_unittest.cc ('k') | gpu/command_buffer/service/context_group.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698