Closed wuxiangpeng closed 1 year ago
Transformation circleCrop = new CircleCrop(); GlideApp.with(context) .load(url) .optionalTransform(circleCrop) .optionalTransform(WebpDrawable.class, new WebpDrawableTransformation(circleCrop)) .into(iv);
默认会根据ImageView的大小进行降采样缩放图片,如果不需要可以使用Glide的API override width/height
Transformation circleCrop = new CircleCrop();
GlideApp.with(context)
.load(url)
.optionalTransform(circleCrop)
.optionalTransform(WebpDrawable.class, new WebpDrawableTransformation(circleCrop))
.into(iv);