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

Side by Side Diff: third_party/WebKit/Source/core/offscreencanvas/OffscreenCanvas.cpp

Issue 2764633002: cc/paint: Remove cc::PaintSurface. (Closed)
Patch Set: fix for relanding Created 3 years, 8 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "core/offscreencanvas/OffscreenCanvas.h" 5 #include "core/offscreencanvas/OffscreenCanvas.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include "core/dom/ExceptionCode.h" 8 #include "core/dom/ExceptionCode.h"
9 #include "core/fileapi/Blob.h" 9 #include "core/fileapi/Blob.h"
10 #include "core/frame/ImageBitmap.h" 10 #include "core/frame/ImageBitmap.h"
11 #include "core/html/ImageData.h" 11 #include "core/html/ImageData.h"
12 #include "core/html/canvas/CanvasAsyncBlobCreator.h" 12 #include "core/html/canvas/CanvasAsyncBlobCreator.h"
13 #include "core/html/canvas/CanvasContextCreationAttributes.h" 13 #include "core/html/canvas/CanvasContextCreationAttributes.h"
14 #include "core/html/canvas/CanvasRenderingContext.h" 14 #include "core/html/canvas/CanvasRenderingContext.h"
15 #include "core/html/canvas/CanvasRenderingContextFactory.h" 15 #include "core/html/canvas/CanvasRenderingContextFactory.h"
16 #include "platform/graphics/Image.h" 16 #include "platform/graphics/Image.h"
17 #include "platform/graphics/ImageBuffer.h" 17 #include "platform/graphics/ImageBuffer.h"
18 #include "platform/graphics/OffscreenCanvasFrameDispatcherImpl.h" 18 #include "platform/graphics/OffscreenCanvasFrameDispatcherImpl.h"
19 #include "platform/graphics/StaticBitmapImage.h" 19 #include "platform/graphics/StaticBitmapImage.h"
20 #include "platform/image-encoders/ImageEncoderUtils.h" 20 #include "platform/image-encoders/ImageEncoderUtils.h"
21 #include "public/platform/Platform.h" 21 #include "public/platform/Platform.h"
22 #include "third_party/skia/include/core/SkSurface.h"
22 #include "wtf/MathExtras.h" 23 #include "wtf/MathExtras.h"
23 24
24 namespace blink { 25 namespace blink {
25 26
26 OffscreenCanvas::OffscreenCanvas(const IntSize& size) : m_size(size) {} 27 OffscreenCanvas::OffscreenCanvas(const IntSize& size) : m_size(size) {}
27 28
28 OffscreenCanvas* OffscreenCanvas::create(unsigned width, unsigned height) { 29 OffscreenCanvas* OffscreenCanvas::create(unsigned width, unsigned height) {
29 return new OffscreenCanvas( 30 return new OffscreenCanvas(
30 IntSize(clampTo<int>(width), clampTo<int>(height))); 31 IntSize(clampTo<int>(width), clampTo<int>(height)));
31 } 32 }
(...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after
347 } 348 }
348 349
349 DEFINE_TRACE(OffscreenCanvas) { 350 DEFINE_TRACE(OffscreenCanvas) {
350 visitor->trace(m_context); 351 visitor->trace(m_context);
351 visitor->trace(m_executionContext); 352 visitor->trace(m_executionContext);
352 visitor->trace(m_commitPromiseResolver); 353 visitor->trace(m_commitPromiseResolver);
353 EventTargetWithInlineData::trace(visitor); 354 EventTargetWithInlineData::trace(visitor);
354 } 355 }
355 356
356 } // namespace blink 357 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698