{"action":"created","issue":{"url":"https://api.github.com/repos/desbma/sacad/issues/7","repository_url":"https://api.github.com/repos/desbma/sacad","labels_url":"https://api.github.com/repos/desbma/sacad/issues/7/labels{/name}","comments_url":"https://api.github.com/repos/desbma/sacad/issues/7/comments","events_url":"https://api.github.com/repos/desbma/sacad/issues/7/events","html_url":"https://github.com/desbma/sacad/issues/7","id":134761300,"number":7,"title":"Match image with the largest resolution from reliable sources","user":{"login":"baoshan","id":1096182,"avatar_url":"https://avatars.githubusercontent.com/u/1096182?v=3","gravatar_id":"","url":"https://api.github.com/users/baoshan","html_url":"https://github.com/baoshan","followers_url":"https://api.github.com/users/baoshan/followers","following_url":"https://api.github.com/users/baoshan/following{/other_user}","gists_url":"https://api.github.com/users/baoshan/gists{/gist_id}","starred_url":"https://api.github.com/users/baoshan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baoshan/subscriptions","organizations_url":"https://api.github.com/users/baoshan/orgs","repos_url":"https://api.github.com/users/baoshan/repos","events_url":"https://api.github.com/users/baoshan/events{/privacy}","received_events_url":"https://api.github.com/users/baoshan/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2016-02-19T03:26:43Z","updated_at":"2016-02-20T17:20:25Z","closed_at":null,"body":"#6 deals mainly with the improvement over resizing. There're 4 album referenced in that issue. I made a comparison between the current `sacad` behavior when used on a `540px` device, with using the largest possible version. The `Pictures` album is excluded for that's unfair for `last.fm` (only `300px` version provided).\r\n\r\nCurrent Behaviour:\r\n\r\n+ resolution is a required argument;\r\n+ favor `png` over `jpg` for same resolution;\r\n+ default tolerance (25%)\r\n\r\nProposed Behaviour:\r\n\r\n+ no resolution argument required;\r\n+ favor highest resolution image from reliable sources;\r\n+ No resizing (unless asked)\r\n\r\nThis test resizes all images to `540px` using `ImageMagick` command `convert A.png -resize 540x540 -quality 100 A.540.png` (which simulate what the users see actually, according to the use case you proposed). If you feel the `540px` is unfair for some `last.fm` images are `500x500` (the mega one), I'm glad to post a `480px` version.\r\n\r\nNo | Current Behaviour | Proposed Behaviour\r\n------------ | ------------ | -------------\r\n1 | ![a 540](https://cloud.githubusercontent.com/assets/1096182/13165578/c29542c6-d6f9-11e5-9f2a-381f2904b4ad.png) | ![a 540](https://cloud.githubusercontent.com/assets/1096182/13165586/d0d9d284-d6f9-11e5-994b-170c92726555.png)\r\n2 | ![b 540](https://cloud.githubusercontent.com/assets/1096182/13165590/e0746e52-d6f9-11e5-87d5-e0912929b621.png) | ![b 540](https://cloud.githubusercontent.com/assets/1096182/13165596/eb4efc02-d6f9-11e5-8836-b7e7d427e1c1.png)\r\n3 | ![c 540](https://cloud.githubusercontent.com/assets/1096182/13165606/f7f7c65a-d6f9-11e5-90b1-03d2c3f6b9e9.png) | ![c 540](https://cloud.githubusercontent.com/assets/1096182/13165622/10de215a-d6fa-11e5-832d-f50adfcc4552.png)\r\nSize | 1,054,095 Bytes | 794,931 Bytes\r\nOptimised Size | 908,128 Bytes | 794,931 Bytes\r\nTime used to decode | 172 ms | 382 ms \r\n\r\nThe size is based on the un-resized version; the time is calculated using `convert A.jpg -resize 540x540 A.540.bmp` and `convert A.png -resize 540x540 A.540.bmp` respectively.\r\n\r\nThe proposal:\r\n\r\n1. shows a storage efficiency (+14% ~ +33%);\r\n2. shows a less time efficiency (-123%);\r\n3. with a clear improvement on image quality, see the text on test 2 and adele's nose and lips on test 3, and all 3 tests reveals a more layered colour depth, although this is subjective, I'd like to post some camera shots with calibrated screen if necessary;\r\n4. You inevitable upgrade your device, but not your collection, if a tablet uses `960px` to show the image, the proposed policy is definitely an all winner, while the users using the current `sacad` have to re-match again.\r\n\r\nThanks and I'd like to hear your thoughts."},"comment":{"url":"https://api.github.com/repos/desbma/sacad/issues/comments/186656057","html_url":"https://github.com/desbma/sacad/issues/7#issuecomment-186656057","issue_url":"https://api.github.com/repos/desbma/sacad/issues/7","id":186656057,"user":{"login":"desbma","id":1145175,"avatar_url":"https://avatars.githubusercontent.com/u/1145175?v=3","gravatar_id":"","url":"https://api.github.com/users/desbma","html_url":"https://github.com/desbma","followers_url":"https://api.github.com/users/desbma/followers","following_url":"https://api.github.com/users/desbma/following{/other_user}","gists_url":"https://api.github.com/users/desbma/gists{/gist_id}","starred_url":"https://api.github.com/users/desbma/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/desbma/subscriptions","organizations_url":"https://api.github.com/users/desbma/orgs","repos_url":"https://api.github.com/users/desbma/repos","events_url":"https://api.github.com/users/desbma/events{/privacy}","received_events_url":"https://api.github.com/users/desbma/received_events","type":"User","site_admin":false},"created_at":"2016-02-20T17:20:25Z","updated_at":"2016-02-20T17:20:25Z","body":">  Can you see the two possible problem I described above?\r\n\r\nIf you want to target 540px and absolutely avoid a resize at display time, pass `540 -t 0`.\r\nWhen you ask sacad to download a cover at size X, you get size X, but's it's not \"future proof\", because maybe in the future you'll want size Y?\r\n\r\nThis does not make any sense to me.\r\n\r\n**Please let's keep this only about specific issues, not about feature ideas or change proposals.**\r\n\r\n>  And, can you help me understand why the following command only generate a `500px` image while there're available `1500px` one?\r\n\r\n> `sacad -t 75 \"Alice Sara Ott\" \"Pictures\" 1500 pictures.jpg`\r\n\r\nIt looks unexpected indeed, I'll look at it."}}