Awesome Open Source
Awesome Open Source

Red5 Pro iOS Streaming Testbed

This repository contains a simple project with a number of examples that can be used for testing and reference.

Requirements

Red5 Pro Server

You will need a functional, running Red5 Pro server web- (or locally-) accessible for the client to connect to. If you already have a Red5 Pro Account, you can find the Red5 Pro Server download at https://account.red5pro.com/download.

For more information visit Red5Pro.com.

Red5 Pro SDK License Key

A Red5 Pro SDK License Key is required to use the iOS Mobile SDK. If you already have a Red5 Pro Account, you can find your Red5 Pro SDK License Key at https://account.red5pro.com/overview.

You will need to copy the SDK License into the license_key property field of the tests.plist.

Setup

You will need to modify /Red5ProTestbed/tests.plist (the domain value) to point to your host server instance's IP address and update the license_key property to that of your Red5 Pro SDK License. If you do not, the examples will not function when you build. If you are running the server locally, then your machine and mobile device need to be on the same WiFi network.

Once you have modified your settings, you can run the application for simulator or device.

Note: Publishing does not currently work on simulator!

Examples

Publishing

1080p
A high quality publisher. Note that this is the publish test with a non-default 'bitrate' and camera size values set in tests.plist
ABR
A high bitrate publisher with AdaptiveBitrateController
Aspect Ratio
A publish example that includes modifying the scale mode of the preview display
Authentication
An example of publishing a stream as an authenticated user
AV Category
A publish example that includes manual handling of iOS's AV Session
Background
An example that continues to publish audio while the app is in the background
Bandwidth Detection - Upload
An example that tests the upload speed between the device and server before publishing.
Camera Device Orientation
A combination of the Camera Swap and Device Orientation examples
Camera Swap
Touch the screen to swap which camera is being used! Verify with flash, android, or other iOS device running subscribe test that camera is swapping properly and no rendering problems occur.
Custom Audio Source
Uses a custom controller to modify audio data for the publisher.
Custom Video Source
Uses a custom controller to supply video data to the publisher.
Device Orientation
Rotate the device to update the orientation of the broadcast stream. Verify with browser-based players (WebRTC, Flash, HLS), Android, or other iOS device running subscribe test that image is rotating properly and no rendering problems occur.
Encrypted
An example that encrypts all traffic between the device and server.
Image Capture
Touch the publish stream to take a screen shot that is displayed!
High Quality Audio
R5Microphone.sampleRate is set to 44100 (the default is 16000).
Local Record
A publish example that records stream data locally on the device.
Mute/Unmute
Touch the screen to toggle between sending Audio & Video, sending just Video, sending just Audio, and sending no Audio or Video. Turning off and on the media sources is considered mute and unmute events, respecitively
Record
A publish example that records stream data on the server.
Remote Call
The publish portion of the remote call example - sends the remote call.
Stream Manager
A publish example that connects with a server cluster using a Stream Manger
Stream Manager Encrypted
A publish example that encrypts traffic durring a broadcast over Stream Manager.
Stream Manager Transcoder
A publish example that uses transcoding broadcast over Stream Manager.
Telephony Interrupt
An example on "gracefully" handling interrupts while broadcasting - such as receiving an declining a phone call
Two Way
An example of simultaneously publishing while subscribing - allowing a conversation. Includes stream detection and auto-connection.
Two Way - Stream Manager
The two way example, modified to work with a stream manager. Includes stream detection and auto-connection.
Shared Object
An example of sending data and messages between clients through remote shared objects.
Send/Recieve
An example of sending data and messages from a Broadcaster to N-Subscribers.

Subscribing

Aspect Ratio
Change the fill mode of the stream. scale to fill, scale to fit, scale fill. Aspect ratio should be maintained on first 2.
Audio Delay
Captures the raw audio from the stream and delays it with a custom buffer implementation
Authentication
An example of subscribing to a stream as an authenticated user
AV Category
A subscribe example that includes manual handling of iOS's AV Session
Background
A subscribing example that can continue when the app moves into the background
Bandwidth Test
Detect Insufficient and Sufficient BW flags. Test on a poor network using a publisher that has high video quality. Video should become sporadic or stop altogether. The screen will darken when no video is being received.
Bandwidth Detection - Download
An example that tests the download speed between the device and server before subscribing.
Bandwidth Detection - Dual
An example that tests both the upload and download speeds between the device and server before subscribing.
Cluster
An example of connecting to a cluster server.
Encrypted
An example that encrypts all traffic between the device and server.
Image Capture
Touch the subscribe stream to take a screen shot that is displayed!
Metal View
Uses a metal based view to display a stream.
Mute
Allows toggle of mute playback.
No View
A proof of using an audio only stream without attaching it to a view.
Reconnect
An example of reconnecting to a stream on a connection error.
Remote Call
The subscribe portion of the remote call example - receives the remote call.
Set Volume
Shows setting the playback volume for the stream.
Stream Manager
A subscribe example that connects with a server cluster using a Stream Manger
Stream Manager Encrypted
A subsribe example that encrypts traffic while receiving a broadcast over Stream Manager.
Telephony Interrupt
An example on "gracefully" responding to interrupts while subscribed to a broadcasting - such as the publisher receiving an declining a phone call
Two Streams
An example of subscribing to multiple streams at once, useful for subscribing to a presentation hosted by two people using a Two Way connection.

Notes

  1. For some of the above examples you will need two devices (a publisher, and a subscriber). You can also use a web browser to subscribe or publish via Flash, http://<your_red5_pro_server>:5080/live.
  2. You can see a list of active streams by navigating to http://your_red5_pro_server:5080/live/subscribe.jsp (will need to refresh this page after you have started publishing).

Analytics


Get A Weekly Email With Trending Projects For These Topics
No Spam. Unsubscribe easily at any time.
swift (7,529
ios (3,487
sdk (493
live-streaming (31

Find Open Source By Browsing 7,000 Topics Across 59 Categories