ILImageEditor 1.0.1

ILImageEditor 1.0.1

测试已测试
语言语言 SwiftSwift
许可 MIT
发布最后发布2017 年 8 月
SwiftSwift 版本3.0
SPM支持 SPM

Muqtadir Ahmed 维护。



  • il-Logical

ILImageEditor

描述

这是一个简单的图像编辑器,对图像执行大多数基本且广泛使用的操作,如旋转、图像镜像、调整大小和裁剪。

功能

  • 旋转
  • 图像镜像
  • 压缩/调整大小
  • 裁剪
  • 修复方向

要求

  • iOS 9.0+

使用方法

ILImageEditor 可在 CocoaPods 上使用。只需将以下行添加到您的 podfile 中

pod 'ILImageEditor'

或者,下载文件并将它们拖放到您的 Xcode 项目中

入门

初始化

import ILImageEditor

class ImageEditor {
    var editor = ILImageEditor()
}

使用方法

修复不正确的图像方向。

public func fixImageOrientation(image: UIImage) -> UIImage

执行旋转、镜像操作。

public func editImageWithOptions(image: UIImage, withOptions option: FlippingOptions) -> UIImage

####压缩或调整图像大小。public func compressImageToSize(image: UIImage, withSize size: CompressionOptions, compressionQualtity: CGFloat) -> UIImage

####裁剪图像到指定的矩形。public func cropAnImageToRect(image: UIImage, rectToCrop rect: CGRect) -> UIImage

作者

Muqtadir Ahmed, [email protected]

许可

ILImageEditor 在 MIT 许可证下提供。有关更多信息,请参阅 LICENSE 文件。