In this post, we will see how to resolve How do you display an image at the maximum available space? Question: I check if the image is vertical or horizontal. If it is horizontal, I rotate it: But it leaves ...

In this post, we will see how to resolve iOS App Crashes from Memory Issue when Generating Images from PHAssets Question: I’m trying to get some photos (PHAsset‘s) from a user’s Photos library, and convert them to UIImage‘s. Here’s the ...

In this post, we will see how to resolve Is there a way to perpetually save photos to an Xcode app after refreshing? Question: I’m working on a program that uploads images to a CollectionView by accessing the user’s photo ...

Question: In my iPhone app, I take a picture with the camera, then I want to resize it to 290*390 pixels. I was using this method to resize the image : It works perfectly, but it’s an undocumented function, so ...

Question: I have an UIImageView called “theImageView”, with UIImage in a single color (transparent background) just like the left black heart below. How can I change the tint color of this image programmatically in iOS 7 or above, as per ...

Question: I’d like to load an image from a URL in my application, so I first tried with Objective-C and it worked, however, with Swift, I’ve a compilation error: ‘imageWithData’ is unavailable: use object construction ‘UIImage(data:)’ My function: In Objective-C: ...

Question: I want to create UIImage(urlString: String?). There is no error when I run this code but it is not working. Answer: UIImage initializer init(data:) is a synchronous method. Your self.init(data: imageData) method is called before the async method dataTask ...

Question: I am using an ImagePicker to select an Image from Library and store in CoreData (as Binary). In another view this selected image is shown as a thumbnail. I want the user to be free when selecting an image. ...

Question: I’m implementing snapshot sharing in iOS app, so the UIImage is created from the View and it is in the sharesheet and works fine, but I can’t get to show this UIImage as a thumbnail is ShareSheet. the UIImage ...

Question: I have built an app which fetches contacts from phonebook and saves their name and photo. To save the photo I’ve used the following code and when I print imageStr using print("IMGSTR: \(imageStr)") I get the following output Now ...