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

Unified Diff: third_party/WebKit/Source/platform/graphics/ExpensiveCanvasHeuristicParameters.h

Issue 2687073003: Make disabling 2d canvas GPU acceleration for getImageData less aggressive. (Closed)
Patch Set: Address comments Created 3 years, 10 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: third_party/WebKit/Source/platform/graphics/ExpensiveCanvasHeuristicParameters.h
diff --git a/third_party/WebKit/Source/platform/graphics/ExpensiveCanvasHeuristicParameters.h b/third_party/WebKit/Source/platform/graphics/ExpensiveCanvasHeuristicParameters.h
index 3fbcba25c6fc5aa2fd80d8728e68a2a9cc3e97b8..340d96c18cdad3d3be5e7ccd661c0d8d67cdac16 100644
--- a/third_party/WebKit/Source/platform/graphics/ExpensiveCanvasHeuristicParameters.h
+++ b/third_party/WebKit/Source/platform/graphics/ExpensiveCanvasHeuristicParameters.h
@@ -78,7 +78,11 @@ enum {
// GPU readback prevention heuristics
//====================================
- GetImageDataForcesNoAcceleration = 1,
+ GPUReadbackForcesNoAcceleration = 1,
+
+ // When gpu readback is successively invoked in following number of frames,
+ // we disable gpu acceleration to avoid the high cost of gpu readback.
+ GPUReadbackMinSuccessiveFrames = 3,
// When a canvas is used as a source image, if its destination is
// non-accelerated and the source canvas is accelerated, a readback

Powered by Google App Engine
This is Rietveld 408576698