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

Unified Diff: third_party/WebKit/Source/core/frame/ImageBitmap.h

Issue 2026803002: Avoid GPU readback in tex(Sub)Image2D(ImageBitmap) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address kbr@'s comments Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/frame/ImageBitmap.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/frame/ImageBitmap.h
diff --git a/third_party/WebKit/Source/core/frame/ImageBitmap.h b/third_party/WebKit/Source/core/frame/ImageBitmap.h
index 102232a3b496cb80c1571df51ed04b74005d27da..7e7de12b6764a0b07e308bcbac6e02b27576aa75 100644
--- a/third_party/WebKit/Source/core/frame/ImageBitmap.h
+++ b/third_party/WebKit/Source/core/frame/ImageBitmap.h
@@ -59,6 +59,7 @@ public:
bool isPremultiplied() const { return m_image->isPremultiplied(); }
PassRefPtr<StaticBitmapImage> transfer();
void close();
+ bool isTextureBacked() const;
~ImageBitmap() override;
@@ -68,6 +69,8 @@ public:
void adjustDrawRects(FloatRect* srcRect, FloatRect* dstRect) const override;
FloatSize elementSize(const FloatSize&) const override;
bool isImageBitmap() const override { return true; }
+ int sourceWidth() override { return m_image ? m_image->width() : 0; }
+ int sourceHeight() override { return m_image ? m_image->height() : 0; }
// ImageBitmapSource implementation
IntSize bitmapSourceSize() const override { return size(); }
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/frame/ImageBitmap.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698