As you saw in ImageView , this is a limitation for Android. However, I am making some changes to the types of the Fresco scale, and this will be possible to do as soon as I push my changes.
In short, instead of ScaleType being Enum (which is very inflexible), ScaleType changes as an interface that can be implemented for arbitrary scaling. This change has been planted domestically and will soon be transferred to GitHub.
In addition to the above, I am working on an implementation of InterpolatingScaleType, which simply interpolates between the two basic types of scale based on the interpolation value (0.0 - 1.0). A value of 0.0 returns the same transform as the base scaleType1, while a value of 1.0 returns the same transform as the base scaleType2. Between the values ββthere is a linear combination between them.
InterpolatingScaleType allows you to smoothly interpolate between two different types of scales that are convenient in animations, for example, when performing a transition to a view.
Once this is ready, I will update this answer.
EDIT:
@burzumrus was kind enough to provide the implementation you can find here on GitHub . There is also thread on this issue on the Fresco GitHub page.
source share