{ "id": "173300", "key": "TIMOB-26925", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [], "resolution": { "id": "11", "description": "Is not a bug in our product", "name": "Not Our Bug" }, "resolutiondate": "2019-08-02T17:16:50.000+0000", "created": "2019-03-27T08:44:00.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "applebug", "cropped", "engSchedule", "gallery", "image" ], "versions": [ { "id": "19882", "name": "Release 8.0.0", "archived": false, "released": true, "releaseDate": "2019-03-14" }, { "id": "20429", "name": "Release 7.5.1", "archived": false, "released": true, "releaseDate": "2019-02-26" } ], "issuelinks": [ { "id": "57487", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "inwardIssue": { "id": "169870", "key": "TIMOB-25336", "fields": { "summary": "iOS 11: openPhotoGallery/allowEditing does not crop correctly. ", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "Critical", "id": "1" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2019-08-02T17:16:50.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "h6.Reproduce Steps\r\n1. Download any image of resolution(3264 X 2448) for testing purpose. (Attached test image)\r\n2. Run the following example code in a default alloy app.\r\n3. Drag the test image over to simulator.\r\n4. Run the example app, click on the Hello World text of the application and select the testing image from the gallery.\r\n5. Go to simulator folder, then check the saved image. For example in my test, the location is: (~/sliang⁩/⁨Library⁩/⁨Developer⁩/⁨CoreSimulator⁩/⁨Devices⁩/⁨9080930F-2320-4FF3-A042-D7955440EACE⁩/⁨data⁩/⁨Containers⁩/Data/⁨Application⁩/8D3292C5-4578-4B59-8956-29C36AB23BFF⁩/Documents⁩)\r\n\r\nh6.Problem\r\nOpen the image, you will see the resolution is only 3073 X 2305 and it get cropped at right side and bottom side. \r\n\r\nh6.Expect\r\nThe image should not get cropped.", "attachment": [ { "id": "66544", "filename": "Img.zip", "author": { "name": "sliang", "key": "sliang", "displayName": "Shuo Liang", "active": true, "timeZone": "Asia/Harbin" }, "created": "2019-04-05T08:27:52.000+0000", "size": 6942206, "mimeType": "application/zip" }, { "id": "66420", "filename": "index.js", "author": { "name": "sliang", "key": "sliang", "displayName": "Shuo Liang", "active": true, "timeZone": "Asia/Harbin" }, "created": "2019-03-27T08:43:22.000+0000", "size": 934, "mimeType": "text/javascript" }, { "id": "66421", "filename": "originalImage.jpg", "author": { "name": "sliang", "key": "sliang", "displayName": "Shuo Liang", "active": true, "timeZone": "Asia/Harbin" }, "created": "2019-03-27T08:42:41.000+0000", "size": 868435, "mimeType": "image/jpeg" }, { "id": "66552", "filename": "TestCameraImage.zip", "author": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-04-12T23:28:47.000+0000", "size": 53764, "mimeType": "application/zip" } ], "flagged": false, "summary": "IOS: select Image from gallery but got cropped unexpected", "creator": { "name": "sliang", "key": "sliang", "displayName": "Shuo Liang", "active": true, "timeZone": "Asia/Harbin" }, "subtasks": [], "reporter": { "name": "sliang", "key": "sliang", "displayName": "Shuo Liang", "active": true, "timeZone": "Asia/Harbin" }, "environment": "iOS 12\r\nSDK 7.4.0 - 8.0.0.GA", "comment": { "comments": [ { "id": "447464", "author": { "name": "sliang", "key": "sliang", "displayName": "Shuo Liang", "active": true, "timeZone": "Asia/Harbin" }, "body": "Any update?", "updateAuthor": { "name": "sliang", "key": "sliang", "displayName": "Shuo Liang", "active": true, "timeZone": "Asia/Harbin" }, "created": "2019-04-04T05:30:52.000+0000", "updated": "2019-04-04T05:30:52.000+0000" }, { "id": "447488", "author": { "name": "sliang", "key": "sliang", "displayName": "Shuo Liang", "active": true, "timeZone": "Asia/Harbin" }, "body": "[~vijaysingh]\r\nCustomer replied that they tried to replicate the issue with a native Xcode project but this issue is not happening there. This is only happening in our project. They are using Xcode 9. Attached is the native project.", "updateAuthor": { "name": "sliang", "key": "sliang", "displayName": "Shuo Liang", "active": true, "timeZone": "Asia/Harbin" }, "created": "2019-04-05T08:23:26.000+0000", "updated": "2019-04-05T08:23:26.000+0000" }, { "id": "447535", "author": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "body": "I can see that issue is there with iOS 11 & iOS 12 in this case. But it is working fine in iOS 9 and iOS 10. \r\nWe have introduced manual cropping to have a higher quality of cropped image in TIMOB-7511.\r\n \r\nI add the original image (3264X2448) in iPhone 6 simulator and run the app on simulator-\r\n\r\nWhile debugging I found in - \r\n1. In iOS 10 - \r\n [Original image|https://github.com/appcelerator/titanium_mobile/blob/864d8f10b30b5d4fabb4d235a44e715973750c5a/iphone/Classes/MediaModule.m#L1944] dimension - {2668X2001}\r\n [Crop rect|https://github.com/appcelerator/titanium_mobile/blob/864d8f10b30b5d4fabb4d235a44e715973750c5a/iphone/Classes/MediaModule.m#L1935] - {2661X1999}\r\n [Actual Edited Image|https://github.com/appcelerator/titanium_mobile/blob/864d8f10b30b5d4fabb4d235a44e715973750c5a/iphone/Classes/MediaModule.m#L1921] - {746X560}\r\n2. In iOS 11 - \r\n Original image dimension - {3264X2448}\r\n Crop rect - {3072X2301}\r\n Actual Edited Image - {748X560}\r\n\r\n3. In iOS 12 - \r\n Original image dimension - {3264X2448}\r\n Crop rect - {3073X2305}\r\n Actual Edited Image - (750X560)\r\n\r\nWhen cropping in simulator the rectangle of simulator is not cropping the image as image is not outside the crop rectangle. So ideally for iOS 10, 11 and 12 the Crop rect should be same as of 'original image dimension' . But in iOS 11 & iOS 12 it is different. \r\nDue to wrong crop rect image is getting cropped from bottom and right.\r\n\r\nSo Crop Rect is causing the problem. I'll look in more detail of this.", "updateAuthor": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-04-08T22:35:33.000+0000", "updated": "2019-04-09T22:39:41.000+0000" }, { "id": "447675", "author": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "body": "I have filed a bug to apple - https://openradar.appspot.com/radar?id=5010761264922624", "updateAuthor": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-04-12T22:32:00.000+0000", "updated": "2019-04-12T22:32:00.000+0000" }, { "id": "450240", "author": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Apple's comment -\r\n\"Engineering has determined that your bug report is a duplicate of another issue and will be closed. \r\n\r\nThe open or closed status of the original report your bug was duplicated to appears in a text box within the bug detail section of the bug reporter user interface. For security and privacy reasons, we don't provide access to the original bug yours was duped to.\r\n\r\nIf you have any questions or concerns, please update your report directly at this link: https://bugreport.apple.com/.\r\n\"\r\n\r\n", "updateAuthor": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-08-02T17:12:20.000+0000", "updated": "2019-08-02T17:12:20.000+0000" } ], "maxResults": 13, "total": 13, "startAt": 0 } } }