Integration guide

Download SDK


This guide lists the software components required by the player and how they should be integrated.



It is recommended that you first use the sample basic-playback application (see below) to confirm that playback works using the downloaded opy-sdk-android-SW_VERSION-production.jar and opy_licence files.


The following documentation is provided:

Contains several small sample applications that demonstrate how to use both simple and advanced features, for example, playing clear streams and playing encrypted streams.

HTML documentation for the player Java API.

Software components

The player consists of the following software components:


This mandatory file is the Java library file for controlling the player. It should be placed in the libs directory. For example, if you use it with the basic-playback sample application, place it in the ../basic-playback/libs directory (which you need to create if it does not exist).


This mandatory file is an encrypted licence that controls which player features and platforms are enabled based on your licence agreement. The player will not work without it. There are two types of licence:

  • Trial licence – a time-limited licence that can be downloaded to evaluate the player. It works with any application ID domain name.
  • Purchased licence – the licence that is provided once you have purchased the product. It only works with the application ID domain name you provided at time of purchase.

It must be placed in the Android raw directory. For example, if you use it with the basic-playback sample application, place it the ../basic-playback/src/main/res/raw directory (which you need to create if it does not exist).


This optional file can be used to modify default playback behaviour based on device capabilities or device name (for further information see Player profiling).

Android compatibility

The player is designed for use with Android 5.0 (Lollipop) API level 21 and above.

Build environment setup

Development toolchain

  • Android Studio – latest version
  • Android SDK – install the latest version from Android Studio when prompted.
  • Gradle – use the latest version as recommended by Android Studio.
  • JDK – use the version provided with Android Studio.

Setting up Android Studio

  1. Launch Android Studio.
  2. Copy the basic playbacks application to a local directory.
  3. From the Welcome to Android Studio launch page, select Import Project, then select the basic playback sample application.
  4. If prompted, select Yes to install missing programs and sync.
  5. From the SDK Manager, select platform support from Android 5.0 (Lollipop) and later. Optionally, just select the platforms for the device(s) you will be developing/testing on.

Build and run the sample application using the trial licence

  1. With the basic playback project loaded, download the trial opy_licence file and place it in the raw directory (as described above).
  2. Confirm that the opy-sdk-android-SW_VERSION-production.jar file is in the libs directory (as described above).
  3. Modify the build.gradle file to point to the correct .jar filename. (For example, compile files('libs/opy-sdk-android-SW_VERSION-production.jar') OR rename the opy-sdk-android-SW_VERSION-production.jar file to nmpsdk.jar.)
  4. With an Android device connected, from Android Studio run the basic playback project. > Note > > The application must run on a Android device and not on an Android Studio Simulator.
  5. Big Buck Bunny should be playing on the Android target device.
  6. You can check the SDK version by looking for "This player is powered by SDK version:" in Android Studio's logcat output OR by using the player API NMPSDK.getSdkVersion().

Build and run the sample application using the purchased licence

The purchased licence will only work with the application ID domain name that you registered when you purchased it. To use the purchased licence with any sample application, you must change the sample application domain name.

For example, if your application domain name is com.your_company.your_player, change the applicationId value in Basic playback->build.gradle from com.nagra.example.basic to com.your_company.your_player.

Then follow the instructions in the trial licence example above.

Additional considerations

  • Only one instance of the player is supported at any given time.
  • When switching streams, the player must be stopped (NMPVideoView.StopPlayback()) before starting the new playback session.