Skip to content

Phisto/CoreAudioConverter

Repository files navigation

Carthage Compatible License

CoreAudioConverter

Overview

The CoreAudioConverter framework provides facilities for converting various audio file formats to MPEG Audio Layer III, more commonly referred to as MP3.

Supported Audio Formats

  • Audio Interchange File Format (AIFF)
  • Apple Lossless Audio Codec (ALAC)
  • Advanced Audio Coding (ACC)

Requirements

  • macOS 10.10+
  • Xcode 10.1+

Installation

Carthage

Carthage is a decentralized dependency manager that builds your dependencies and provides you with binary frameworks. To integrate CoreAudioConverter into your Xcode project using Carthage, specify it in your Cartfile:

github "Phisto/CoreAudioConverter" ~> 1.0

Manually

If you prefer not to use Carthage, you can integrate CoreAudioConverter into your project manually. You only need to build and add the CoreAudioConverter framework (CoreAudioConverter.framework) to your project.

Usage

// create the encoder task
NSURL *fileURL = <#...#>
NSURL *outFileUrl = <#...#>
EncoderTask *task = [EncoderTask taskWithInputURL:fileURL
                                        outputURL:outFileUrl
                                     temporaryURL:nil];

// create the encoder
MP3Encoder *mp3Encoder = [[MP3Encoder alloc] initWithDelegate:self];
if (!mp3Encoder) {
    <#// handle failure...#>
}

NSError *encodingError = nil;
BOOL erfolg = [mp3Encoder executeTask:task error:&encodingError];
if (!erfolg) {
    <#// handle failure...#>
}

LAME

The CoreAudioConverter framework is using LAME to encode files to MP3. LAME is a high quality MPEG Audio Layer III encoder licensed under the GNU Lesser General Public License (LGPL).

Audio File Tagger

The CoreAudioConverter framework is using the AudioFileTagger framework to tag the encoded MP3 files with ID3v2 tags. AudioFileTagger is released under the GNU Lesser General Public License (LGPL).

Credits

I learned a lot by browsing trough the code repository for the brilliant macOS application Max.

License

CoreAudioConverter is released under the GNU Lesser General Public License (LGPL).

About

This is a framework to convert various audio file formats (aif | aiff | aac | m4a) to the mp3 format.

Resources

License

Stars

Watchers

Forks

Packages

No packages published