Setting the audio volume of a video programmatically requires the use of the Flash-only Player API.
You have two options for controlling the volume. Both options require first enabling APIs within the Player Settings.
1) Use the setVolume() method of the VideoPlayerModule to specify a volume level, from 0 to 1.
For example, using Javascript:
<script type="text/javascript">
function onTemplateLoaded(expID) {
var player = brightcove.getPlayer(expID);
var video = bc.player.getModule(APIModules.VIDEO_PLAYER);
var exp = bc.player.getModule(APIModules.EXPERIENCE);
exp.addEventListener(BCExperienceEvent.TEMPLATE_READY, function(){
// sets the volume to 50%
video.setVolume(0.5);
});
}
</script>
2) Use the mute() method of the VideoPlayerModule. This is a boolean value, with the default being "true".
Using the same code structure from the above example:
// mutes the player
video.mute();
For more information about the Flash-only Player API and the steps needed to enable a player for its use, please see the following support document:
The Flash-only Player API Overview
Note: Volume control has not been included in the Smart Player API. iOS devices do not allow for control of the volume outside the built-in system controls (i.e. cannot be done via Javascript). Controlling the volume programmatically in any HTML player is currently not possible.