Swiftpack.co - mj-kong/TRTransformer as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by mj-kong.
mj-kong/TRTransformer v1.12.4
Reverse + Transcode
⭐️ 1
🕓 2 days ago
iOS
.package(url: "https://github.com/mj-kong/TRTransformer.git", from: "v1.12.4")

TRTransformer

A set of utility classes for reversing or transcoding AVAsset video and audio partially.

These classes will reverse or transcode video, audio and videos with audio.

Video reversal is based heavily on Chris Sung's CSVideoReverse class, This is forked from Interfacelab/ILABReverseVideoExporter

Reverse

/// Example

let url = // Local or Remote Asset URL
let asset = AVAsset(url: url) 
let outputURL = // URL
let session = ILABReverseVideoExportSession(asset: asset, outputURL)

session.exportAsynchronously({ [unowned self] (message: String?, progress: Float) in
    // process reverse

}) { [unowned self] (result: Bool, erro: Error?) in
    // complete reverse

}

Transcode

/// Example

let url = // Local or Remote Asset URL
let asset = AVAsset(url: url) 
let outputURL = // URL
let session = ILABTranscodeSession(asset: asset, outputURL)

session.transcodeAsynchronously({ [unowned self] (message: String?, progress: Float) in
    // process transcode

}) { [unowned self] (result: Bool, erro: Error?) in
    // complete transcode

}

GitHub

link
Stars: 1
Last commit: 3 days ago
jonrohan Something's broken? Yell at me @ptrpavlik. Praise and feedback (and money) is also welcome.

Release Notes

Release (v1.12.4)
3 days ago

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics