Friday, October 25, 2013 by Tim Webb
Following the release of the AudioCopy app earlier this week, there were members of the community crying foul at some of the features which were similar to those found in AudioShare. AudioShare has been a long loved tool among iOS musicians, since its release in July 2012. I invited developer Jonatan Liljedahl to write an OpEd stating the case for developers to support AudioShare in their apps, and how his SDK will benefit users in the continuously expanding inter-app audio options.
The AudioShare SDK - How and why?
by Jonatan Liljedahl, Kymatica
We already have two standards for Audio Copy and Paste, and with iOS7 one of them broke and was replaced with a new version. So why support yet another way of getting audio in and out between apps?
Firstly, AudioShare's main purpose is not to replace the existing AudioCopyPaste standards. The reason I made AudioShare was that there was a gap that was asking to be filled - iOS musicians needed a central librarian to store and manage their sounds, with various ways to get audio in and out of the library. AudioShare delivers that, and I'm happy to see it growing into the standard file manager for iOS musicians or anyone that need to manage soundfiles on their iOS device. It is also a recorder, and an Inter-App Audio host, and some people refer to it as the swiss-army knife of iOS audio.
So, for all these AudioShare users, copying and pasting to transfer audio between other apps and AudioShare works fine, albeit a bit cumbersome. But this can easily be improved! By implementing the AudioShare SDK in your app, your users will be able to export or import to and from AudioShare with a single tap of a button, and the user can keep working directly with their central sound library.
But this is not the only reason. AudioShare SDK also supports any kind of audio file, including MP3 and MIDI files. It also supports any format, for example 24bit/48k, instead of being limited to the CD-standard of 16bit/44k1. And it works for iOS 5, 6 and 7!
The SDK is extremely easy to incorporate in your own code, here's what is needed to export a file into AudioShare:
[[AudioShare sharedInstance] addSoundFromPath:thePathToYourFile withName:@"My Sound"];
That's a single line of code! Importing from AudioShare is a tiny bit more complex, but should still take only a couple of minutes:
1. First, declare a new URL type for your app with the scheme yourAppName.audioshare
2. Then, in your app delegates openURL handler method, call checkPendingImport:withBlock: to handle the actual import. The supplied block will be called with a path to the imported file, living inside your apps temporary directory.
3. Finally, to initiate the import from your app, simply call [[AudioShare sharedInstance] initiateSoundImport];
AudioShare SDK is free and open source, and can be found here:
Don't hesitate to contact me if you have any questions!