twilio / twilio-video-app-ios

A collaboration application built with the Twilio Video iOS SDK
Apache License 2.0
248 stars 54 forks source link

Implementation of screen broadcasting. #126

Open Fanpei920 opened 4 years ago

Fanpei920 commented 4 years ago

The Problem

Could you implement screen broadcasting in the app with replayKit? (In-app broadcasting and Out-app broadcasting)

timrozum commented 4 years ago

Hi @Fanpei920,

We are actively working to add in-app and system screen capture features to our video SDK. As part of that effort we will integrate system screen capture into the video app in this repo.

Meanwhile you may see this quickstart for in-app and system screen capture examples built on top of the current video SDK.

timrozum commented 4 years ago

@Fanpei920 we have released the in-app screen capture feature in a public beta: https://github.com/twilio/twilio-video-ios/releases/tag/4.0.0-beta3

We are working on system screen capture.

timrozum commented 3 years ago

@Fanpei920 in-app screen capture is now out of beta and available in the 4.0.0 release.

manishmg commented 2 years ago

@timrozum is there any broadcast functionality in this project. I check the quick strater project but when I am try that broadcast functionality in the main app I am getting issues. When twillio register from broadcast the main app video removes automatically. Is there any sample to implement this?

timrozum commented 2 years ago

@manishmg you should be able to use this quickstart to create the broadcast: https://github.com/twilio/video-quickstart-ios/tree/master/ReplayKitExample

And this quickstart to view the broadcast: https://github.com/twilio/video-quickstart-ios/tree/master/VideoQuickStart

Make sure to use this room name when joining the room to view the broadcast: https://github.com/twilio/video-quickstart-ios/blob/c1544311ca82ba6af0e145d2f7fc11898696559d/ReplayKitExample/BroadcastExtension/SampleHandler.swift#L80

If Apple adds iOS support to ScreenCaptureKit in the future, at that time we would probably add features to the SDK for system screen capture and integrate it into the video app in this repo. Unfortunately the new Apple API is only available for macOS.

The broadcast API from Apple is not really optimized for video call screen sharing and so it can be difficult to implement.