首页 > 解决方案 > 对动态字段使用 FFImageloading RoundedTranformation。

问题描述

您好我想将 RoundedTransformation 应用于 XamarinForms 中动态创建的 CachedImage。

这是动态创建 CachedImage 的代码

var imgProd = new CachedImage { Source = temp.imgSource, HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand, Margin = 0, DownsampleHeight = vm.featureStackHeight, DownsampleToViewSize = true, Aspect = Aspect.Fill};

标签: xamarin.formsffimageloading

解决方案


当然,去吧:

imgProd.Transformations.Add(new CircleTransformation());

推荐阅读