RTCMultiConnection Docs

Write Android apps using RTCMultiConnection

HOME © Muaz Khan . @WebRTCWeb . Github . Latest issues . What's New?

All RTCMultiConnection Demos has their equivalent (open-sourced) apps for both platforms: Android and iOS.

Development Environment Prerequisites

  1. Oracle Java Development Kit (JDK)
  2. Apache Ant
  3. Android SDK
For a clear (comprehensive) guide, please visit: appache: installing-the-requirements Or check if your system is ready

Cordova Prerequisites

Install Cordova:

npm install -g cordova

Check if your system is ready

cordova requirements

Above command will/should display a result similar to this:

Java JDK: installed
Android SDK: installed
Android target: installed android-23,Google Inc.:Google APIs:23
Gradle: installed ----------------- this one seems redundant
Please make sure to re-install the prerequisites if you get different result.

Download Open-Sourced Cordova Apps

Download any HTML-demo-file from this page and search for "blockquote". You will find a link to download the open-sourced app/codes.

Example demo file: github/Scalable-Broadcast.html#L113

Download & extract the mobile-app's ZIP file.

Modify Config.xml

"Config.xml" file will have following information:

<?xml version='1.0' encoding='utf-8'?>
<widget id="com.webrtc.scalablebroadcast" version="3.0.0" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
    <icon src="www/img/icon.png" />

Please mdofiy following XML attributes:

  1. "id" attribute: It should be something like this:
    <widget id="com.yourdomain">
  2. "name" attribute: Name should NOT have spaces or special characters. Consider it as a "username":
  3. "icon" attribute: You can replace "icon.png" file with your own app-icon.

Re-Add Cordova-based Android platform

# first of all, remove old android platforms
cordova platform remove android

# recommended version: 5.1.0
# however you can use any newer version

cordova platform add android@5.1.0 --save
It will re-generate android prerequisites according to your app's new name, id, and icon. (things that you modifed in the config.xml file)

Build APK File

cordova build android
Now go to "platforms/android/build/outputs/apk" and you will find this file: "android-armv7-debug5.apk"

Test on Emulator

cordova emulate android

Latest Issues

Want to ask a Question?

You can include your email for private conversation!

Latest Updates