Radiant Media Player

Cloud-hosted vs. self-hosted player



Documentation sections


Cloud-hosted player

All Radiant Media Player files are available through our global CDN (content delivery network) partner CloudFlare for delivery to a global audience.

When using our cloud-player in production we recommend you use a specific player version with subresource integrity. Subresource integrity usage is optional. Subresource integrity will improve security and user experience when loading the player at no extra-cost of performance (where subresource integrity is not supported by the browser/WebView, the player will still load but without the increased security features).

Once Radiant Media Player core JavaScript file (rmp.min.js) has been loaded from our cloud, it will take care of cloud-loading its dependencies (CSS, VAST parser ...) when needed and based on input player settings.

Example for adding Radiant Media Player to your page with subresource integrity:

<script src="https://cdn.radiantmediatechs.com/rmp/4.9.1/js/rmp.min.js" 
  integrity="sha384-fX5m5EETkRkc+whPZ43BDMlgiYsOTl+GwZdQ/i0R1xHxh+eohyaKYXf7gK7b+FWJ"
  crossorigin="anonymous"></script>

You can also cloud-load the latest always up-to-date major release (currently version 4) of the player. In such case subresource integrity cannot be used. Example:

<script src="https://cdn.radiantmediatechs.com/rmp/v4/latest/js/rmp.min.js"></script>

Self-hosted player

In this case scenario you are hosting the player files on your server. Self-hosting is only available for active Radiant Media Player customers.

First download the self-hosted player files package in our back-end (click the "Download Player Files" tab). Unzip the files. You should have the following folder structure:

  • css/
  • dash/
  • examples/
  • flash/
  • hls/
  • js/
  • rmp-vast/
  • three/
  • vtt/
  • LICENSE

Only static files are present within those folders. Folders must not be renamed. If you do not host the player files at the root of your site you must tell the player where to find the required files with the pathToRmpFiles player setting (see below for an example). Example:

<script src="radiantmediaplayer/js/rmp.min.js"></script>
<div id="rmpPlayer"></div>
<script>
var bitrates = {
  mp4: [
    'https://www.rmp-streaming.com/media/bbb-576p.mp4'
  ]
};
var settings = {
  licenseKey: 'your-license-key',
  bitrates: bitrates,
  width: 640,
  height: 360,
  poster: 'https://www.radiantmediaplayer.com/images/poster-rmp-demo.jpg',
  nav: true,
  // Here we tell the player to look for the required dependencies in radiantmediaplayer/
  pathToRmpFiles: 'radiantmediaplayer/'
};
var elementID = 'rmpPlayer';
var rmp = new RadiantMP(elementID);
rmp.init(settings);
</script>

The pathToRmpFiles setting can either be a relative or absolute path or a URL.

Some Google-related player features require loading player dependencies from Google servers. Those files are thus not provided with our self-hosted package. Here is the list:

Google HTML5 IMA SDK

https://imasdk.googleapis.com/js/sdkloader/ima3.js

Google Analytics

https://www.google-analytics.com/analytics.js

Google Cast

https://www.gstatic.com/cv/js/sender/v1/cast_sender.js?loadCastFramework=1

Those files are automatically loaded by the player from Google servers over HTTPS when needed. Referencing these files from Google's servers ensures that you get access to new features and product updates as they become available. You may opt out of the related player features to avoid loading those files from Google servers but the player will then not be able to use the disabled features.


HTTPS support

Loading the player over HTTPS is always recommended. Cloud-hosted files for Radiant Media Player are thus HTTPS compatible. If you self-host the player files you must host them on a domain/server with a valid HTTPS certificate to be HTTPS compatible.

If you use HTTPS all the images, closed captions, logo and streaming URLs called by the player must be HTTPS compatible. Failure to do so can result in unwanted warning/behaviour for your viewers.

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 3.0 License.