| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "modules/offscreencanvas2d/OffscreenCanvasRenderingContext2D.h" | 5 #include "modules/offscreencanvas2d/OffscreenCanvasRenderingContext2D.h" |
| 6 | 6 |
| 7 #include "bindings/modules/v8/OffscreenCanvasRenderingContext2DOrWebGLRenderingC
ontextOrWebGL2RenderingContext.h" | 7 #include "bindings/modules/v8/OffscreenCanvasRenderingContext2DOrWebGLRenderingC
ontextOrWebGL2RenderingContext.h" |
| 8 #include "core/frame/ImageBitmap.h" | 8 #include "core/frame/ImageBitmap.h" |
| 9 #include "core/frame/Settings.h" | 9 #include "core/frame/Settings.h" |
| 10 #include "core/workers/WorkerGlobalScope.h" | 10 #include "core/workers/WorkerGlobalScope.h" |
| 11 #include "core/workers/WorkerSettings.h" | 11 #include "core/workers/WorkerSettings.h" |
| 12 #include "platform/graphics/ImageBuffer.h" | 12 #include "platform/graphics/ImageBuffer.h" |
| 13 #include "platform/graphics/StaticBitmapImage.h" | 13 #include "platform/graphics/StaticBitmapImage.h" |
| 14 #include "platform/graphics/UnacceleratedImageBufferSurface.h" | 14 #include "platform/graphics/UnacceleratedImageBufferSurface.h" |
| 15 #include "platform/graphics/gpu/AcceleratedImageBufferSurface.h" | 15 #include "platform/graphics/gpu/AcceleratedImageBufferSurface.h" |
| 16 #include "platform/graphics/paint/PaintCanvas.h" | 16 #include "platform/graphics/paint/PaintCanvas.h" |
| 17 #include "wtf/Assertions.h" | 17 #include "platform/wtf/Assertions.h" |
| 18 #include "wtf/CurrentTime.h" | 18 #include "platform/wtf/CurrentTime.h" |
| 19 | 19 |
| 20 namespace blink { | 20 namespace blink { |
| 21 | 21 |
| 22 OffscreenCanvasRenderingContext2D::~OffscreenCanvasRenderingContext2D() {} | 22 OffscreenCanvasRenderingContext2D::~OffscreenCanvasRenderingContext2D() {} |
| 23 | 23 |
| 24 OffscreenCanvasRenderingContext2D::OffscreenCanvasRenderingContext2D( | 24 OffscreenCanvasRenderingContext2D::OffscreenCanvasRenderingContext2D( |
| 25 ScriptState* script_state, | 25 ScriptState* script_state, |
| 26 OffscreenCanvas* canvas, | 26 OffscreenCanvas* canvas, |
| 27 const CanvasContextCreationAttributes& attrs) | 27 const CanvasContextCreationAttributes& attrs) |
| 28 : CanvasRenderingContext(nullptr, canvas, attrs) { | 28 : CanvasRenderingContext(nullptr, canvas, attrs) { |
| (...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 252 } | 252 } |
| 253 | 253 |
| 254 bool OffscreenCanvasRenderingContext2D::IsPaintable() const { | 254 bool OffscreenCanvasRenderingContext2D::IsPaintable() const { |
| 255 return this->GetImageBuffer(); | 255 return this->GetImageBuffer(); |
| 256 } | 256 } |
| 257 | 257 |
| 258 bool OffscreenCanvasRenderingContext2D::IsAccelerated() const { | 258 bool OffscreenCanvasRenderingContext2D::IsAccelerated() const { |
| 259 return image_buffer_ && image_buffer_->IsAccelerated(); | 259 return image_buffer_ && image_buffer_->IsAccelerated(); |
| 260 } | 260 } |
| 261 } | 261 } |
| OLD | NEW |