Custom ImageView class not working with Picasso image downloading library

前端 未结 2 1734
暖寄归人
暖寄归人 2021-02-09 06:53

I have recently extended from an ImageView to create a CircularImageView class which makes the image circular with a coloured border. This is done via the onDraw(canvas) method

2条回答
  •  南旧
    南旧 (楼主)
    2021-02-09 07:05

    For circular images using Picasso, use this class that implements Transformation.

    Picasso.with(context).load(url).transform(new RoundedTransformation(radius, margin)).into(imageview);
    

提交回复
热议问题