com.facebook.imagepipeline.animated.base.AnimatedDrawableCachingBackend |
![]() |
A specialized version of AnimatedDrawableBackend
that adds caching and prefetching.
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
abstract void |
appendDebugOptionString(StringBuilder sb)
Appends a string about the state of the backend that might be useful for debugging.
| ||||||||||
abstract AnimatedDrawableCachingBackend |
forNewBounds(Rect bounds)
Creates a new
AnimatedDrawableBackend with the same parameters but with a new bounds. | ||||||||||
abstract CloseableReference<Bitmap> |
getBitmapForFrame(int frameNumber)
Gets the bitmap for the specified frame number.
| ||||||||||
abstract CloseableReference<Bitmap> |
getPreviewBitmap()
Gets the bitmap for the preview frame.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Appends a string about the state of the backend that might be useful for debugging.
sb | the builder to append to |
---|
Creates a new AnimatedDrawableBackend
with the same parameters but with a new bounds.
bounds | the bounds |
---|
AnimatedDrawableBackend
with the new bounds (this may be the same instance
if the bounds don't require a new backend)
Gets the bitmap for the specified frame number. The bitmap should be the size of the
rendered image according to getRenderedWidth()
and getRenderedHeight()
and
ready to be drawn in the Drawable's draw method.
frameNumber | the frame number (0-based) |
---|
Gets the bitmap for the preview frame. This will only return non-null if the
ImageDecodeOptions
were configured to decode the preview frame.