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

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

Issue 1421903006: ui/gl: Move GLImage into gl namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ozone demo Created 5 years, 1 month 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
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_IMAGE_MANAGER_H_ 5 #ifndef GPU_COMMAND_BUFFER_SERVICE_IMAGE_MANAGER_H_
6 #define GPU_COMMAND_BUFFER_SERVICE_IMAGE_MANAGER_H_ 6 #define GPU_COMMAND_BUFFER_SERVICE_IMAGE_MANAGER_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/containers/hash_tables.h" 9 #include "base/containers/hash_tables.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
11 #include "gpu/gpu_export.h" 11 #include "gpu/gpu_export.h"
12 12
13 namespace gfx { 13 namespace gl {
14 class GLImage; 14 class GLImage;
15 } 15 }
16 16
17 namespace gpu { 17 namespace gpu {
18 namespace gles2 { 18 namespace gles2 {
19 19
20 // This class keeps track of the images and their state. 20 // This class keeps track of the images and their state.
21 class GPU_EXPORT ImageManager { 21 class GPU_EXPORT ImageManager {
22 public: 22 public:
23 ImageManager(); 23 ImageManager();
24 ~ImageManager(); 24 ~ImageManager();
25 25
26 void Destroy(bool have_context); 26 void Destroy(bool have_context);
27 void AddImage(gfx::GLImage* image, int32 service_id); 27 void AddImage(gl::GLImage* image, int32 service_id);
28 void RemoveImage(int32 service_id); 28 void RemoveImage(int32 service_id);
29 gfx::GLImage* LookupImage(int32 service_id); 29 gl::GLImage* LookupImage(int32 service_id);
30 30
31 private: 31 private:
32 typedef base::hash_map<int32, scoped_refptr<gfx::GLImage> > GLImageMap; 32 typedef base::hash_map<int32, scoped_refptr<gl::GLImage>> GLImageMap;
33 GLImageMap images_; 33 GLImageMap images_;
34 34
35 DISALLOW_COPY_AND_ASSIGN(ImageManager); 35 DISALLOW_COPY_AND_ASSIGN(ImageManager);
36 }; 36 };
37 37
38 } // namespage gles2 38 } // namespage gles2
39 } // namespace gpu 39 } // namespace gpu
40 40
41 #endif // GPU_COMMAND_BUFFER_SERVICE_IMAGE_MANAGER_H_ 41 #endif // GPU_COMMAND_BUFFER_SERVICE_IMAGE_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698