valueForProperty:MPMediaItemPropertyArtwork always returning nil in iOS 8 betas...

Discussion in 'iOS Programming' started by VolceOntra, Aug 4, 2014.

  1. VolceOntra, Aug 4, 2014
    Last edited by a moderator: Aug 4, 2014

    VolceOntra macrumors 6502

    VolceOntra

    Joined:
    Apr 25, 2007
    #1
    ...anyone else having this problem or can confirm? My code works fine under iOS 7.

    Code:
        MPMediaItemArtwork *artwork = [rowItem valueForProperty:MPMediaItemPropertyArtwork];
                UIImage *artworkImage = [artwork imageWithSize:CGSizeMake(100,100)];
                
                blurredImage.image = [self.albumsArtworkArray objectAtIndex:indexPath.section];
                
                if (artworkImage) {
                    image.image = artworkImage;
                    
                    
                } else {
                    image.image = noArtwork;
                }
     
  2. plusadd macrumors newbie

    Joined:
    Sep 22, 2014
    Location:
    Japan
    #2
    I think you can get an image like this:

    Code:
    UIImage *artworkImage = [artwork imageWithSize: artwork.bounds.size];
     
  3. VolceOntra thread starter macrumors 6502

    VolceOntra

    Joined:
    Apr 25, 2007
    #3
    Thank you so much
     

Share This Page