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

Side by Side Diff: cc/single_thread_proxy.cc

Issue 12545018: Move context-related callbacks into OutputSurface (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 7 years, 9 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 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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 "cc/single_thread_proxy.h" 5 #include "cc/single_thread_proxy.h"
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/debug/trace_event.h" 8 #include "base/debug/trace_event.h"
9 #include "cc/context_provider.h" 9 #include "cc/context_provider.h"
10 #include "cc/draw_quad.h" 10 #include "cc/draw_quad.h"
(...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after
372 372
373 void SingleThreadProxy::forceSerializeOnSwapBuffers() 373 void SingleThreadProxy::forceSerializeOnSwapBuffers()
374 { 374 {
375 { 375 {
376 DebugScopedSetImplThread impl(this); 376 DebugScopedSetImplThread impl(this);
377 if (m_rendererInitialized) 377 if (m_rendererInitialized)
378 m_layerTreeHostImpl->renderer()->doNoOp(); 378 m_layerTreeHostImpl->renderer()->doNoOp();
379 } 379 }
380 } 380 }
381 381
382 void SingleThreadProxy::onSwapBuffersCompleteOnImplThread()
383 {
384 NOTREACHED();
385 }
386
387 bool SingleThreadProxy::commitAndComposite() 382 bool SingleThreadProxy::commitAndComposite()
388 { 383 {
389 DCHECK(Proxy::isMainThread()); 384 DCHECK(Proxy::isMainThread());
390 385
391 if (!m_layerTreeHost->initializeRendererIfNeeded()) 386 if (!m_layerTreeHost->initializeRendererIfNeeded())
392 return false; 387 return false;
393 388
394 scoped_refptr<cc::ContextProvider> offscreenContextProvider; 389 scoped_refptr<cc::ContextProvider> offscreenContextProvider;
395 if (m_RendererCapabilitiesForMainThread.usingOffscreenContext3d && m_layerTr eeHost->needsOffscreenContext()) { 390 if (m_RendererCapabilitiesForMainThread.usingOffscreenContext3d && m_layerTr eeHost->needsOffscreenContext()) {
396 offscreenContextProvider = m_layerTreeHost->client()->OffscreenContextPr oviderForMainThread(); 391 offscreenContextProvider = m_layerTreeHost->client()->OffscreenContextPr oviderForMainThread();
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
465 } 460 }
466 461
467 skia::RefPtr<SkPicture> SingleThreadProxy::capturePicture() 462 skia::RefPtr<SkPicture> SingleThreadProxy::capturePicture()
468 { 463 {
469 // Requires impl-side painting, which is only supported in threaded composit ing. 464 // Requires impl-side painting, which is only supported in threaded composit ing.
470 NOTREACHED(); 465 NOTREACHED();
471 return skia::RefPtr<SkPicture>(); 466 return skia::RefPtr<SkPicture>();
472 } 467 }
473 468
474 } // namespace cc 469 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698