Questions tagged [mpmediaquery]

A media query specifies a set of media items (instances of MPMediaItem) from the iPod library by way of a filter and a grouping type. Filter and grouping type are both optional; an unqualified query matches the entire library.

A media query specifies a set of media items (instances of MPMediaItem) from the iPod library by way of a filter and a grouping type. Filter and grouping type are both optional; an unqualified query matches the entire library.

170 questions
0
votes
1 answer

Retrieve MPMediaItemArtwork from Album Id

I have an albumId ( say "-7833645336740617216" ). I am looking at a method similar which can take this as an input, and return the MPMediaItemArtwork associated with this album.
Amarsh
  • 11,214
  • 18
  • 53
  • 78
0
votes
1 answer

Running MPMediaQuery in GCD

The following code runs great and gives me the results I am looking for. However, I would like to run it in its own thread. Is MPMediaQuery thread safe, and what am I doing wrong, if it is? -(NSArray*) mediaItemsFromPersistentIds:(NSArray*)…
Paul S.
  • 1,342
  • 4
  • 22
  • 43
0
votes
1 answer

Create a custom MediaPickerController

I was tasked to create a music player application that is sort of like a DJ app, and when the add music button is clicked, it needs to show the list of all the songs just like the native MediaPickerController but with added functionalities like…
Bryan P
  • 4,142
  • 5
  • 41
  • 60
0
votes
1 answer

Check if Music library is empty

I'm accessing the iPhone's library and doing a query on it MPMediaQuery *albums = [MPMediaQuery albumsQuery]; NSArray *albumCollections = [albums collections]; If music doesn't exist, [albums collections] obviously causes a crash. How can I check…
Sr.Richie
  • 5,680
  • 5
  • 38
  • 62
0
votes
0 answers

MPMediaTypeMovie returns nil

I am trying to play all videos, including the movies, which I bought in iTunes. But when I try to fetch theMPMediaItems then I get an NSInvalidArgumentException because the MPMediaQuery returns a nil object. This is my function: //get the iPod…
kchromik
  • 1,348
  • 2
  • 13
  • 42
0
votes
1 answer

MPMediaQuery returning tracks instead of playlist from persistentID

The purpose of my code is to return an MPMediaPlaylist object, from a persistentID previously attained. MPMediaPropertyPredicate *predicate = [MPMediaPropertyPredicate predicateWithValue:persistentID …
Andrew
  • 7,693
  • 11
  • 43
  • 81
0
votes
1 answer

Getting Genre list on iOS7

I try to get the list of genres on my iPhone 5S with iOS 7.0.3 using this code: MPMediaQuery *query = [MPMediaQuery genresQuery]; for (MPMediaItemCollection *item in [query collections]) { NSLog(@"%@", [[item representativeItem]…
Urkman
  • 1,298
  • 1
  • 16
  • 32
0
votes
3 answers

"unrecognized selector" crash on IOS 7 simulator

I am testing my music application compatibility on IOS7 by running it on Xcode 5 iPhone simulator(IOS7) but it crashes on retrieving all the music items using following code. MPMediaQuery *allSongs = [[MPMediaQuery alloc] init]; NSArray…
subhash kumar singh
  • 2,716
  • 8
  • 31
  • 43
0
votes
2 answers

Media Queries not working in Internet Explorer ie6-ie8

the code is given which was written for css but not working at all in IE(6-8) @media screen and (max-width: 340px)…
Prafulla
  • 29
  • 1
  • 6
0
votes
2 answers

iPhone song library query with known persistentIdentifier returning nil

I'm trying to play back a song referenced from a stored persistentIdentifier, but the MPMediaQuery returns 0 results if I apply a filter to it using the stored value. My code for the not-working filtered version: NSNumber *persistentId = [NSNumber…
0
votes
2 answers

list all the videos (from the photo library and the video app) into the uitableviewcell

I want to list all the videos. Not just the videos in photo library, but also in the video app, including the movies, tv shows, music videos, etc into my app. When I used ALAsset like this: ALAsset *asset = [videoLibrary…
0
votes
1 answer

An MPMediaQuery for playlists (on iPod) includes some albums

I've instantiated a query to request a collection of all the playlists on my iPod Touch. The result, returned from the MPMediaQuery collections property, contains 43 items. These include all 17 of the PlayLists that the native Music app shows. …
0
votes
2 answers

Same code, different result - MPMediaQuery's method "collectionSections"

At first, I want to say that i don't speak English very well. understand please TT I typed the code in Xcode. MPMediaQuery* songsQuery = [MPMediaQuery songsQuery]; self.songsSectionArray = [songsQuery collectionSections]; In the songsQuery, There…
0
votes
1 answer

Is it possible to delete media from ipod library programmatically?

After search several apple documents and websites, I feel that apple only allow to read media data from ipod-library. Is there anyone confirm about this ? Is it possible to implement the feature to delete media from ipod library ? Regards, Soontak…
-1
votes
1 answer

Getting only null returns from MPMediaQuery albums query

Ok. So, I've been running this on my iphone. It works for songs just fine, I'm able to display a list of songs complete with artist names and album covers in a UITableview, however the moment I try to search for albums I just get null. Here is my…
Jobalisk
  • 728
  • 1
  • 6
  • 17
1 2 3
11
12