Reputation: 35
I need to display images using Picasso library, keeping the original orientation. I'm taking pictures using Camera or from Gallery, and then upload multiple images to server using Volley.
The problem is when images are loaded, they are rotated, i.e. orientation is wrong.
How can I rotate images in both portrait or landscape mode loaded from server?
Picasso.with(getApplicationContext()).load("http://:www..." + url).into(imageView);
I tried to get exif orientation from images on server using PHP exif_read_info, but Orientation is not specified.
Upvotes: 1
Views: 723
Reputation: 377
To rotate by 90 degree use.
Picasso
.with(context)
.load("http://:www..." + url)
.rotate(90f)
.into(imageView);
Upvotes: 1