Latest 0.1.0
Homepage https://github.com/ahmadamri/AQPlayer
License MIT
Platforms ios 11.0
Authors

iOS Audio player :speaker: uses AVQueuePlayer

AQPlayer
command center skip mode
command center next previous mode

  • play background audio and handle MPRemoteCommandCenter actions.
  • next track, previous track, go to specific track, skip interval (forward/backward), change playback rate, …

Usage:

let playerManager = AQPlayerManager.shared

Initialize player items and setup the player manager

var playeritems: [AQPlayerItemInfo] = []

// for each audio file 
let item = AQPlayerItemInfo(id: fileId,
                            url: audioUrl,
                            title: "part_title",
                            albumTitle: "albumTitle",
                            coverImage: nil,
                            startAt: 0)
playeritems.append(item)
playerManager.setup(with: playeritems, startFrom: 0, playAfterSetup: false)

Command Center Art work image can be set during initilization of the item using (URL or UIImage), or through the delegate method getCoverImage

Example

Check the Example in the project for full fuctioning demo

clone the repo, and run pod install from the Example directory first.

Requirements

  • swift 4.2
  • iOS 11.0+

License

AQPlayer is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "AQPlayer",
    "version": "0.1.0",
    "summary": "Audio player using AVQueuePlayer",
    "description": "TODO: Add long description of the pod here.",
    "homepage": "https://github.com/ahmadamri/AQPlayer",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "ahmadamri": ""
    },
    "source": {
        "git": "https://github.com/ahmadamri/AQPlayer.git",
        "tag": "0.1.0"
    },
    "swift_versions": "4.2",
    "platforms": {
        "ios": "11.0"
    },
    "source_files": "AQPlayer/Classes/**/*"
}

Pin It on Pinterest

Share This