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

Side by Side Diff: webkit/common/gpu/context_provider_in_process.cc

Issue 54463007: Expose GLES2Interface to cc (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 #include "webkit/common/gpu/context_provider_in_process.h" 5 #include "webkit/common/gpu/context_provider_in_process.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback_helpers.h" 10 #include "base/callback_helpers.h"
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 } 145 }
146 146
147 blink::WebGraphicsContext3D* ContextProviderInProcess::Context3d() { 147 blink::WebGraphicsContext3D* ContextProviderInProcess::Context3d() {
148 DCHECK(context3d_); 148 DCHECK(context3d_);
149 DCHECK(lost_context_callback_proxy_); // Is bound to thread. 149 DCHECK(lost_context_callback_proxy_); // Is bound to thread.
150 DCHECK(context_thread_checker_.CalledOnValidThread()); 150 DCHECK(context_thread_checker_.CalledOnValidThread());
151 151
152 return context3d_.get(); 152 return context3d_.get();
153 } 153 }
154 154
155 ::gpu::gles2::GLES2Interface* ContextProviderInProcess::ContextGL() {
156 DCHECK(context3d_);
157 DCHECK(lost_context_callback_proxy_); // Is bound to thread.
158 DCHECK(context_thread_checker_.CalledOnValidThread());
159
160 return context3d_->GetGLInterface();
161 }
162
155 ::gpu::ContextSupport* ContextProviderInProcess::ContextSupport() { 163 ::gpu::ContextSupport* ContextProviderInProcess::ContextSupport() {
156 DCHECK(context3d_); 164 DCHECK(context3d_);
157 DCHECK(lost_context_callback_proxy_); // Is bound to thread. 165 DCHECK(lost_context_callback_proxy_); // Is bound to thread.
158 DCHECK(context_thread_checker_.CalledOnValidThread()); 166 DCHECK(context_thread_checker_.CalledOnValidThread());
159 167
160 return context3d_->GetContextSupport(); 168 return context3d_->GetContextSupport();
161 } 169 }
162 170
163 class GrContext* ContextProviderInProcess::GrContext() { 171 class GrContext* ContextProviderInProcess::GrContext() {
164 DCHECK(context3d_); 172 DCHECK(context3d_);
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
231 swap_buffers_complete_callback_ = swap_buffers_complete_callback; 239 swap_buffers_complete_callback_ = swap_buffers_complete_callback;
232 } 240 }
233 241
234 void ContextProviderInProcess::SetMemoryPolicyChangedCallback( 242 void ContextProviderInProcess::SetMemoryPolicyChangedCallback(
235 const MemoryPolicyChangedCallback& memory_policy_changed_callback) { 243 const MemoryPolicyChangedCallback& memory_policy_changed_callback) {
236 // There's no memory manager for the in-process implementation. 244 // There's no memory manager for the in-process implementation.
237 } 245 }
238 246
239 } // namespace gpu 247 } // namespace gpu
240 } // namespace webkit 248 } // namespace webkit
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698