WCS provides SDK to develop client applications for the iOS platform.
- The browser connects to the server via the Websocket protocol and sends the publish command.
- The browser captures the microphone and the camera and sends the WebRTC stream to the server.
- The iOS device connects to the server via the Websocket protocol and sends the play command.
- The iOS device receives the WebRTC stream from the server and plays it in the application.
Quick manual on testing
Playing a video stream in an iOS mobile application
1. For the test we use:
- the demo server at demo.flashphoner.com;
- the Two Way Streaming web application to publish the stream;
- the iOS mobile application to play the stream.
2. Open the Two Way Streaming web application. Click Connect, then Publish. Copy the identifier of the stream:
3. Run the application to publish the stream on iPhone. Enter the URL of the WCS server and the name of the published stream, then click "Play". The stream starts playing from the server:
Below is the call flow when using the Player example.
1. Establishing a connection to the server.
2. Receiving from the server an event confirming successful connection.
ConnectionStatusEvent ESTABLISHED code
3. Playing the stream.
4. Receiving from the server an event confirming successful playing of the stream.
StreamStatusEvent, status PLAYING code
5. Receiving the audio and video stream via WebRTC
6. Stopping the playback of the stream.
7. Receiving from the server an event confirming the playback of the stream is stopped.
ConnectionStatusEvent DISCONNECTED code