Coder Social home page Coder Social logo

agoraio / video-sdk-samples-android Goto Github PK

View Code? Open in Web Editor NEW
5.0 8.0 3.0 14.89 MB

Android reference app for Agora Video SDK

Home Page: https://docs.agora.io/en/video-calling/get-started/get-started-sdk?platform=android

License: MIT License

Kotlin 100.00%
agora android reference-app rtc video-sdk

video-sdk-samples-android's Introduction

Agora Video SDK for Android reference app

This reference app demonstrates the use of Agora's Video SDK for real-time audio and video communication. It is a robust and comprehensive documentation reference app for Android, designed to enhance your productivity and understanding. It's built to be flexible, easily extensible, and beginner-friendly.

Clone the repo, run and test the samples, and use the code in your own projects. Enjoy!

Samples

This reference app includes several samples that illustrate the functionality and features of Agora Video and Voice SDKs. Each sample is self-contained and the relevant code can be found in its own folder in the root directory. For more information about each sample, see:

Get Started

Develop

Integrate Features

To view the UI implementation, open the relevant Activity Class file here.

Prerequisites

Before getting started with this reference app, ensure you have the following set up:

  • Android Studio 4.1 or higher
  • Android SDK API Level 24 or higher
  • A mobile device that runs Android 4.1 or higher
  • An Agora account and project
  • A computer with Internet access. Ensure that no firewall is blocking your network communication.

Run the app

  1. Clone the repository

    To clone the repository to your local machine, open Terminal and navigate to the directory where you want to clone the repository. Then, use the following command:

    git clone https://github.com/AgoraIO/video-sdk-samples-android.git
  2. Open the project

    Launch Android Studio. From the File menu, select Open... and navigate to the android-reference-app folder. Start Gradle sync to automatically install all project dependencies.

  3. Modify the project configuration

    The app loads connection parameters from the config.json file. Ensure that the file is populated with the required parameter values before running the application.

    • uid: The user ID associated with the application.
    • appId: (Required) The unique ID for the application obtained from Agora Console.
    • channelName: The default name of the channel to join.
    • rtcToken:An token generated for channelName. You generate a temporary token using the Agora token builder.
    • serverUrl: The URL for the token generator. See Secure authentication with tokens for information on how to set up a token server.
    • tokenExpiryTime: The time in seconds after which a token expires.

    If a valid serverUrl is provided, all samples use the token server to obtain a token except the SDK quickstart project that uses the rtcToken. If a serverUrl is not specified, all samples except Secure authentication with tokens use the rtcToken from config.json.

  4. Build and run the project

    To build and run the project, select your connected Android device or emulator and press the Run button in Android Studio.

  5. Run the samples in the reference app

    From the main app screen, choose and launch a sample.

Contact

If you have any questions, issues, or suggestions, please file an issue in our GitHub Issue Tracker.

video-sdk-samples-android's People

Contributors

billy-the-fish avatar saudsami avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

majdaelai

video-sdk-samples-android's Issues

Issue with Agora ScreenShare on Android

I am following this guidelines to use Screen sharing with my android project. but I am getting this runtime error while starting a screen sharing:

W/System.err: java.lang.NoSuchMethodError: no non-static method "Lio/agora/rtc2/extensions/MediaProjectionSource$ScreenCaptureParameters;.<init>(IIIZ)V"
E/rtc: #
    # Fatal error in: ../../../../../media_sdk_script/media_engine2/webrtc/sdk/android/src/jni/jni_generator_helper.cc, line 59
    # last system error: 2
    # Check failed: !env->ExceptionCheck()
    # error during GetMethodID: <init>, (IIIZ)V

android-reference-app error

I don't understand why none of these video sdk providers , have any working sample to make the functionality understand. Literally, this is my third library and this also doesn't work. I guess it doesn't matter for the companies to make it easy for the developers. Most irritating thing is you cannot even get help directly for these issues. I mean seriously, raise a ticket and that page doesn't even include this option. Instead of wasting hours and days on the internet looking for a fix I would rather move onto some other sdk. I have to work on my own app that's already enough for me, so why would I waste time on fixing your sdk issues. Seriously, fix your samples. Trying to load the android reference app in android studio fails with the following error:-

Null extracted folder for artifact: ResolvedArtifact(componentIdentifier=AgoraScreenShareExtension.aar, variant=local file, variantName=null, artifactFile=D:\SourceCodes\Classes\agora\video-sdk-samples-android\product-workflow\libs\AgoraScreenShareExtension.aar, isTestFixturesArtifact=false, extractedFolder=null, publishedLintJar=null, dependencyType=ANDROID, isWrappedModule=false, buildMapping={__current_build__=D:\SourceCodes\Classes\agora\video-sdk-samples-android\android-reference-app})
agora_error

Add the remaining VSDK examles

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.