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

Unified Diff: third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp

Issue 2362363002: Cancel GPU acceleration for 2D canvas when drawing very large images (Closed)
Patch Set: fix sqrt Created 4 years, 3 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/core/html/HTMLCanvasElement.cpp
diff --git a/third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp b/third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp
index 863a5902d7ad72791f99b55ac916b4d2b83961b7..b3af91e1b1a561ae7d2324cc4961a06294699eab 100644
--- a/third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp
+++ b/third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp
@@ -281,6 +281,11 @@ bool HTMLCanvasElement::isPaintable() const
return (m_context && m_context->isPaintable()) || ImageBuffer::canCreateImageBuffer(size());
}
+bool HTMLCanvasElement::isAccelerated() const
+{
+ return m_context && m_context->isAccelerated();
+}
+
void HTMLCanvasElement::didDraw(const FloatRect& rect)
{
if (rect.isEmpty())
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLCanvasElement.h ('k') | third_party/WebKit/Source/core/html/HTMLImageElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698