skia2/include
Leon Scroggins III 7a10b332a3 Add an SkDrawable for animated images (e.g. GIF)
Bug: b/63909536

SkAnimatedImage is a simple drawable for animating a GIF. Thread-safety
is left up to the client. At most two bitmaps are stored in the
drawable; one for the current frame and one for a frame that may need to
be restored. The backup frame prevents some cases where we would
otherwise have to re-decode from the beginning of the image.

The API lets the client set the time value, and decodes to match that
time.

TODO:
- Callback for when the animation is complete
- Ability to use SkAndroidCodec
- Modify the loop count (or leave that up to client?)
- Better and/or client-specific caching

Other changes:
- Add a sample which animates a GIF
- Reenable SK_CODEC_PRINTF for debug builds and Android

Change-Id: I945ffbccdb6008f2a05ed4d9b2af869a261fb300
Reviewed-on: https://skia-review.googlesource.com/93420
Reviewed-by: Derek Sollenberger <djsollen@google.com>
Commit-Queue: Leon Scroggins <scroggo@google.com>
2018-01-12 19:36:11 +00:00
..
android Add SK_API to APIs used by the android framework. 2017-09-21 18:14:36 +00:00
atlastext Add matrix stack to SkAtlasTextTarget. 2017-12-20 14:00:44 +00:00
c C API: document sk_matrix_t 2017-03-21 18:04:34 +00:00
codec Add an SkDrawable for animated images (e.g. GIF) 2018-01-12 19:36:11 +00:00
config Revert "Revert "SkUserConfig.h: remove out-of-date comment on SK_SFNTLY_SUBSETTER"" 2017-01-27 14:40:01 +00:00
core restore intersect methods to use old-style empty-checks on their inputs 2018-01-10 20:39:33 +00:00
effects Revert "Alloc glyph image correctly for SkMask::k3D_Format." 2017-11-14 16:16:45 +00:00
encode Revert "Add an Option for orientation on JPEG encodes" 2017-10-18 18:09:47 +00:00
gpu Added SkSL workaround for devices which cannot safely access gl_FragCoord 2018-01-12 19:26:00 +00:00
pathops Remove trailing whitespace. 2017-10-09 21:20:34 +00:00
ports removed dead code behind legacy fontmgr api flag 2017-10-11 15:18:57 +00:00
private Updating lazy proxys to support the case where we know a lot more info about the texture. 2018-01-12 19:36:08 +00:00
svg Add a SkWStream-based SkSVGCanvas factory 2017-09-19 20:33:19 +00:00
utils Fix alpha contribution to tonal color. 2017-12-19 19:27:06 +00:00
views [Viewer] Preserve gesture transformation matrix on slide/backend change 2018-01-05 18:18:39 +00:00