Player APIs (BrightScript & Ja...
JavaScript APIs
audiooutput
3min
this object allows individual control of audio outputs on the player audiooutput idl constructor(string output name) ] interface audiooutput { attribute float volumelinear; attribute float volumedb; attribute long delay; attribute float treble; attribute float bass; attribute boolean mute; readonly attribute string name; }; object creation to create an audiooutput object, use the require() method you must also enter an audiooutputclass (in the example below, "analog" is used) the audiooutputclass parameter can take the following strings “none” "hdmi” or "hdmi 1" , "hdmi 2" , "hdmi 3" , or "hdmi 4 " for series 5 players with multiple outputs “usb” “spdif” "analog" “analog\ n” "earc" (au335 only) support for multiple usb outputs using the usb port naming terminology see rodeviceinfo docid\ utkdmpos1ulxaoylx1ns6 var audiooutputclass = require("@brightsign/audiooutput"); var audiooutput = new audiooutputclass("analog"); audiooutput use this interface to create audiooutput objects volumelinear float float sets the linear volume of the specified output as a percentage represented by a floating point number between 0 and 1 (1 0 is 100%) volumedb float float sets the volume in decibels of the specified output as a percentage represented by a floating point number where 0 0 is 100% delay long long on series 3 and 4 players, delays the audio for a specific audio output by lagging decoded samples before they reach that output delays are in milliseconds treble float float on series 3 and 4 players, sets the treble of the specified output in decibels the treble floating point numbers can range from 10 to 10, with 0 indicating no modification to the audio signal bass float float on series 3 and 4 players, sets the bass of the specified output in decibels the bass floating point numbers can range from 10 to 10, with 0 indicating no modification to the audio signal mute boolean boolean mutes the specified output if true this method is set to false by default name string string the name of the output plugstate boolean boolean has a value of true if the corresponding output has a plug in it, false if it does not, or undefined if the plug state cannot be determined on the current hardware or os version this is supported by bos 9 0 163 onwards