Adotube logo


Adotube Brightcove Player


Above you see a demo of the Adotube Brightcove Player, which is the Brightcove Player integrated with the Adotube Overstream Platform. The sample offer is configured to be shown from the time the video player is launched to 1/2 of the way into the video.

The idea behind the Adotube Brightcove Player is that you can use it in exactly the same way as you can use the Brightcove Player, but in addition it can show advertising content from Adotube. So whether you are an existing or an aspiring Brightcove customer, you can now get the best of both worlds.

Source & Documentation

The Adotube Brightcove Player Distribution for the above integration is available. If you would like to see how this was accomplished, you can download the extended Adotube Brightcove Player Source Code. Please note that the sample integrations from the archives will not run on the local system, but need to be uploaded to a web server to work.

This integration was performed according to the Overstream Platform Plugin Interface Specification for AS2 Players.

Input Parameters

The parameters overstreamPlatformURL and omlSource that need to be dynamically specified at embed time are obtained from the Embed Code Tab for a placement in the Adotube Publisher Management Console. You should select the "Third-Party Player" Integration option in the Placement Configuration.

Integration Methods

The Adotube Brightcove Player supports all the three integration methods supported by the Brightcove player itself (embeded HTML, ActionScript and JavaScript). The instructions below assume that you have downloaded the Adotube Brightcove Player Distribution and are hosting it on your server.

HTML

First of all, go to the Brightcove Admin Section and get the publishing code for the video you want to publish. Select the 'HTML to Embed' tab from the 'Publishing codes' window and copy the code you found there and paste it in your html. At this point you have a fully functional Brightcove player, but in order to add the Adotube Overstream Platform Adapter to it you have to change a couple things in the embed code.

Change the source of the swf file from (e.g.) 'http://services.brightcove.com/services/viewer/federated_f8/1460842893' to point to the location of the AdotubeBrightcovePlayer.swf .

<embed src="http://yourserver/pathto/AdotubeBrightcovePlayer.swf" bgcolor="#FFFFFF" ...

The second and last step is to add the parameters overstreamPlatformURL and omlSource to the flashVars part of the embed in order for the Adotube Overstream Platform to work. Example (please note that you might want to encode the URLs in case any of them contains the '&' character):

flashVars="overstreamPlatformURL=http://www.adotube.com/docs/adapters/OP/OverstreamPlatform.swf&
omlSource=http://www.adotube.com/docs/adapters/OP/sampleOML.xml&...
Please note that, if the dimensions of your embed are different than the default Brightcove embed dimensions (486x412), you must also add two extra variables to the flashVars(eWidth and eHeight). So for example the begining of the flashVars string could look like this:
flashVars="eWidth=400&eHeight=350&overstreamPlatformURL=http://www.adotube.com/docs/adapters/OP/OverstreamPlatform.swf&
omlSource=http://www.adotube.com/docs/adapters/OP/sampleOML.xml&...

ActionScript

Having obtained the ActionScript publishing code from Brightcove, add the following lines at the beginning of the script:

_root.adotubeBootstrap = function() {
	com.adotube.adapter.brightcove.BrightcoveOPAdapter.singleton.init();
} 

Also you must change the following line in the Brightcove code:

bcPlayer.onTemplateLoaded = function() {};

to this:

bcPlayer.onTemplateLoaded = function() {
	_root.adotubeBootstrap();
};

Make sure that when you compile your swf, you have the com folder and its contents from the Adotube Brightcove Player Source Code archive in the same folder as your .FLA (or in any case in the classpath for that .FLA). Remember also that you will need to set parameters overstreamPlatformURL and omlSource when embedding your swf (or you can hardcode them into the swf if you want).

JavaScript

To use the JavaScript integration method you have to copy the code that you get from Brightcove in your HTML and change this line:

<script src="http://admin.brightcove.com/js/experience_util.js" type="text/javascript"...

to point to the experience_utils.js file that can be found the in the Adotube Brightcove Player Distribution. For example:

<script src="experience_util.js" type="text/javascript"...

Also, after the this line:

config["preloadBackColor"] = "#FFFFFF";

you should specify the parameters overstreamPlatformURL, omlSource:

config["overstreamPlatformURL"] = "..."; 
config["omlSource"] = "...";

Normally experience_util.js should be hosted in the same folder as the AdotubeBrightcovePlayer.swf; if it is not, please change the following line in the class to point to the location of AdotubeBrightcovePlayer.swf:

var swfFile = "http://path/to/AdotubeBrightcovePlayer.swf";