-
public class AnimatedImageCompositorContains the logic for compositing the frames of an AnimatedImage. Animated image formats like GIF and WebP support inter-frame compression where a subsequent frame may require being blended on a previous frame in order to render the full frame. This class encapsulates the behavior to be able to render any frame of the image. Designed to work with a cache via a Callback.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public interfaceAnimatedImageCompositor.CallbackCallback for caching.
-
Constructor Summary
Constructors Constructor Description AnimatedImageCompositor(AnimatedDrawableBackend animatedDrawableBackend, boolean isNewRenderImplementation, AnimatedImageCompositor.Callback callback)
-
Method Summary
Modifier and Type Method Description voidrenderDeltas(int frameNumber, Bitmap baseBitmap)voidrenderFrame(int frameNumber, Bitmap bitmap)Renders the specified frame. -
-
Constructor Detail
-
AnimatedImageCompositor
AnimatedImageCompositor(AnimatedDrawableBackend animatedDrawableBackend, boolean isNewRenderImplementation, AnimatedImageCompositor.Callback callback)
-
-
Method Detail
-
renderDeltas
void renderDeltas(int frameNumber, Bitmap baseBitmap)
-
renderFrame
void renderFrame(int frameNumber, Bitmap bitmap)
Renders the specified frame. Only should be called on the rendering thread.
- Parameters:
frameNumber- the frame to renderbitmap- the bitmap to render into
-
-
-
-