Contains a demo version of the official Roll player.

Last update: Jul 29, 2022

RollDemo

Minimum iOS Version UIKit Support SwiftUI Support

This package is a demo version of Roll player which is a native iOS audiovisual player that builds on AVFoundation.

Contact Information:

โš ๏ธ : This package is a demo version of the full player, so some features have been disabled. Also playback will be interrupted after some time. If you would like to try the full player, please send an email to [email protected] or by creating an issue on GitHub. (Email will work best though)

Default Roll Player UI

Features of Roll player include (non-exhaustive):

  • Playback of Live and VOD streams
  • Playlist support, even in PiP mode!
  • Smart error recovery (when applicable) while preserving playhead information
  • Picture-in-Picture mode (supporting devices)
  • AirPlay support
  • Now Playing Info support
  • Optimized time to playback
  • Playback start at a specific time
  • Playback control via Siri
  • Playback speed control
  • Screen dimming control
  • Volume control
  • Audio and subtitles selection (for supported HLS streams)
  • Usual video controls (play, pause, stop, rewind, fast forward and seek through the video)

A default UI is provided but you can customize the UI controls as you wish, like in the following example: Eccentric Roll Player UI showing customization

Installation

You can bring the Roll Demo to your project using SPM only.

Getting Started

The easiest way to test Roll Demo is to use a storyboard file in order to embed an instance of the player in your view controller hierarchy, but you can also embed the player in code if you wish.
This guide will go with storyboards

  • Add Roll demo package to you project. Adding Roll Demo as a dependency to you project in Xcode

  • Then in you storyboard file:

    1. add a view controller that embeds the player.
    2. Set the embedded view controller's class to PlayerViewController from the module, Roll. Embedding the player in your storyboard
  • Open you container view controller from the storyboard (the one that embeds the player view controller) and intercept the embedding process in order to be able to inject a stream in to the player:

import Roll
import UIKit

class ViewController: UIViewController {
  // implementations

  // 1:
  override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
    guard
        segue.identifier == "player_embed"
      , let playerViewController = segue.destination as? PlayerViewController
    else {
      return
    }

    // 2:
    let stream = StreamRepresentation(
      id: "Stream Id",
      location: URL(string: "https://example.apple.com/videos/bestmovie/master.m3u8")!,
      title: "Bonzy Title",
      supplementaryTitle: "Paro Supplementary Title",
      trait: .replay()
    )

    // 3:
    playerViewController.replace(stream: stream)
  }

  // other implementations
}

// 1:
We check that we are embedding the player, which is an instance of PlayerViewController.

// 2:
A playable stream defined using StreamRepresentation. This structure encapsulates useful information / configuration about the stream. For our purpose, we will focus on providing:

  • id: A unique identifier for the stream (depends on how you identify streams in your organization).
  • location: The URL of the stream.
  • title: The title of the stream. This might be used for display in the UI.
  • supplementaryTitle: A supplementary title for the stream. This might be used for display in the UI also.

// 3:
Set the stream on the player to start playback.

Full featured Roll player

If you have tried and loved the Roll Demo, you can reach me through one of the following channels:

GitHub

https://github.com/rajiv-labs/RollDemo
You might also like...

VGPlayer - ๐Ÿ“บ A simple iOS video player by Vein.

 VGPlayer - ๐Ÿ“บ  A simple iOS video player by Vein.

Swift developed based on AVPlayer iOS player,support horizontal gestures Fast forward, pause, vertical gestures Support brightness and volume adjustment, support full screen, adaptive screen rotation direction.

Jul 29, 2022

YouTube player for SwiftUI

YouTube player for SwiftUI

SwiftUI YouTube Player for iOS and MacOS Fully functional, SwiftUI-ready YouTube player for iOS 14+ and MacOS 11+. Actions and state are both delivere

Jul 26, 2022

Open Source iOS 360 Degree Panorama Video Player.

Open Source iOS 360 Degree Panorama Video Player.

๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ The Metal with Swift 5.0 version is comming ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ ๐ŸŽบ 360 VR Player A Open Source, Ad-free, Na

Aug 3, 2022

VLC media player

VLC media player VLC is a libre and open source media player and multimedia engine, focused on playing everything, and running everywhere. VLC can pla

Aug 6, 2022

๐Ÿ“ฝ A video player for SwiftUI, support for caching, preload and custom control view.

๐Ÿ“ฝ A video player for SwiftUI, support for caching, preload and custom control view.

Features QuickStart Advances Installation Requirements License Demo Clone or download the project. In the terminal, run swift package resolve. Open Vi

Aug 5, 2022

FWVideoPlayer is video Player for iOS in Swift.

FWVideoPlayer Desc FWVideoPlayer is video Player for iOS in Swift. It can play video and audio. You can use it easy. Example To run the example projec

Oct 15, 2021

SuperVideoPlayer is video player in Objc.

SuperVideoPlayer Example To run the example project, clone the repo, and run pod install from the Example directory first. Requirements Installation S

Oct 19, 2021

iOS video player for trailer. You can customize layout for the control panel. Support PiP and DRM.

iOS video player for trailer. You can customize layout for the control panel. Support PiP and DRM.

Jan 31, 2022

IINA is the modern video player for macOS.

IINA is the modern video player for macOS.

IINA IINA is the modern video player for macOS. Website ยท Releases ยท Telegram Group Features Based on mpv, which provides the best decoding capacity o

Nov 2, 2021
Related tags
Audio player demo based on Swift and SwiftUI, which can play local or network audio.
Audio player demo based on Swift and SwiftUI, which can play local or network audio.

SwiftAudioDemo Audio player demo based on Swift and SwiftUI, which can play local or network audio. In this demo, I have made a radio player to play n

Mar 13, 2022
Official SwiftUI SDK for Stream Chat.
Official SwiftUI SDK for Stream Chat.

SwiftUI - Currently in Development ?? The SwiftUI SDK is built on top of the StreamChat framework and it's a SwiftUI alternative to the StreamChatUI S

Aug 10, 2022
iCook's official tvOS app
iCook's official tvOS app

iCook tvOS App A tvOS app that plays iCook TV videos. Quick Start Run the following commands to install dependencies: make bootstrap Production Setup

Feb 8, 2022
BMPlayer - A video player for iOS, based on AVPlayer, support the horizontal, vertical screen
BMPlayer - A video player for iOS, based on AVPlayer, support the horizontal, vertical screen

A video player for iOS, based on AVPlayer, support the horizontal, vertical screen. support adjust volume, brightness and seek by slide, support subtitles.

Aug 1, 2022
Overlay alpha channel video animation player view using Metal.
Overlay alpha channel video animation player view using Metal.

Overlay alpha channel video animation player view using Metal. Example To run the example project, clone the repo, and run pod install from the Exampl

Jul 19, 2022
MMPlayerView - Custom AVPlayerLayer on view and transition player with good effect like youtube and facebook
MMPlayerView - Custom AVPlayerLayer on view and transition player with good effect like youtube and facebook

MMPlayerView Demo-Swift List / Shrink / Transition / Landscape MMPlayerLayer ex. use when change player view frequently like tableView / collectionVie

Jul 29, 2022
MobilePlayer - A powerful and completely customizable media player for iOS
MobilePlayer - A powerful and completely customizable media player for iOS

MobilePlayer A powerful and completely customizable media player for iOS. Table of Contents Features Installation Usage Customization Skinning Showing

Aug 5, 2022
โ–ถ๏ธ video player in Swift, simple way to play and stream media on iOS/tvOS

Player Player is a simple iOS video player library written in Swift. Looking for an obj-c video player? Check out PBJVideoPlayer (obj-c). Looking for

Aug 2, 2022
Player View is a delegated view using AVPlayer of Swift

PlayerView [![CI Status](http://img.shields.io/travis/David Alejandro/PlayerView.svg?style=flat)](https://travis-ci.org/David Alejandro/PlayerView) An

May 31, 2022
Swifty360Player - iOS 360-degree video player streaming from an AVPlayer.
Swifty360Player - iOS 360-degree video player streaming from an AVPlayer.

Swifty360Player iOS 360-degree video player streaming from an AVPlayer. Demo Requirements Swifty360Player Version Minimum iOS Target Swift Version 0.2

Aug 4, 2022