MMSCropView 2.1.0

MMSCropView 2.1.0

TestsTested
LangLanguage SwiftSwift
License MIT
ReleasedLast Release Nov 2017
SwiftSwift Version 4.0
SPMSupports SPM

Maintained by William Miller.




  • By
  • William Miller

MMSCropView

CI Status
Version
License
Platform
Readme Score

This class provides the feature to draw a rectangle over an image by dragging a finger over it, move it, and extract the covered region into a UIImage.

Example

## Usage To run the example project, clone the repo, and run `pod install` from the Example directory first.

In your storyboard select the custom class MMSCropImageView for the Image View widget.

Import the class header.

import MMSCropView

Add an event handler to initiate the crop action and call the crop method on the image view.

@IBAction func crop(sender: UIButton) {

    let croppedImage = originalImageView.crop()

    croppedImageView.image = croppedImage

}

Requirements

  • MMSCropView requires iOS 8.3 or later.
  • Swift 3.0.

Installation

MMSCropView is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod "MMSCropView"

Author

William Miller, [email protected]

Article

An article describing the implementation of the class: A View Class for Cropping Images.

Contact

William Miller

License

This project is is available under the MIT license. See the LICENSE file for more info. Attribution by linking to the project page is appreciated.