Player APIs (BrightScript & Ja...
...
Object Reference
Presentation and Widget Object...
roAudioConfiguration
4min
this object allows for mixing and leveling of audio streams before they are passed to audio outputs object creation the roaudioconfiguration object is created with no parameters createobject("roaudioconfiguration") ifaudioconfiguration configureaudio(audio routing as roassociativearray) as boolean configures the audio routing this method will fail if called when audio resources are in use (i e there are active rovideoplayer or roaudioplayer instances) it returns true on success and false on failure the passed associative array can have the following parameters mode string string sets the audio routing mode "dynamic" the default mode mixing audio streams with differing sampling rates will cause playback to fail; differing volume levels will not be normalized; and audio streams cannot be added to an output that currently has audio playing on it other parameters in the associative array are ignored "prerouted" this setting was implemented in firmware 7 0 you can add and remove audio streams on an output that currently has audio playing on it; additional audio routing behavior is determined with the autolevel , pcmonly , and srcrate parameters autolevel string string enables ( "on" ) or disables ( "off" ) volume leveling for audio outputs in the "prerouted" audio mode when this setting is enabled, all pcm audio streams on a particular output will play at a similar volume pcmonly string string enables ( "true" ) or disables ( "false" ) compressed audio support in the "prerouted" audio mode srcrate int int sets the sample rate to which all pcm audio streams are converted in the the "prerouted" audio mode this value can be either 44100 or 48000 getconfiguration() as roassociativearray returns audio configuration information as an associative array mode string string the audio routing mode ( "dynamic" or "prerouted" ) decoder count int int the number of available decoders compressed capable count int int the number of decoders that can route compressed audio autolevel bool bool a flag indicating whether the volume leveling setting is enabled pcmonly bool bool a flag indicating whether the compressed audio support setting is enabled srcrate int int the sample rate to which all pcm audio streams are converted if the mode is "dynamic" , the associative array will contain the mode and decoder count parameter only getclockstatus() as roassociativearray returns audio clock information about the i2c, spdif, and hdmi® outputs