• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: iPhone Library Access
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: iPhone Library Access


  • Subject: Re: iPhone Library Access
  • From: Chris Adamson <email@hidden>
  • Date: Fri, 9 Jul 2010 09:18:37 -0400

I just found this last night and need to find some time to investigate it further.  The basic idea is to use the MediaPlayer framework to get an MPMediaItem.  Usually you'd use this to play something from the library.  But the -[valueForProperty:] method now takes a key MPMediaItemPropertyAssetURL which returns a special URL of the form ipod-library://... .

Now you switch gears to the AV Foundation framework (the only thing that supports this weird URL scheme).  Presumably, the AVPlayer will accept this URL, but to do anything interesting I think what you want to do here is to create an AVURLAsset.  From that, I think you'd be able to add the asset as a track to a movie composition.  Unfortunately, AV Foundation doesn't offer sample level access at edit-time (only at capture time… arrgh!), but maybe you could export an audio-only movie to PCM and then start inspecting samples.  I don't currently know if AV Foundation can export into a format that Core Audio's AudioFileOpenURL() can open… obviously, it would be nice to export to CAF if possible.

Like I said, I think the MPMediaItemPropertyAssetURL property is the secret, but I need to find sometime to play with it.  There are only six hits on Google for MPMediaItemPropertyAssetURL right now, seven once this gets posted, but hopefully people will go off and running with it.

--Chris

On Jul 8, 2010, at 11:14 PM, Aran Mulholland wrote:

> I noticed there is an app on the app store that allows access to the
> iTunes library (Flare Scratch) and then manipulates the audio data. I
> hear its a feature of iOS 4.
> What library/framework do i use for this kind of access?

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: iPhone Library Access
      • From: Aran Mulholland <email@hidden>
References: 
 >iPhone Library Access (From: Aran Mulholland <email@hidden>)

  • Prev by Date: RemoteIO callback functions
  • Next by Date: Re: What is the AudioStreamBasicDescription(asbd) for a wav file
  • Previous by thread: iPhone Library Access
  • Next by thread: Re: iPhone Library Access
  • Index(es):
    • Date
    • Thread