Hello first of all I am new in iPhone,
I want access all songs in my application. Is this posible to get all songs ?
Thank you very much. May be it's easy for you but for me it's hard.
In the Music app, tap Library, then tap a category, such as Albums or Songs; tap Downloaded to view only music stored on iPhone. Scroll to browse or swipe down the page and type in the search field to filter your results and find what you're looking for.
Since cellular bandwidth is often limited, you may be interested in preserving your cellular data and using Low Data Mode for Apple Music. Apple Music's streaming quality tops out at 256 kbps, which means that at the high-quality setting, you'd approximately consume a little above 5 MB of data for a three-minute song.
Identify songs in Control Center on iPhone or iPad To identify songs, open Control Center, then tap the Shazam button . Shazam can identify songs playing on your device even when you're using headphones. To find songs you've identified, touch and hold the Shazam button in Control Center to open your History View.
Download a song, album, or playlist: Touch and hold music you've added to your library, then tap Download. at the top of the screen. Note: You must turn on Sync Library to download music from Apple Music to your library (go to Settings > Music, then turn on Sync Library).
You need the Media Player framework:
Actual example taken from the docs:
MPMediaQuery *everything = [[MPMediaQuery alloc] init];
NSLog(@"Logging items from a generic query...");
NSArray *itemsFromGenericQuery = [everything items];
for (MPMediaItem *song in itemsFromGenericQuery) {
NSString *songTitle = [song valueForProperty: MPMediaItemPropertyTitle];
NSLog (@"%@", songTitle);
}
This tutorial might help you as well.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With