| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef RecordingImageBufferSurface_h | 5 #ifndef RecordingImageBufferSurface_h |
| 6 #define RecordingImageBufferSurface_h | 6 #define RecordingImageBufferSurface_h |
| 7 | 7 |
| 8 #include "platform/graphics/GraphicsContext.h" | 8 #include "platform/graphics/GraphicsContext.h" |
| 9 #include "platform/graphics/ImageBufferSurface.h" | 9 #include "platform/graphics/ImageBufferSurface.h" |
| 10 #include "public/platform/WebThread.h" | 10 #include "public/platform/WebThread.h" |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 PassRefPtr<SkPicture> getPicture() override; | 38 PassRefPtr<SkPicture> getPicture() override; |
| 39 void willDrawVideo() override; | 39 void willDrawVideo() override; |
| 40 void didDraw(const FloatRect&) override; | 40 void didDraw(const FloatRect&) override; |
| 41 bool isValid() const override { return true; } | 41 bool isValid() const override { return true; } |
| 42 bool isRecording() const override { return !m_fallbackSurface; } | 42 bool isRecording() const override { return !m_fallbackSurface; } |
| 43 void willAccessPixels() override; | 43 void willAccessPixels() override; |
| 44 void willOverwriteCanvas() override; | 44 void willOverwriteCanvas() override; |
| 45 void finalizeFrame(const FloatRect&) override; | 45 void finalizeFrame(const FloatRect&) override; |
| 46 void setImageBuffer(ImageBuffer*) override; | 46 void setImageBuffer(ImageBuffer*) override; |
| 47 PassRefPtr<SkImage> newImageSnapshot() const override; | 47 PassRefPtr<SkImage> newImageSnapshot() const override; |
| 48 void draw(GraphicsContext*, const FloatRect& destRect, const FloatRect& srcR
ect, SkXfermode::Mode, bool needsCopy) override; | 48 void draw(GraphicsContext*, const FloatRect& destRect, const FloatRect& srcR
ect, SkXfermode::Mode) override; |
| 49 bool isExpensiveToPaint() override; | 49 bool isExpensiveToPaint() override; |
| 50 void setHasExpensiveOp() override { m_currentFrameHasExpensiveOp = true; } | 50 void setHasExpensiveOp() override { m_currentFrameHasExpensiveOp = true; } |
| 51 | 51 |
| 52 // Passthroughs to fallback surface | 52 // Passthroughs to fallback surface |
| 53 const SkBitmap& bitmap() override; | 53 const SkBitmap& bitmap() override; |
| 54 bool restore() override; | 54 bool restore() override; |
| 55 WebLayer* layer() const override; | 55 WebLayer* layer() const override; |
| 56 bool isAccelerated() const override; | 56 bool isAccelerated() const override; |
| 57 Platform3DObject getBackingTexture() const override; | 57 Platform3DObject getBackingTexture() const override; |
| 58 bool cachedBitmapEnabled() const override; | 58 bool cachedBitmapEnabled() const override; |
| (...skipping 19 matching lines...) Expand all Loading... |
| 78 bool m_frameWasCleared; | 78 bool m_frameWasCleared; |
| 79 bool m_didRecordDrawCommandsInCurrentFrame; | 79 bool m_didRecordDrawCommandsInCurrentFrame; |
| 80 bool m_currentFrameHasExpensiveOp; | 80 bool m_currentFrameHasExpensiveOp; |
| 81 bool m_previousFrameHasExpensiveOp; | 81 bool m_previousFrameHasExpensiveOp; |
| 82 OwnPtr<RecordingImageBufferFallbackSurfaceFactory> m_fallbackFactory; | 82 OwnPtr<RecordingImageBufferFallbackSurfaceFactory> m_fallbackFactory; |
| 83 }; | 83 }; |
| 84 | 84 |
| 85 } // namespace blink | 85 } // namespace blink |
| 86 | 86 |
| 87 #endif | 87 #endif |
| OLD | NEW |