Package pl.droidsonroids.gif.transforms
Interface Transform
- All Known Implementing Classes:
CornerRadiusTransform
public interface Transform
Interface to support clients performing custom transformations before the current GIF Bitmap is drawn.
-
Method Summary
Modifier and Type Method Description voidonBoundsChange(Rect bounds)Called byGifDrawablewhen its bounds changes byGifDrawable.onBoundsChange(Rect)and when transform is associated usingGifDrawable.setTransform(Transform).voidonDraw(Canvas canvas, Paint paint, Bitmap buffer)Called byGifDrawablewhen itsGifDrawable.draw(Canvas)is called.
-
Method Details
-
onBoundsChange
Called byGifDrawablewhen its bounds changes byGifDrawable.onBoundsChange(Rect)and when transform is associated usingGifDrawable.setTransform(Transform). In this latter case the latestGifDrawablebounds (emptyRectif they were not set yet).- Parameters:
bounds- new bounds
-
onDraw
Called byGifDrawablewhen itsGifDrawable.draw(Canvas)is called.- Parameters:
canvas- The canvas supplied by the system to draw on.paint- The paint to use for custom drawing.buffer- The current Bitmap for the GIF.
-