aboutsummaryrefslogtreecommitdiffstats
path: root/resources
diff options
context:
space:
mode:
authorFlorin Malita <fmalita@chromium.org>2018-10-03 14:39:56 -0400
committerSkia Commit-Bot <skia-commit-bot@chromium.org>2018-10-03 19:02:35 +0000
commit62c6bd910abbb64e4fd94caf16c14c7519878a3a (patch)
tree222364ff6d12207d2e7f8d1d53404c4914a7446d /resources
parentb4d895606f77c23bd34a1b57419723f6431e3386 (diff)
downloadplatform_external_skqp-62c6bd910abbb64e4fd94caf16c14c7519878a3a.tar.gz
platform_external_skqp-62c6bd910abbb64e4fd94caf16c14c7519878a3a.tar.bz2
platform_external_skqp-62c6bd910abbb64e4fd94caf16c14c7519878a3a.zip
[skottie] Multi-frame image support
Extend the image asset provider API to support animated/multi-frame images. Add a GM based on SkAnimCodecPlayer + animated public domain GIF (source: https://giphy.com/explore/public-domain). Bug: skia: Change-Id: Iaa596e01a7626ca6574db1ebc90632f5a9a02bdc Reviewed-on: https://skia-review.googlesource.com/159162 Commit-Queue: Florin Malita <fmalita@chromium.org> Reviewed-by: Mike Reed <reed@google.com>
Diffstat (limited to 'resources')
-rw-r--r--resources/images/flightAnim.gifbin0 -> 999846 bytes
-rw-r--r--resources/skottie/skottie_sample_multiframe.json52
2 files changed, 52 insertions, 0 deletions
diff --git a/resources/images/flightAnim.gif b/resources/images/flightAnim.gif
new file mode 100644
index 0000000000..7aaa327262
--- /dev/null
+++ b/resources/images/flightAnim.gif
Binary files differ
diff --git a/resources/skottie/skottie_sample_multiframe.json b/resources/skottie/skottie_sample_multiframe.json
new file mode 100644
index 0000000000..afd78497a3
--- /dev/null
+++ b/resources/skottie/skottie_sample_multiframe.json
@@ -0,0 +1,52 @@
+{
+ "v":"4.6.9",
+ "fr":60,
+ "ip":0,
+ "op":200,
+ "w":800,
+ "h":600,
+ "ddd":0,
+
+ "assets": [
+ {
+ "id": "image_0",
+ "p": "image_0.png",
+ "u": "images/",
+ "w": 600,
+ "h": 400
+ }
+ ],
+
+ "layers":[
+ {
+ "ddd":0,
+ "ind":1,
+ "ty":2,
+ "refId": "image_0",
+ "nm":"Custom Path 1",
+ "ao": 0,
+ "ip": 0,
+ "op": 200,
+ "st": 0,
+ "sr": 1,
+ "bm": 0,
+ "ks": {
+ "o": { "a":0, "k":100 },
+ "r": { "a":1, "k": [
+ { "t": 0, "s": 0, "e": 5 },
+ { "t": 50, "s": 5, "e": -5 },
+ { "t": 150, "s": -5, "e": 0 },
+ { "t": 200 }
+ ]},
+ "p": { "a":0, "k":[ 400, 300, 0 ] },
+ "a": { "a":0, "k":[ 300, 200, 0 ] },
+ "s": { "a":1, "k":[
+ { "t": 0, "s": [ 100, 100, 100 ], "e": [ 150, 150, 100 ] },
+ { "t": 100, "s": [ 150, 150, 100 ], "e": [ 100, 100, 100 ] },
+ { "t": 200 }
+ ]}
+ }
+
+ }
+ ]
+}