프로젝트
GitHub에서 보기
matthewpalmer/Regift
소개
iOS에서 동영상을 간편하게 GIF로 변환합니다.
디자인 및 미디어측정된 스타 증가
- in 24h
- 0
- in 7 days
- -1
- in 15 days
- -1
- in 1 month
- 기록 수집 중
서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.
README.md
OriginalRegift
Easily convert a video to a GIF on iOS and OSX.
🚀
I also make Rocket, an app that gives you Slack-style emoji everywhere on your Mac.
Requirements
- Xcode 10+
- iOS 11.1+ / macOS 10.12+
- Swfit 5.0+
Installation
Cocoapods
Regift is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod "Regift"
Carthage
Regift is available through Carthage.
github 'matthewpalmer/Regift'
Quick Start
import Regift
Synchronous GIF creation:
let videoURL = ...
let frameCount = 16
let delayTime = Float(0.2)
let loopCount = 0 // 0 means loop forever
let regift = Regift(sourceFileURL: videoURL, frameCount: frameCount, delayTime: delayTime, loopCount: loopCount)
print("Gif saved to \(regift.createGif())")
let startTime = Float(30)
let duration = Float(15)
let frameRate = 15
let trimmedRegift = Regift(sourceFileURL: URL, startTime: startTime, duration: duration, frameRate: frameRate, loopCount: loopCount)
print("Gif saved to \(trimmedRegift.createGif())")
Asynchronous GIF creation:
let videoURL = ...
let frameCount = 16
let delayTime = Float(0.2)
let loopCount = 0 // 0 means loop forever
Regift.createGIFFromSource(videoURL, frameCount: frameCount, delayTime: delayTime) { (result) in
print("Gif saved to \(result)")
}
let startTime = Float(30)
let duration = Float(15)
let frameRate = 15
Regift.createGIFFromSource(videoURL, startTime: startTime, duration: duration, frameRate: frameRate) { (result) in
print("Gif saved to \(result)")
}
Acknowledgements
Thanks to Rob Mayoff's Gist, without which this library wouldn't exist.
My personal thanks to all of Regift’s contributors:
- caughtinflux
- samuelbeek
- sebyddd
- nakajijapan
- dbburgess
관련 프로젝트 살펴보기
불러오는 중…