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

Side by Side Diff: chrome/browser/gpu_process_host_ui_shim.h

Issue 6462034: Refactor how surfaces are acquired for GPU compositing. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove unnecessary include. Created 9 years, 10 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 | « no previous file | chrome/browser/gpu_process_host_ui_shim.cc » ('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) 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 CHROME_BROWSER_GPU_PROCESS_HOST_UI_SHIM_H_ 5 #ifndef CHROME_BROWSER_GPU_PROCESS_HOST_UI_SHIM_H_
6 #define CHROME_BROWSER_GPU_PROCESS_HOST_UI_SHIM_H_ 6 #define CHROME_BROWSER_GPU_PROCESS_HOST_UI_SHIM_H_
7 #pragma once 7 #pragma once
8 8
9 // This class lives on the UI thread and supports classes like the 9 // This class lives on the UI thread and supports classes like the
10 // BackingStoreProxy, which must live on the UI thread. The IO thread 10 // BackingStoreProxy, which must live on the UI thread. The IO thread
11 // portion of this class, the GpuProcessHost, is responsible for 11 // portion of this class, the GpuProcessHost, is responsible for
12 // shuttling messages between the browser and GPU processes. 12 // shuttling messages between the browser and GPU processes.
13 13
14 #include <map>
14 #include <queue> 15 #include <queue>
15 16
16 #include "base/callback.h" 17 #include "base/callback.h"
17 #include "base/linked_ptr.h" 18 #include "base/linked_ptr.h"
18 #include "base/scoped_ptr.h" 19 #include "base/scoped_ptr.h"
19 #include "base/singleton.h" 20 #include "base/singleton.h"
20 #include "base/values.h" 21 #include "base/values.h"
21 #include "base/threading/non_thread_safe.h" 22 #include "base/threading/non_thread_safe.h"
22 #include "chrome/common/gpu_feature_flags.h" 23 #include "chrome/common/gpu_feature_flags.h"
23 #include "chrome/common/gpu_info.h" 24 #include "chrome/common/gpu_info.h"
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 // the GPU process, but haven't heard back about yet. 171 // the GPU process, but haven't heard back about yet.
171 std::queue<linked_ptr<EstablishChannelCallback> > channel_requests_; 172 std::queue<linked_ptr<EstablishChannelCallback> > channel_requests_;
172 173
173 // The pending synchronization requests we need to reply to. 174 // The pending synchronization requests we need to reply to.
174 std::queue<linked_ptr<SynchronizeCallback> > synchronize_requests_; 175 std::queue<linked_ptr<SynchronizeCallback> > synchronize_requests_;
175 176
176 // The pending create command buffer requests we need to reply to. 177 // The pending create command buffer requests we need to reply to.
177 std::queue<linked_ptr<CreateCommandBufferCallback> > 178 std::queue<linked_ptr<CreateCommandBufferCallback> >
178 create_command_buffer_requests_; 179 create_command_buffer_requests_;
179 180
181 typedef std::pair<int32 /* renderer_id */,
182 int32 /* render_view_id */> ViewID;
183
184 // Encapsulates surfaces that we acquire when creating view command buffers.
185 // We assume that a render view has at most 1 such surface associated
186 // with it.
187 class ViewSurface;
188 std::map<ViewID, linked_ptr<ViewSurface> > acquired_surfaces_;
189
180 bool initialized_; 190 bool initialized_;
181 bool initialized_successfully_; 191 bool initialized_successfully_;
182 192
183 bool gpu_feature_flags_set_; 193 bool gpu_feature_flags_set_;
184 scoped_ptr<GpuBlacklist> gpu_blacklist_; 194 scoped_ptr<GpuBlacklist> gpu_blacklist_;
185 GpuFeatureFlags gpu_feature_flags_; 195 GpuFeatureFlags gpu_feature_flags_;
186 }; 196 };
187 197
188 #endif // CHROME_BROWSER_GPU_PROCESS_HOST_UI_SHIM_H_ 198 #endif // CHROME_BROWSER_GPU_PROCESS_HOST_UI_SHIM_H_
189 199
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/gpu_process_host_ui_shim.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698