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

Side by Side Diff: cc/resources/picture_pile_impl.cc

Issue 141163019: Re-land: cc: Remove WorkerPool class and instead use TaskGraphRunner directly. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix mode of task_graph_runner.h Created 6 years, 11 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 | « cc/resources/picture_pile.cc ('k') | cc/resources/pixel_buffer_raster_worker_pool.h » ('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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 #include <algorithm> 5 #include <algorithm>
6 #include <limits> 6 #include <limits>
7 7
8 #include "base/debug/trace_event.h" 8 #include "base/debug/trace_event.h"
9 #include "cc/base/region.h" 9 #include "cc/base/region.h"
10 #include "cc/debug/debug_colors.h" 10 #include "cc/debug/debug_colors.h"
11 #include "cc/resources/picture_pile_impl.h" 11 #include "cc/resources/picture_pile_impl.h"
12 #include "cc/resources/worker_pool.h" 12 #include "cc/resources/raster_worker_pool.h"
13 #include "skia/ext/analysis_canvas.h" 13 #include "skia/ext/analysis_canvas.h"
14 #include "third_party/skia/include/core/SkCanvas.h" 14 #include "third_party/skia/include/core/SkCanvas.h"
15 #include "third_party/skia/include/core/SkSize.h" 15 #include "third_party/skia/include/core/SkSize.h"
16 #include "ui/gfx/rect_conversions.h" 16 #include "ui/gfx/rect_conversions.h"
17 #include "ui/gfx/size_conversions.h" 17 #include "ui/gfx/size_conversions.h"
18 #include "ui/gfx/skia_util.h" 18 #include "ui/gfx/skia_util.h"
19 19
20 namespace cc { 20 namespace cc {
21 21
22 PicturePileImpl::ClonesForDrawing::ClonesForDrawing( 22 PicturePileImpl::ClonesForDrawing::ClonesForDrawing(
(...skipping 22 matching lines...) Expand all
45 return make_scoped_refptr(new PicturePileImpl(other, thread_index)); 45 return make_scoped_refptr(new PicturePileImpl(other, thread_index));
46 } 46 }
47 47
48 PicturePileImpl::PicturePileImpl() 48 PicturePileImpl::PicturePileImpl()
49 : clones_for_drawing_(ClonesForDrawing(this, 0)) { 49 : clones_for_drawing_(ClonesForDrawing(this, 0)) {
50 } 50 }
51 51
52 PicturePileImpl::PicturePileImpl(const PicturePileBase* other) 52 PicturePileImpl::PicturePileImpl(const PicturePileBase* other)
53 : PicturePileBase(other), 53 : PicturePileBase(other),
54 clones_for_drawing_(ClonesForDrawing( 54 clones_for_drawing_(ClonesForDrawing(
55 this, WorkerPool::GetNumRasterThreads())) { 55 this, RasterWorkerPool::GetNumRasterThreads())) {
56 } 56 }
57 57
58 PicturePileImpl::PicturePileImpl( 58 PicturePileImpl::PicturePileImpl(
59 const PicturePileImpl* other, unsigned thread_index) 59 const PicturePileImpl* other, unsigned thread_index)
60 : PicturePileBase(other, thread_index), 60 : PicturePileBase(other, thread_index),
61 clones_for_drawing_(ClonesForDrawing(this, 0)) { 61 clones_for_drawing_(ClonesForDrawing(this, 0)) {
62 } 62 }
63 63
64 PicturePileImpl::~PicturePileImpl() { 64 PicturePileImpl::~PicturePileImpl() {
65 } 65 }
(...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after
407 ++it) { 407 ++it) {
408 Picture* picture = it->second.GetPicture(); 408 Picture* picture = it->second.GetPicture();
409 if (picture && (processed_pictures.count(picture) == 0)) { 409 if (picture && (processed_pictures.count(picture) == 0)) {
410 picture->EmitTraceSnapshot(); 410 picture->EmitTraceSnapshot();
411 processed_pictures.insert(picture); 411 processed_pictures.insert(picture);
412 } 412 }
413 } 413 }
414 } 414 }
415 415
416 } // namespace cc 416 } // namespace cc
OLDNEW
« no previous file with comments | « cc/resources/picture_pile.cc ('k') | cc/resources/pixel_buffer_raster_worker_pool.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698