| 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 "platform/graphics/UnacceleratedStaticBitmapImage.h" | 5 #include "platform/graphics/UnacceleratedStaticBitmapImage.h" |
| 6 | 6 |
| 7 #include "third_party/skia/include/core/SkImage.h" | 7 #include "third_party/skia/include/core/SkImage.h" |
| 8 | 8 |
| 9 namespace blink { | 9 namespace blink { |
| 10 | 10 |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 | 27 |
| 28 bool UnacceleratedStaticBitmapImage::currentFrameKnownToBeOpaque(MetadataMode) { | 28 bool UnacceleratedStaticBitmapImage::currentFrameKnownToBeOpaque(MetadataMode) { |
| 29 return m_image->isOpaque(); | 29 return m_image->isOpaque(); |
| 30 } | 30 } |
| 31 | 31 |
| 32 void UnacceleratedStaticBitmapImage::draw(PaintCanvas* canvas, | 32 void UnacceleratedStaticBitmapImage::draw(PaintCanvas* canvas, |
| 33 const PaintFlags& flags, | 33 const PaintFlags& flags, |
| 34 const FloatRect& dstRect, | 34 const FloatRect& dstRect, |
| 35 const FloatRect& srcRect, | 35 const FloatRect& srcRect, |
| 36 RespectImageOrientationEnum, | 36 RespectImageOrientationEnum, |
| 37 ImageClampingMode clampMode, | 37 ImageClampingMode clampMode) { |
| 38 const ColorBehavior& colorBehavior) { | |
| 39 // TODO(ccameron): This function should not ignore |colorBehavior|. | |
| 40 // https://crbug.com/672306 | |
| 41 StaticBitmapImage::drawHelper(canvas, flags, dstRect, srcRect, clampMode, | 38 StaticBitmapImage::drawHelper(canvas, flags, dstRect, srcRect, clampMode, |
| 42 m_image); | 39 m_image); |
| 43 } | 40 } |
| 44 | 41 |
| 45 sk_sp<SkImage> UnacceleratedStaticBitmapImage::imageForCurrentFrame( | 42 sk_sp<SkImage> UnacceleratedStaticBitmapImage::imageForCurrentFrame( |
| 46 const ColorBehavior& colorBehavior) { | 43 const ColorBehavior& colorBehavior) { |
| 47 // TODO(ccameron): This function should not ignore |colorBehavior|. | 44 // TODO(ccameron): This function should not ignore |colorBehavior|. |
| 48 // https://crbug.com/672306 | 45 // https://crbug.com/672306 |
| 49 return m_image; | 46 return m_image; |
| 50 } | 47 } |
| 51 | 48 |
| 52 } // namespace blink | 49 } // namespace blink |
| OLD | NEW |