- Forum posts: 1
Apr 10, 2016, 5:56:37 PM via Website
Apr 10, 2016 5:56:37 PM via Website
I am trying to implement functionality like Skype i.e while having Audio/Video call I can go to another screen, but the call will continue, and again I can return to the AV calling screen. I am implementing this idea in Android platform.
The problem I am facing is when I switch the screen, the video is paused, but the audio is continuing. Is there any way to make video continue even if I switch the screen.
I used following code to start the Audio/Video conference from V
ideoChatActivity.java`
app.startLocalMedia(new SingleAction<Exception>() {
@Override
public void invoke(Exception ex) {
if (ex == null) {
// Start the signalling engine.
app.startSignalling(new SingleAction<String>() {
@Override
public void invoke(String ex) {
if (ex != null) {
// alert("Could not start signalling. %s",
// ex.getMessage());
alert("Some problem occured while establishing connection");
Logger.error("YES-Error at startSignalling " + ex);
}
}
}, webasyncURL);
// Start the conference engine.
Logger.error("YES-here-1.2");
app.startConference(iceLinkServerAddress, roomName, video, container, wheel, audioOnlyDefaultAvatar,
muteControlToggle, videoOnOffToggle, speakerToggle, videoChatActivity,
new SingleAction<Exception>() {
@Override
public void invoke(Exception ex) {
if (ex != null) {
// alert("Could not start conference. %s",
// ex.getMessage());
alert("Some problem occured while initializing video call");
Logger.error("YES-Error at startconference " + ex.getLocalizedMessage());
}
}
});
} else {
// alert("Could not start local media. %s",
// ex.getMessage());
Logger.error("YES-Error at startLocalMedia " + ex.getLocalizedMessage());
}
}
}, video, audio);
When I back to the previous activity while doing Audio/Video conference I called the service to strat startLocalMedia.
Here is my C
ameraService.java`
VideoChatActivity.app.startLocalMedia(new SingleAction<Exception>() {
@Override
public void invoke(Exception ex) {
if (ex == null) {
// Start the signalling engine.
VideoChatActivity.app.startSignalling(new SingleAction<String>() {
@Override
public void invoke(String ex) {
if (ex != null) {
// alert("Could not start signalling. %s",
// ex.getMessage());
//alert("Some problem occured while establishing connection");
Logger.error("YES-Error at startSignalling " + ex);
}
}
}, VideoChatActivity.webasyncURL);
// Start the conference engine.
VideoChatActivity.app.startConference(VideoChatActivity.iceLinkServerAddress, VideoChatActivity.roomName, VideoChatActivity.video, VideoChatActivity.container, VideoChatActivity.wheel, VideoChatActivity.audioOnlyDefaultAvatar,
VideoChatActivity.muteControlToggle, VideoChatActivity.videoOnOffToggle, VideoChatActivity.speakerToggle, VideoChatActivity.videoChatActivity,
new SingleAction<Exception>() {
@Override
public void invoke(Exception ex) {
if (ex != null) {
// alert("Could not start conference. %s",
// ex.getMessage());
//alert("Some problem occured while initializing video call");
Logger.error("YES-Error at startconference " + ex.getLocalizedMessage());
}
}
});
} else {
// alert("Could not start local media. %s",
// ex.getMessage());
//alert("Some problem occured while getting media devices");
Logger.error("YES-Error at startLocalMedia " + ex.getLocalizedMessage());
}
}
}, VideoChatActivity.video, VideoChatActivity.audio);
Recommended editorial content
With your consent, external content is loaded here.
By clicking on the button above, you agree that external content may be displayed to you. Personal data may be transmitted to third-party providers in the process. You can find more information about this in our Privacy Policy.