libheif + Xcode
A wrapper for libheif + Xcode project. This enables Carthage support to build libheif as a framework for Apple's platform.
This repo also including the CocoaPods's spec file to use libheif.
Requirements
- iOS 8
- macOS 10.9
- tvOS 9.0
- watchOS 2.0
Installation
Carthage
libheif is (via this repo) available through Carthage.
github "SDWebImage/libheif-Xcode"
CocoaPods
libheif is available through CocoaPods.
pod 'libheif'
Swift Package Manager (Xcode 11+)
libheif is available through Swift Package Manager.
let package = Package(
dependencies: [
.package(url: "https://github.com/SDWebImage/libheif-Xcode.git", from: "1.6.1")
]
)
Usage
libheif itself is not a full function decoder but an abstract layer. It needs libde265 for HEIF decoder support, and x265 for HEIF encoder support.
Since most of people's usage of this library is for HEIF decoding, and x265
is under GPLv2 license, we only integrate libheif with the Carthage dependency libde265-Xcode. To use x265 for HEIF encoding, try to build it by your own.
Use libheif as you would normally, this is just a repo that adds an Xcode proj.
License
libheif is available under the terms of the GNU Lesser General Public License. See the LICENSE file for more info.