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

Unified Diff: cc/raster/gpu_tile_task_worker_pool.cc

Issue 1317743002: cc: Implement shared worker contexts. (v1) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add aw comments Created 5 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: cc/raster/gpu_tile_task_worker_pool.cc
diff --git a/cc/raster/gpu_tile_task_worker_pool.cc b/cc/raster/gpu_tile_task_worker_pool.cc
index 0f3d6077813207b1eaed9d80dcc52e1e3268ba50..dfafec2574d751642a29160c284a51b3b33eba0d 100644
--- a/cc/raster/gpu_tile_task_worker_pool.cc
+++ b/cc/raster/gpu_tile_task_worker_pool.cc
@@ -50,6 +50,10 @@ class RasterBufferImpl : public RasterBuffer {
ContextProvider::ScopedContextLock scoped_context(context_provider);
+ gpu::gles2::GLES2Interface* gl = scoped_context.ContextGL();
+ if (!gl)
+ return;
+
gfx::Rect playback_rect = raster_full_rect;
if (resource_has_previous_content_) {
playback_rect.Intersect(raster_dirty_rect);
@@ -63,7 +67,7 @@ class RasterBufferImpl : public RasterBuffer {
playback_rect, scale);
// Barrier to sync worker context output to cc context.
- scoped_context.ContextGL()->OrderingBarrierCHROMIUM();
+ gl->OrderingBarrierCHROMIUM();
}
private:

Powered by Google App Engine
This is Rietveld 408576698