Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to use Glide to transform the images loaded on an ImageView that came from the Gallery or sdcard?

So I have learned how to use glide to load images from a server and transform them and it works nicely.

But now, I want to know how I can use the same transformations on an image I have set to the ImageView before I set it as src?

like image 600
John Ernest Guadalupe Avatar asked Nov 18 '25 22:11

John Ernest Guadalupe


1 Answers

You can use it in same way as for images from the server Glide.with(context).load(uri).transform(new Transform()).into(view) where uri is your local uri of the picture, and Transform is a class of your transformation.

like image 151
Ilya Vorobiev Avatar answered Nov 21 '25 14:11

Ilya Vorobiev



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!