Twilio Video Xamarin Android

Twilio Video Android SDK binding for Xamarin

NuGet

How to Build

Twilio.Video Android 7.0.3 (December 6th, 2021)

AndroidDexTool should be set to d8 for TargetFrameworkVersion == v9.0 or later. You also need ReLinker Xamarin Bindings for Android: https://github.com/xbindings/relinker-android-binding

The aar is already included into this repostiory. So just build the project.    

or

Download aar/jar version you needed from https://bintray.com/twilio/releases/video-android and copy it to src\Jars. Then you will need to change res/values/values.xml and add missing <attr format="boolean" name="overlaySurface"/> attribute if needed. And rename /src/Jars/ARR/libs/libwebrtc.jar to libwebrtc_2.jar if you are going to use Twilio.Voice SDK in you project.

$ unzip video-android-7.0.3.aar -d tempFolder    
# Change whatever you need    
$ jar cvf video-android-7.0.3.aar -C tempFolder/ .

Changed properties

ScaleType, mirror, or overlaySurface have been prefixed. These attributes defined for VideoView and VideoTextureView have been prefixed with tvi to prevent attribute name clashes. Reference the following snippets to update your application layout files. For example: app:tviScaleType="fit"

Proguard settings

-keep class tvi.webrtc.** { ; } -keep class com.twilio.video.* { *; } -keepattributes InnerClasses

Sample

We don't have C# version of twilio quickstart application, so I highly recommend you to read about using native library bindings for xamarin and check official Twilio quickstart guides.

video-quickstart-android

Contributions

If you have a bugfix or an update you'd like to add, please open an issue. All pull requests should be opened against the master branch.