0

Please excuse if this is a novice question, as I'm quite new to iOS development (Just started about 3 days ago doing things natively) and I'm running into a small quirk. Right now I'm using UIImagePickerController@setAllowsEditing to drop the user into edit mode before they can confirm the picture, however my application requires that images be 512x512 to be sent off to my server for storage. There are numerous reasons for this, but those shouldn't matter for the question.

As of right now the user's image dimensions is completely dependent on their Camera, or the resolution of the image that they're picking from their photo library. Is there a way to force the user to crop the image into 512x512 dimensions.

Hobbyist
  • 15,888
  • 9
  • 46
  • 98
  • I made a demo project, see if it helps: [AImageResize](https://github.com/ArpitOnTheWay/AImageResize) – Arpit Dongre Jan 09 '16 at 13:01
  • @Arpit - Thanks for the demo project, unfortunately I'm not that fluent with Objective-C and I'm using Java through RoboVM to do everything. `HOWEVER` what I get from your example is that an image is automatically resized to be the desired width/height AFTER the user messed with the edit tool. This could cause the image to squish, stretch, and do all sorts of crazy things. I would test it, but unfortunately I'm at work right now. The idea is to give a user a clear idea of what the image is going to look like at 512x512 while they're editing – Hobbyist Jan 09 '16 at 13:20

1 Answers1

0

Try this libraries:iOS-Image-Crop-View,
GKImagePicker

Also there is this previous question on SO:Question

Community
  • 1
  • 1
Arpit Dongre
  • 1,683
  • 19
  • 30