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

Unified Diff: cc/debug/rasterize_and_record_benchmark_impl.cc

Issue 1531013004: cc: Do solid color analysis before scheduling tiles. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: test updated. Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | cc/playback/display_list_raster_source.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/debug/rasterize_and_record_benchmark_impl.cc
diff --git a/cc/debug/rasterize_and_record_benchmark_impl.cc b/cc/debug/rasterize_and_record_benchmark_impl.cc
index de6817005d4bd56648167de694d1fa66ed954e70..86340ab5731d8189b1748e10d3251121613084fb 100644
--- a/cc/debug/rasterize_and_record_benchmark_impl.cc
+++ b/cc/debug/rasterize_and_record_benchmark_impl.cc
@@ -43,20 +43,19 @@ void RunBenchmark(DisplayListRasterSource* raster_source,
LapTimer timer(kWarmupRuns,
base::TimeDelta::FromMilliseconds(kTimeLimitMillis),
kTimeCheckInterval);
+ SkColor color = SK_ColorTRANSPARENT;
+ *is_solid_color = raster_source->PerformSolidColorAnalysis(
+ content_rect, contents_scale, &color);
+
do {
SkBitmap bitmap;
bitmap.allocPixels(SkImageInfo::MakeN32Premul(content_rect.width(),
content_rect.height()));
SkCanvas canvas(bitmap);
- DisplayListRasterSource::SolidColorAnalysis analysis;
- raster_source->PerformSolidColorAnalysis(content_rect, contents_scale,
- &analysis);
raster_source->PlaybackToCanvas(&canvas, content_rect, content_rect,
contents_scale);
- *is_solid_color = analysis.is_solid_color;
-
timer.NextLap();
} while (!timer.HasTimeLimitExpired());
base::TimeDelta duration =
« no previous file with comments | « no previous file | cc/playback/display_list_raster_source.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698