ConnectyCube / connectycube-cordova-samples

Cordova code samples for ConnectyCube platform
https://connecycube.com
Apache License 2.0
4 stars 5 forks source link

Video Switch not working in iOS Cordova #3

Open Unixon-solutions opened 4 years ago

Unixon-solutions commented 4 years ago

Getting this error TypeError: undefined is not an object (evaluating 'e.track.kind') in key: "_replaceTracks",

const constraints = { video: deviceId };

        videosession.switchMediaTracks(constraints)
       .then(stream => {})
        .catch(error => {}); 

This works in android and web (android and iOS both) but in iOS cordova its not working which uses cordova-plugin-iosrtc. When above code get called video call get freezes.

nocodedweb commented 4 years ago

Same happening here. What's the solution to this issue?

ccvlad commented 4 years ago

Hi there

Here the WIP PR in the cordova-plugin-iosrts: https://github.com/cordova-rtc/cordova-plugin-iosrtc/pull/544 I've subscribed on PR and will check our SDK and the videochat sample after necessary release of cordova-plugin-iosrts. Then I would unblock cameras switch for iOS Cordova here and here.

DaveLomber commented 4 years ago

@ccvlad @nocodedweb could you please check with this custom branch of Cordova iOS RTC plugin

If it works - then the custom branch can be used until it's merged top master

ccvlad commented 4 years ago

I've checked - not yet

jakesteele commented 4 years ago

Hey,

Just chiming in here, I am trying to use LiveSwitch from FrozenMountain which defaults to using ReplaceTrack. I found a work around to stop and re-start a new local device however the user experience isn't perfect. Hoping the addition this feature will solve that!

Thanks!