| Index: third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp
|
| diff --git a/third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp b/third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp
|
| index 526b9fb656f544c1aa9ecb33fb014edb31cc774f..2e04b9fc7bb800ba543c0af403f534c5e3fe25a7 100644
|
| --- a/third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp
|
| +++ b/third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp
|
| @@ -61,6 +61,23 @@ ImageBitmap* OffscreenCanvas::transferToImageBitmap(ExceptionState& exceptionSta
|
| return image;
|
| }
|
|
|
| +PassRefPtr<Image> OffscreenCanvas::getSourceImageForCanvas(SourceImageStatus* status, AccelerationHint, SnapshotReason reason, const FloatSize&) const
|
| +{
|
| + if (!m_context) {
|
| + *status = InvalidSourceImageStatus;
|
| + return nullptr;
|
| + }
|
| + *status = NormalSourceImageStatus;
|
| + return m_context->getImage(reason);
|
| +}
|
| +
|
| +bool OffscreenCanvas::isOpaque() const
|
| +{
|
| + if (!m_context)
|
| + return false;
|
| + return !m_context->hasAlpha();
|
| +}
|
| +
|
| CanvasRenderingContext* OffscreenCanvas::getCanvasRenderingContext(ScriptState* scriptState, const String& id, const CanvasContextCreationAttributes& attributes)
|
| {
|
| CanvasRenderingContext::ContextType contextType = CanvasRenderingContext::contextTypeFromId(id);
|
|
|