Very strange for me, occupy the same code in another application if it works on Android reverses the image in -90. Try set correctOrientation = true
does not work for me. Someone with the same error and could fix it ??
$scope.getPhoto = function() {
Camera.getPicture().then(function(imageURI) {
console.log(imageURI);
$scope.lastPhoto = imageURI;
}, function() {
//error
}, {
quality: 75,
correctOrientation: true
});
};
I think the problem is the resolution of the image depending on the device. What I did was use a parameter that cuts the image after taking a photograph. When cut, the picture came out correctly, but that was not what I needed because it is one step more to add to the flow so remove that parameter, change the image type from PNG to JPEG, identify which platform was the device and image stored correctly.
var options = {
quality: 50,
destinationType: Camera.DestinationType.FILE_URI,
encodingType: Camera.EncodingType.JPEG,
correctOrientation: true
};