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.11
Reverse + Transcode
⭐️ 2
🕓 32 weeks ago
iOS
.package(url: "https://github.com/mj-kong/TRTransformer.git", from: "v1.12.11")

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: 2
Last commit: 32 weeks ago
Advertisement: IndiePitcher.com - Cold Email Software for Startups

Release Notes

Release (v1.12.11)
32 weeks ago

Allow "cancel" in reversing audio track

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