Open m1ga opened 4 weeks ago
When you use cameraX and rotate the camera AFTER opening it in portrait mode it won't update the target rotation and the image had the wrong orientation.
Test
var win = Ti.UI.createWindow(); var img = Ti.UI.createImageView(); win.addEventListener("click", function() { Ti.Media.requestCameraPermissions(function(e) { if (e.success) { var overlay = Ti.UI.createView(); var btn = Ti.UI.createButton({ bottom: 0, title: "take" }) overlay.add(btn); Ti.Media.showCamera({ overlay: overlay, useCameraX: true, success: function(e){ img.image = e.media; } }); btn.addEventListener("click", function() { Ti.Media.takePicture(); }) } }); }) win.add(img); win.open();
Run the app and click on the screen to open the camera.
Test 2:
When you use cameraX and rotate the camera AFTER opening it in portrait mode it won't update the target rotation and the image had the wrong orientation.
Test
Run the app and click on the screen to open the camera.
Test 2: