Panel | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||
ON THIS PAGE
|
ifAudioOutput
SetVolume(a As Integer) As Boolean
Sets the volume of the specified output as a percentage represented by an integer between 0 and 100.
SetTone(treble As Integer, bass As Integer) As Boolean
Sets the treble and bass of the specified output. The treble and bass integers can range from -1000 to 1000, with 0 indicating no modification to the audio signal. Each increment represents a change of 0.01db.
SetMute(a As Boolean) As Boolean
Mutes the specified output if True. This method is set to False by default.
GetOutput() As String
Returns the string with which the roAudioOutput object was created.
SetAudioDelay(delay_in_milliseconds As Integer) As Boolean
Delays the audio for a specific audio output by lagging decoded samples before they reach that output. Delays are limited to 150ms or less. Currently, the system software only supports positive delays; therefore, if you need to set the audio ahead of the video, you will need to use roVideoPlayer.SetVideoDelay() instead.
The SetVolume()
and SetMute()
methods work in conjunction with the volume and mute functionality offered by roAudioPlayer. The roAudioPlayer volume settings affect the audio decoder volume. The audio stream is then sent to the assigned outputs, which have an additional level of volume control enabled by roAudioOutput.
The roAudioOutput object affects the absolute volume (as well as mute settings) for an audio output. If two players are streaming to the same output, both will be affected by any settings implemented through roAudioOutput.
Note | ||
---|---|---|
| ||
To control which audio outputs connect to audio player outputs generated by roAudioOutput, use the SetPcmAudioOutputs() and SetCompressedAudioOutputs() methods, which can be used for roVideoPlayer and roAudioPlayer. See the roAudioPlayer entry for further explanation of these methods. |
Example
To enable only HDMI-4 at 3840x2160x60p:
Code Block |
---|
mode=CreateObject("roVideoMode") sm = CreateObject("roArray", 1, 1) sm[0] = CreateObject("roAssociativeArray") sm[0].name = "HDMI-4" sm[0].video_mode="3840x2160x60p" sm[0].transform="normal" sm[0].display_x=0 sm[0].display_y=0 sm[0].enabled=true mode.SetScreenModes(sm) ' Play full screen video with audio going to HDMI-4 rect = createobject("roRectangle",0,0,3840,2160) output = createObject("roAudioOutput", "hdmi:4") vplayer = createobject("roVideoPlayer") vplayer.setrectangle(rect) vplayer.setcompressedaudiooutputs(output) vplayer.playfile("Example.mp4") |