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

Side by Side Diff: gpu/command_buffer/tests/gl_manager.h

Issue 20017005: gpu: Refactor GpuMemoryBuffer framework for multi-process support. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Include proper internalformat support.[D Created 7 years, 4 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) 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_TESTS_GL_MANAGER_H_ 5 #ifndef GPU_COMMAND_BUFFER_TESTS_GL_MANAGER_H_
6 #define GPU_COMMAND_BUFFER_TESTS_GL_MANAGER_H_ 6 #define GPU_COMMAND_BUFFER_TESTS_GL_MANAGER_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "gpu/command_buffer/service/feature_info.h" 10 #include "gpu/command_buffer/service/feature_info.h"
11 #include "ui/gfx/size.h" 11 #include "ui/gfx/size.h"
12 12
13 namespace gfx { 13 namespace gfx {
14 14
15 class GLContext; 15 class GLContext;
16 class GLShareGroup; 16 class GLShareGroup;
17 class GLSurface; 17 class GLSurface;
18 18
19 } 19 }
20 20
21 namespace gpu { 21 namespace gpu {
22 22
23 class CommandBufferService; 23 class CommandBufferService;
24 class GpuMemoryBufferFactory;
25 class GpuScheduler;
24 class TransferBuffer; 26 class TransferBuffer;
25 class GpuScheduler;
26 27
27 namespace gles2 { 28 namespace gles2 {
28 29
29 class ContextGroup; 30 class ContextGroup;
30 class MailboxManager; 31 class MailboxManager;
31 class GLES2Decoder; 32 class GLES2Decoder;
32 class GLES2CmdHelper; 33 class GLES2CmdHelper;
33 class GLES2Implementation; 34 class GLES2Implementation;
34 class ImageFactory; 35 class ImageFactory;
35 class ImageManager; 36 class ImageManager;
(...skipping 12 matching lines...) Expand all
48 // If not null will share a mailbox manager with this context. 49 // If not null will share a mailbox manager with this context.
49 GLManager* share_mailbox_manager; 50 GLManager* share_mailbox_manager;
50 // If not null will create a virtual manager based on this context. 51 // If not null will create a virtual manager based on this context.
51 GLManager* virtual_manager; 52 GLManager* virtual_manager;
52 // Whether or not glBindXXX generates a resource. 53 // Whether or not glBindXXX generates a resource.
53 bool bind_generates_resource; 54 bool bind_generates_resource;
54 // Whether or not it's ok to lose the context. 55 // Whether or not it's ok to lose the context.
55 bool context_lost_allowed; 56 bool context_lost_allowed;
56 // Image manager to be used. 57 // Image manager to be used.
57 gles2::ImageManager* image_manager; 58 gles2::ImageManager* image_manager;
58 // Image factory to be used. 59 // GpuMemoryBuffer factory to be used.
59 gles2::ImageFactory* image_factory; 60 GpuMemoryBufferFactory* gpu_memory_buffer_factory;
60 }; 61 };
61 GLManager(); 62 GLManager();
62 ~GLManager(); 63 ~GLManager();
63 64
64 void Initialize(const Options& options); 65 void Initialize(const Options& options);
65 void Destroy(); 66 void Destroy();
66 67
67 void MakeCurrent(); 68 void MakeCurrent();
68 69
69 void SetSurface(gfx::GLSurface* surface); 70 void SetSurface(gfx::GLSurface* surface);
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 // Used on Android to virtualize GL for all contexts. 111 // Used on Android to virtualize GL for all contexts.
111 static int use_count_; 112 static int use_count_;
112 static scoped_refptr<gfx::GLShareGroup>* base_share_group_; 113 static scoped_refptr<gfx::GLShareGroup>* base_share_group_;
113 static scoped_refptr<gfx::GLSurface>* base_surface_; 114 static scoped_refptr<gfx::GLSurface>* base_surface_;
114 static scoped_refptr<gfx::GLContext>* base_context_; 115 static scoped_refptr<gfx::GLContext>* base_context_;
115 }; 116 };
116 117
117 } // namespace gpu 118 } // namespace gpu
118 119
119 #endif // GPU_COMMAND_BUFFER_TESTS_GL_MANAGER_H_ 120 #endif // GPU_COMMAND_BUFFER_TESTS_GL_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698