Glide圆角

您所在的位置:网站首页 glide圆角原理 Glide圆角

Glide圆角

2024-01-25 18:52| 来源: 网络整理| 查看: 265

需要引入: implementation ‘jp.wasabeef:glide-transformations:3.3.0’

protected void onCreate(@Nullable Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_glide);

String url = "https://avatar.csdn.net/9/7/A/3_zhangphil.jpg"; // 原图处理成圆角. // 如果是四周都是圆角则是RoundedCornersTransformation.CornerType.ALL ImageView image = findViewById(R.id.image); Glide.with(this) .load(url) .apply(bitmapTransform(new RoundedCornersTransformation(200, 0, RoundedCornersTransformation.CornerType.ALL))) .into(image); }


【本文地址】


今日新闻


推荐新闻


CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3