AgoraIO / API-Examples

Play with AgoraSDK and have fun! Everything you need to start learning Agora.
296 stars 218 forks source link

Screen share feature not working on iPhone12 iOS14.4.2 #148

Closed jingliancui closed 1 week ago

jingliancui commented 3 years ago

While I deploy the sample to the iPhone 12 iOS14.4.2 ,the extension not work and no breakpoint will be hit on xcode. But it can be run and debug on the iPhone 7 plus iOS13.6.

yoreland commented 3 years ago

you may need to set "ScreenShare" as channel name. Currently it is hardcoded as need to enable App Group to transfer channel name across processes

jingliancui commented 3 years ago

@yoreland Hello youreland, My Channel had been set as "ScreenShare" on the agora console and my app , But extension still not run . On the app, after press the start broadcast button , after counting down 3 second finished. Nothing run and no record start. Maybe I could upload the video here.

yoreland commented 3 years ago

Okay, do you have chance to verify the same on any other device?

dhavalSA commented 3 years ago

@jingliancui First of all if you want make your breakpoints working which are set in extension, you have to run your project by selecting extensions's target . if you run application with parent app's target then extension's breakpoint will not work .

now for the other issue you reported here , if after clicking start broadcast and you can see red mark in status bar that means broadcast is working from broadcaster side . now if you are not receiving stream on other user then you need to mange uid because in this API example there is one condition on receiving stream if(isScreenShareUid(uid: uid)) { LogUtils.log(message: "Ignore screen share uid", level: .info) return } you have to mange this condition .

if after clicking broadcast button nothing happen then there is possibility that some times due to many attempts broadcaster extension may malfunction . in such case you can fix such issue by restarting your device .

if non of this fixes work then please share video .

i had similar issue with this , but now i have working feature in one of my application

Hope this help you Thanks

jingliancui commented 3 years ago

@dhavalSA Awesome! Restart device fix this problem! This issue bothers me long time because never turn off my phone. What an interesting things is apple device need restart to fix extension issue.

18840851520 commented 3 years ago

The problem persisted after the restart

tamworth commented 3 weeks ago

@jingliancui you can try again using the new version of the API-Example.