Git Product home page Git Product logo

apprtcdemo's Introduction

This directory contains an example Android client for http://apprtc.appspot.com 

Prerequisites:
- Make sure gclient is checking out tools necessary to target Android: your
  .gclient file should contain a line like:
  target_os = ['android', 'unix']
  Make sure to re-run gclient sync after adding this to download the tools.
- Env vars need to be set up to target Android; easiest way to do this is to run
  (from the libjingle trunk directory):
  . ./build/android/envsetup.sh
  Note that this clobbers any previously-set $GYP_DEFINES so it must be done
  before the next item.
- Set up webrtc-related GYP variables:
  export GYP_DEFINES="build_with_libjingle=1 build_with_chromium=0 libjingle_java=1 $GYP_DEFINES"
  export JAVA_HOME=</path/to/JDK>
  export PATH=$JAVA_HOME/bin:$PATH
  To cause WEBRTC_LOGGING to emit to Android's logcat, add enable_tracing=1 to
  the $GYP_DEFINES above.
- When targeting both desktop & android, make sure to use a different output_dir
  value in $GYP_GENERATOR_FLAGS or you'll likely end up with mismatched ARM &
  x86 output artifacts.  If you use an output_dir other than out/ make sure to
  modify the command-lines below appropriately.
- Finally, run "gclient runhooks" to generate Android-targeting .ninja files.

Example of building & using the app:

cd <path/to/libjingle>/trunk
ninja -C out/Debug AppRTCDemo
adb install -r out/Debug/AppRTCDemo-debug.apk

In desktop chrome, navigate to http://apprtc.appspot.com and note the r=<NNN> room 
this redirects to.  Launch AppRTC on the device and enter the same <NNN> into
the dialog box.

Alternatively, replace the <NNN> from the desktop chrome into the following
command:
adb shell am start -a android.intent.action.VIEW -d '"https://apprtc.appspot.com/?r=<NNN>"'
This should result in the app launching on Android and connecting to the apprtc
page displayed in the desktop browser.

Yet another way to is to send the apprtc room URL to the Android device (e.g. using
https://chrome.google.com/webstore/detail/google-chrome-to-phone-ex/oadboiipflhobonjjffjbfekfjcgkhco)
and choose to open the URL with the AppRTCDemo app.

apprtcdemo's People

Contributors

lapmore avatar

Watchers

James Cloos avatar 智清 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.