Skip to content

Jason-Chan/AVPlayerCacheSupport

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 

Repository files navigation

AVPlayerCacheSupport

An easy way to add cache for AVPlayer.

Features

  • Cache http streaming data For AVPlayer
  • Support both audio & video http streaming (except m3u or other playlist format, e.g. HTTP Live Streaming, take a look at this post)
  • Byte range access & cache
  • Simple API
  • Cache management

Install

Drag the folder named AVPlayerCacheSupport into your project.

Usage

Before

AVPlayerItem *item = [AVPlayerItem playerItemWithURL:url];
self.player = [[AVPlayer alloc] initWithPlayerItem:playerItem];

Now, with cache support

#import "AVPlayerItem+MCCacheSupport.h"

AVPlayerItem *item = [AVPlayerItem mc_playerItemWithRemoteURL:url];
self.player = [[AVPlayer alloc] initWithPlayerItem:playerItem];

Requries

  • iOS 7.0+ or MacOSX 10.9+

License

MIT

Demo

Sitting on WWDC 2015 sample code AVFoundationQueuePlayer-iOS.

About

An easy way to add cache for AVPlayer.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Objective-C 100.0%