API-Examples icon indicating copy to clipboard operation
API-Examples copied to clipboard

In Screen share, Start broadcast not working in iOS 14

Open sapankajbhalala opened this issue 3 years ago • 20 comments

screen sharing not working when start broadcast from Live Broadcast Popup, And some time giving this error message popup image

AgoraUploader.startBroadcast(to: "CHANNEL_NAME")

Specially it's not working in iOS 14 device. I have checked it's with iOS 13 device and it's working.

sapankajbhalala avatar Feb 22 '21 11:02 sapankajbhalala

yep I have that problem too

apiphoomchu avatar Feb 24 '21 02:02 apiphoomchu

@sapankajbhalala We did some test on ios14 devices but currently can't reproduce the issue. Can I know which device model you are using? There is one known issue that the replay kit extension could be crashed when available runtime memory less than 50M.

yoreland avatar Feb 28 '21 13:02 yoreland

i am having same issue. i did check that the reason for this issue is extension's memory use get increased more then 50 MB which ultimately crash the extension thats why this popup comes.

i have implemented it same as shown in Example project . still having this issue . i have check with different devices . it run properly for some time and then memory goes to above 50 . can anyone guide me how to mange this memory limit . and what is the reason for this memory increase while integrating same as example project . i also check same in example project. in example project its not increasing memory . is there any configuration which i missed ? one more thing is if i comment " sharedAgoraEngine.pushExternalVideoFrame(frame)" this line then memory stays in limit

Please guide me Thanks

dhavalSA avatar Apr 03 '21 22:04 dhavalSA

i am having same issue. i did check that the reason for this issue is extension's memory use get increased more then 50 MB which ultimately crash the extension thats why this popup comes.

i have implemented it same as shown in Example project . still having this issue . i have check with different devices . it run properly for some time and then memory goes to above 50 . can anyone guide me how to mange this memory limit . and what is the reason for this memory increase while integrating same as example project . i also check same in example project. in example project its not increasing memory . is there any configuration which i missed ? one more thing is if i comment " sharedAgoraEngine.pushExternalVideoFrame(frame)" this line then memory stays in limit

Please guide me Thanks

Thanks for the detailed information. Will check on this point and update ASAP

yoreland avatar Apr 03 '21 23:04 yoreland

@yoreland is there any workaround for this issue.

dhavalSA avatar Apr 07 '21 06:04 dhavalSA

@yoreland is there any workaround for this issue.

@dhavalSA we just have some insight of this issue. For bitrate control purpose, SDK will buffer some data for video encoding strategy. After testing on several different devices. It is found that if setting video encoding configuration as CGSize(width: 540, height: 960), the sharing will keep stays in limit.

yoreland avatar Apr 07 '21 06:04 yoreland

i checked this , in AgoraUploader i did this modification private static let videoDimension : CGSize = { let screenSize = UIScreen.main.currentMode!.size var boundingSize = CGSize(width: 540, height: 960) let mW = boundingSize.width / screenSize.width let mH = boundingSize.height / screenSize.height if( mH < mW ) { boundingSize.width = boundingSize.height / screenSize.height * screenSize.width } else if( mW < mH ) { boundingSize.height = boundingSize.width / screenSize.width * screenSize.height } return boundingSize }()

bound size reduced to var boundingSize = CGSize(width: 540, height: 960)

now frequency of this issue is reduced but still issue some times having this issue .

dhavalSA avatar Apr 07 '21 09:04 dhavalSA

it seems like when internet goes down or device is bit slow it goes beyond 50 MB .

dhavalSA avatar Apr 07 '21 09:04 dhavalSA

Thanks for the info. We check on this scenario also and update you.

yoreland avatar Apr 07 '21 16:04 yoreland

it seems like when internet goes down or device is bit slow it goes beyond 50 MB .

@dhavalSA From SDK level it is under optimizing, the problem will be resolved for future release. But for currently, you could only limit resolution and frame rate. You could use setVideoEncoderConfiguation API to modify framerate

yoreland avatar Apr 09 '21 09:04 yoreland

@yoreland Thanks for this solution . when we can expect new release with optimised memory issue with proper fix .

dhavalSA avatar Apr 14 '21 09:04 dhavalSA

And then , same problem meet : )

jingliancui avatar Apr 17 '21 15:04 jingliancui

The fix is still working in progress, as it need an optimization on video encoder part. The fix is scheduled on 3.5.0 version.

yoreland avatar Apr 17 '21 15:04 yoreland

@yoreland Thanks ,Please notify us when 3.5.0 version is available

dhavalSA avatar Apr 19 '21 07:04 dhavalSA

@yoreland When ever I start broadcasting after some time this popup appears? Is there any solution IMG_7391

mahadhaq avatar Apr 22 '21 12:04 mahadhaq

@yoreland When ever I start broadcasting after some time this popup appears? Is there any solution IMG_7391

should be same reason as above discussed. The workaround for now is reduce frame rate and resolution on vidoEncoder configuration

yoreland avatar Apr 22 '21 12:04 yoreland

@yoreland When ever I start broadcasting after some time this popup appears? Is there any solution IMG_7391

should be same reason as above discussed. The workaround for now is reduce frame rate and resolution on vidoEncoder configuration

But the issue is still occuring after reducing the frame rate and resolution

mahadhaq avatar Apr 23 '21 07:04 mahadhaq

Same problem. When will 3.5.0 be released?

koogawa avatar Jul 14 '21 01:07 koogawa

Still have this problem on 3.5.0.3. Any update?

s1lviu avatar Sep 10 '21 15:09 s1lviu

any update?

jonah-katz avatar Nov 24 '22 18:11 jonah-katz