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

Unified Diff: cc/trees/layer_tree_host_impl.h

Issue 1946403003: Add fixed raster scale use counter histograms. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase+fix Created 4 years, 7 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 | « cc/trees/layer_tree_host_client.h ('k') | cc/trees/layer_tree_host_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_host_impl.h
diff --git a/cc/trees/layer_tree_host_impl.h b/cc/trees/layer_tree_host_impl.h
index c60a95739ed9e2b4659c593234ba7ab4a94fd1f5..35e4591fe15316ce56acaf2d8a52a45ee57bd503 100644
--- a/cc/trees/layer_tree_host_impl.h
+++ b/cc/trees/layer_tree_host_impl.h
@@ -7,6 +7,7 @@
#include <stddef.h>
+#include <bitset>
#include <memory>
#include <set>
#include <string>
@@ -616,6 +617,16 @@ class CC_EXPORT LayerTreeHostImpl
void SetLayerTreeMutator(LayerTreeMutator* mutator);
LayerTreeMutator* mutator() { return mutator_; }
+ void set_fixed_raster_scale_has_blurry_content() {
+ has_fixed_raster_scale_blurry_content_ = true;
+ }
+ bool has_fixed_raster_scale_blurry_content() const {
+ return has_fixed_raster_scale_blurry_content_;
+ }
+
+ bool HasFixedRasterScalePotentialPerformanceRegression() const;
+ void SetFixedRasterScaleAttemptedToChangeScale();
+
protected:
LayerTreeHostImpl(
const LayerTreeSettings& settings,
@@ -643,6 +654,9 @@ class CC_EXPORT LayerTreeHostImpl
BeginFrameTracker current_begin_frame_tracker_;
private:
+ enum { kFixedRasterScaleAttemptedScaleChangeThreshold = 5 };
+ enum { kFixedRasterScaleAttemptedScaleChangeHistoryCount = 10 };
+
gfx::Vector2dF ScrollNodeWithViewportSpaceDelta(
ScrollNode* scroll_node,
const gfx::PointF& viewport_point,
@@ -846,6 +860,10 @@ class CC_EXPORT LayerTreeHostImpl
LayerTreeMutator* mutator_;
+ bool has_fixed_raster_scale_blurry_content_;
+ std::bitset<kFixedRasterScaleAttemptedScaleChangeHistoryCount>
+ fixed_raster_scale_attempted_scale_change_history_;
+
DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl);
};
« no previous file with comments | « cc/trees/layer_tree_host_client.h ('k') | cc/trees/layer_tree_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698