Anbox Cloud SDKs

Anbox Cloud provides a series of Software Development Kits (SDKs) to facilitate integrating and extending Anbox Cloud for different use cases:

  • Anbox Platform SDK

  • AMS SDK

  • Anbox Streaming SDK

Anbox Platform SDK

The Anbox Platform SDK provides support for developing custom platform plugins, which allows cloud providers to integrate Anbox with their existing infrastructure. The SDK provides several integration points for things like rendering, audio or input processing.

For more details about custom platform plugins, refer to the Anbox Platform SDK API documentation.

Download and installation

The Anbox Platform SDK can be downloaded via Git from GitHub:

git clone https://github.com/canonical/anbox-platform-sdk.git

You need the following build dependencies:

sudo apt install -y --no-install-recommends cmake build-essential ninja-build dh-exec cmake-extras libgmock-dev libelf-dev

Examples

The Anbox Platform SDK provides a collection of example platform plugins to help developers get started with plugin development. The following examples are included:

  • minimal - A platform plugin that provides a sample implementation of a minimal platform plugin to demonstrate the general plugin layout.

  • audio_streaming - A platform plugin that provides a more advanced example of how a platform plugin can process audio and input data.

AMS SDK

The AMS SDK offers a set of Go packages and utilities for any external Go code to be able to connect to the AMS service through the exposed REST API.

See the AMS SDK documentation on GitHub for more information.

Download and installation

The AMS SDK can be downloaded via Git from GitHub:

git clone https://github.com/canonical/ams-sdk.git

To start using the SDK, simply add the content of the provided SDK zip file into your projects vendor/ directory or your GOPATH.

Examples

The AMS SDK comes with a set of examples demonstrating the capabilities of the SDK. You can find them in the examples directory of the AMS source.

Authentication setup

Clients must authenticate to AMS before communicating with it. For more information, see How to control AMS remotely and the AMS SDK documentation on GitHub.

Anbox Cloud Streaming SDK

The Anbox Cloud streaming SDK allows the development of custom streaming clients using JavaScript. This SDK handles all aspects of streaming, from the WebRTC protocol to handling controls, game pads, speakers and screen resolutions.

Under the hood, the SDK is actually comprised of two components:

  • The connector that communicates to the stream backend (either the stream gateway or your own middleware) and initiates the WebRTC setup.

  • The stream class that displays the video and audio feed, handle controls, life-cycle events and more.

Having these two components makes it easier to plug your own software in the SDK rather than having to re-write everything again.

Features

Feature

JavaScript SDK

Video streaming

Audio streaming

Microphone support

Dynamically change Android foreground activity

Send commands to the Android container

Game pad support

Camera support

Pointer lock (Experimental)

Sensor support

Location support

Supported platforms

All

Zero Copy rendering and decoding

Supported video codecs

VP8, H.264, AV1

Download and installation

To use the Anbox Cloud streaming SDK, you must have deployed the Anbox Streaming Stack. See How to deploy Anbox Cloud with Juju for more information.

You can download the Anbox Cloud streaming SDK via Git from GitHub:

git clone https://github.com/canonical/anbox-streaming-sdk.git

Examples

The Anbox Cloud streaming SDK comes bundled with examples to help you get started. They are located in the examples directory.