Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CC_PAINT_PAINT_IMAGE_H_ | |
| 6 #define CC_PAINT_PAINT_IMAGE_H_ | |
| 7 | |
| 8 #include "cc/paint/paint_export.h" | |
| 9 | |
| 10 #include "third_party/skia/include/core/SkImage.h" | |
| 11 | |
| 12 namespace cc { | |
| 13 | |
| 14 class CC_PAINT_EXPORT PaintImage { | |
|
Khushal
2017/04/11 02:19:46
Add a TODO for a persistent id for PaintImage, whi
vmpstr
2017/04/11 18:58:33
Done.
| |
| 15 public: | |
| 16 // TODO(vmpstr): Work towards removing "UNKNOWN" value. | |
| 17 enum class AnimationType { UNKNOWN, ANIMATED, STATIC }; | |
|
Khushal
2017/04/11 02:19:46
Do you think we actually need the animation and co
vmpstr
2017/04/11 18:58:33
I'd rather keep the logic for deciding that in cc.
Khushal
2017/04/11 20:55:01
We are using ANIMATED here for the frames in skcan
| |
| 18 | |
| 19 // TODO(vmpstr): Work towards removing "UNKNOWN" value. | |
| 20 enum class CompletionState { UNKNOWN, DONE, PARTIALLY_DONE }; | |
| 21 | |
| 22 PaintImage(sk_sp<const SkImage> sk_image, | |
| 23 AnimationType animation_type, | |
| 24 CompletionState completion_state); | |
| 25 ~PaintImage(); | |
| 26 | |
| 27 const sk_sp<const SkImage>& sk_image() const { return sk_image_; } | |
| 28 AnimationType animation_type() const { return animation_type_; } | |
| 29 CompletionState completion_state() const { return completion_state_; } | |
| 30 | |
| 31 private: | |
| 32 sk_sp<const SkImage> sk_image_; | |
| 33 AnimationType animation_type_; | |
| 34 CompletionState completion_state_; | |
| 35 }; | |
| 36 | |
| 37 } // namespace cc | |
| 38 | |
| 39 #endif // CC_PAINT_PAINT_IMAGE_H_ | |
| OLD | NEW |