The AudioFileTagger framework provides facilities for reading metadata from audio files and tagging MP3 files with ID3v2 tags.
- macOS 10.10+
- Xcode 10.1+
Carthage is a decentralized dependency manager that builds your dependencies and provides you with binary frameworks. To integrate AudioFileTagger into your Xcode project using Carthage, specify it in your Cartfile
:
github "Phisto/AudioFileTagger" ~> 1.0
If you prefer not to use Carthage, you can integrate AudioFileTagger into your project manually. You only need to build and add the AudioFileTagger framework (AudioFileTagger.framework) to your project.
NSURL *fileURL = <#...#>
Metadata *meta = [[Metadata alloc] initWithMetadataFromFile:fileURL];
if (metadata) {
NSLog(@"\n");
NSLog(@"title: %@", meta.title);
NSLog(@"artist: %@", meta.artist);
NSLog(@"albumName: %@", meta.albumName);
NSLog(@"\n");
}
MP3Tagger *tagger = [MP3Tagger taggerWithMetadata:meta];
if (!tagger) {
<#// handle failure...#>
}
NSURL *mp3FileToTag = <#...#>
BOOL erfolg = [tagger tagFile:fileToTag];
if (!erfolg) {
<#// handle failure...#>
}
The AudioFileTagger framework uses TagLib to tag MP3 files with ID3v2 tags. TagLib is a library for reading and editing the meta-data of several popular audio formats. TagLib is distributed under the GNU Lesser General Public License (LGPL) and Mozilla Public License (MPL).
I made a (Fork) of the official 1.11.1 Release, so i can easily import the TagLib framwork via Carthage.
AudioFileTagger is released under the GNU Lesser General Public License (LGPL).