{"action":"created","issue":{"url":"https://api.github.com/repos/thephpleague/glide/issues/66","labels_url":"https://api.github.com/repos/thephpleague/glide/issues/66/labels{/name}","comments_url":"https://api.github.com/repos/thephpleague/glide/issues/66/comments","events_url":"https://api.github.com/repos/thephpleague/glide/issues/66/events","html_url":"https://github.com/thephpleague/glide/issues/66","id":86630765,"number":66,"title":"Combine crop and resize","user":{"login":"Yoyogi","id":1135653,"avatar_url":"https://avatars.githubusercontent.com/u/1135653?v=3","gravatar_id":"","url":"https://api.github.com/users/Yoyogi","html_url":"https://github.com/Yoyogi","followers_url":"https://api.github.com/users/Yoyogi/followers","following_url":"https://api.github.com/users/Yoyogi/following{/other_user}","gists_url":"https://api.github.com/users/Yoyogi/gists{/gist_id}","starred_url":"https://api.github.com/users/Yoyogi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yoyogi/subscriptions","organizations_url":"https://api.github.com/users/Yoyogi/orgs","repos_url":"https://api.github.com/users/Yoyogi/repos","events_url":"https://api.github.com/users/Yoyogi/events{/privacy}","received_events_url":"https://api.github.com/users/Yoyogi/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-06-09T15:06:44Z","updated_at":"2015-06-09T15:16:05Z","closed_at":"2015-06-09T15:16:05Z","body":"Hello,\r\n\r\nIs it possible to resize an image before cropping it ?\r\nFor instance, I have a large image 2000x2000px. I want to get only the part of 100x200px located at coordinates (500px;500px), but in a smaller size like 50x100px. Is it possible to do something like this ?\r\n\r\nThanks\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/thephpleague/glide/issues/comments/110397968","html_url":"https://github.com/thephpleague/glide/issues/66#issuecomment-110397968","issue_url":"https://api.github.com/repos/thephpleague/glide/issues/66","id":110397968,"user":{"login":"reinink","id":882133,"avatar_url":"https://avatars.githubusercontent.com/u/882133?v=3","gravatar_id":"","url":"https://api.github.com/users/reinink","html_url":"https://github.com/reinink","followers_url":"https://api.github.com/users/reinink/followers","following_url":"https://api.github.com/users/reinink/following{/other_user}","gists_url":"https://api.github.com/users/reinink/gists{/gist_id}","starred_url":"https://api.github.com/users/reinink/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/reinink/subscriptions","organizations_url":"https://api.github.com/users/reinink/orgs","repos_url":"https://api.github.com/users/reinink/repos","events_url":"https://api.github.com/users/reinink/events{/privacy}","received_events_url":"https://api.github.com/users/reinink/received_events","type":"User","site_admin":false},"created_at":"2015-06-09T15:16:05Z","updated_at":"2015-06-09T15:16:05Z","body":"Nope, and this is intentional. It's almost always better to crop before resizing, and this is actually modelled after the [Imgix](http://www.imgix.com/) API. You can still accomplish the same thing, you simply need to perform your crop operation at the larger size, which might require some basic calculations.\r\n\r\nOften cropping libraries provide the ability to specifiy the cropping dimensions based on the original image as well. For example, jCrop allows you to do this using the [Explicit Sizing Method](http://deepliquid.com/content/Jcrop_Sizing_Issues.html#Explicit_Sizing_Method)."}}