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/layers/picture_layer_impl.cc

Issue 1196553009: Revert "cc: Make tiling interest rect calc based on viewport." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: revert extra bools. Created 5 years, 6 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
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 "cc/layers/picture_layer_impl.h" 5 #include "cc/layers/picture_layer_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 #include <limits> 9 #include <limits>
10 #include <set> 10 #include <set>
(...skipping 1119 matching lines...) Expand 10 before | Expand all | Expand 10 after
1130 1130
1131 float PictureLayerImpl::MaximumTilingContentsScale() const { 1131 float PictureLayerImpl::MaximumTilingContentsScale() const {
1132 float max_contents_scale = tilings_->GetMaximumContentsScale(); 1132 float max_contents_scale = tilings_->GetMaximumContentsScale();
1133 return std::max(max_contents_scale, MinimumContentsScale()); 1133 return std::max(max_contents_scale, MinimumContentsScale());
1134 } 1134 }
1135 1135
1136 scoped_ptr<PictureLayerTilingSet> 1136 scoped_ptr<PictureLayerTilingSet>
1137 PictureLayerImpl::CreatePictureLayerTilingSet() { 1137 PictureLayerImpl::CreatePictureLayerTilingSet() {
1138 const LayerTreeSettings& settings = layer_tree_impl()->settings(); 1138 const LayerTreeSettings& settings = layer_tree_impl()->settings();
1139 return PictureLayerTilingSet::Create( 1139 return PictureLayerTilingSet::Create(
1140 GetTree(), this, settings.tiling_interest_area_viewport_multiplier, 1140 GetTree(), this, settings.max_tiles_for_interest_area,
1141 layer_tree_impl()->use_gpu_rasterization() 1141 layer_tree_impl()->use_gpu_rasterization()
1142 ? settings.gpu_rasterization_skewport_target_time_in_seconds 1142 ? settings.gpu_rasterization_skewport_target_time_in_seconds
1143 : settings.skewport_target_time_in_seconds, 1143 : settings.skewport_target_time_in_seconds,
1144 settings.skewport_extrapolation_limit_in_content_pixels); 1144 settings.skewport_extrapolation_limit_in_content_pixels);
1145 } 1145 }
1146 1146
1147 void PictureLayerImpl::UpdateIdealScales() { 1147 void PictureLayerImpl::UpdateIdealScales() {
1148 DCHECK(CanHaveTilings()); 1148 DCHECK(CanHaveTilings());
1149 1149
1150 float min_contents_scale = MinimumContentsScale(); 1150 float min_contents_scale = MinimumContentsScale();
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
1233 1233
1234 bool PictureLayerImpl::IsOnActiveOrPendingTree() const { 1234 bool PictureLayerImpl::IsOnActiveOrPendingTree() const {
1235 return !layer_tree_impl()->IsRecycleTree(); 1235 return !layer_tree_impl()->IsRecycleTree();
1236 } 1236 }
1237 1237
1238 bool PictureLayerImpl::HasValidTilePriorities() const { 1238 bool PictureLayerImpl::HasValidTilePriorities() const {
1239 return IsOnActiveOrPendingTree() && IsDrawnRenderSurfaceLayerListMember(); 1239 return IsOnActiveOrPendingTree() && IsDrawnRenderSurfaceLayerListMember();
1240 } 1240 }
1241 1241
1242 } // namespace cc 1242 } // namespace cc
OLDNEW
« no previous file with comments | « cc/debug/rasterize_and_record_benchmark_impl.cc ('k') | cc/layers/picture_layer_impl_perftest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698