void startCallFromJoinUrl(string joinUrl) { CallCapabilities capabilities = new CallCapabilities(); capabilities.WithWhiteboard(); capabilities.WithFileSharing(); capabilities.WithChat(); capabilities.WithScreenSharing(); CallOptions options = new CallOptions(); //options.WithRecordingEnabled(); // if the call started should be recorded //options.WithBackCameraAsDefault(); // if the call should start with back camera //options.WithProximitySensorDisabled(); // if the proximity sensor should be disabled during calls BandyerIntent.Builder builder = new BandyerIntent.Builder(); CallIntentOptions callIntentOptions = builder.StartFromJoinCallUrl(MainActivity.Application, joinUrl); callIntentOptions.WithCapabilities(capabilities); // optional callIntentOptions.WithOptions(options); // optional BandyerIntent bandyerCallIntent = callIntentOptions.Build(); MainActivity.StartActivity(bandyerCallIntent); }
void startCallWithUserAliases(List <string> userAliases, List <BandyerSdkForms.CallCapability> callCapabilities, List <BandyerSdkForms.InCallCapability> inCallCapabilities, List <BandyerSdkForms.InCallOptions> inCallOptions) { CallCapabilities capabilities = new CallCapabilities(); if (inCallCapabilities.Contains(BandyerSdkForms.InCallCapability.Whiteboard)) { capabilities.WithWhiteboard(); } if (inCallCapabilities.Contains(BandyerSdkForms.InCallCapability.FileSharing)) { capabilities.WithFileSharing(); } if (inCallCapabilities.Contains(BandyerSdkForms.InCallCapability.Chat)) { capabilities.WithChat(); } if (inCallCapabilities.Contains(BandyerSdkForms.InCallCapability.ScreenSharing)) { capabilities.WithScreenSharing(); } CallOptions options = new CallOptions(); if (inCallOptions.Contains(BandyerSdkForms.InCallOptions.CallRecording)) { options.WithRecordingEnabled(); // if the call started should be recorded } if (inCallOptions.Contains(BandyerSdkForms.InCallOptions.BackCameraAsDefault)) { options.WithBackCameraAsDefault(); // if the call should start with back camera } if (inCallOptions.Contains(BandyerSdkForms.InCallOptions.DisableProximitySensor)) { options.WithProximitySensorDisabled(); // if the proximity sensor should be disabled during calls } BandyerIntent.Builder builder = new BandyerIntent.Builder(); CallIntentBuilder callIntentBuilder; if (callCapabilities.Contains(BandyerSdkForms.CallCapability.AudioVideo)) { callIntentBuilder = builder.StartWithAudioVideoCall(MainActivity.Application /* context */); } else if (callCapabilities.Contains(BandyerSdkForms.CallCapability.AudioUpgradable)) { callIntentBuilder = builder.StartWithAudioUpgradableCall(MainActivity.Application); // audio call that may upgrade into audio&video call } else if (callCapabilities.Contains(BandyerSdkForms.CallCapability.AudioOnly)) { callIntentBuilder = builder.StartWithAudioCall(MainActivity.Application); // audio only call } else { callIntentBuilder = builder.StartWithAudioVideoCall(MainActivity.Application /* context */); } CallIntentOptions callIntentOptions = callIntentBuilder.With(userAliases); callIntentOptions.WithCapabilities(capabilities); // optional callIntentOptions.WithOptions(options); // optional BandyerIntent bandyerCallIntent = callIntentOptions.Build(); MainActivity.StartActivity(bandyerCallIntent); }