Android - when getting images from Gallery, they are with wrong orientation.
For example, if they are landscape images, they are ok, but if they are portrait, they are rotated 90 degrees and again shown as landscape.
This is how I start the activity for picking images:
Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
intent.setType("image/*");
And when I get the path, this is how I decode the image:
userPic = BitmapFactory.decodeFile(path);
How can I workaround/fix this issue? Is there anything I am doing wrong?