【问题标题】:Glide: show image with radius corners only on top滑行:仅在顶部显示带有半径角的图像
【发布时间】:2017-11-17 12:45:31
【问题描述】:

我使用 Glide。这里sn-p:

Glide.with(context).load(referenceUrl).into(holder.imageViewPhoto);

好的。它工作正常。 但我需要仅在 TOP 上显示半径角的图像。

类似这样的:

Glide 可以吗?

【问题讨论】:

标签: android android-glide


【解决方案1】:

你可以使用:

requestOptions.centerInside().transform(new CenterInside(), new GranularRoundedCorners(topLeft, topRight, bottomRight, bottomLeft))

【讨论】:

  • GranularRoundedCorners 从何而来?
  • @GudniPall GranularRoundedCorners 是 Gilide 库的一部分。升级到最新版本的库。
  • 谢谢。抱歉,我以为我有最新版本。
猜你喜欢
  • 2023-04-01
  • 1970-01-01
  • 2020-03-24
  • 1970-01-01
  • 1970-01-01
  • 2016-06-08
  • 2022-11-18
  • 2019-06-21
  • 2020-12-21
相关资源
最近更新 更多