AudioStreamSynchronized

继承: AudioStream < Resource < RefCounted < Object

Stream that can be fitted with sub-streams, which will be played in-sync.

描述

This is a stream that can be fitted with sub-streams, which will be played in-sync. The streams being at exactly the same time when play is pressed, and will end when the last of them ends. If one of the sub-streams loops, then playback will continue.

属性

方法

AudioStreamget_sync_stream ( stream_index: int ) const1
floatget_sync_stream_volume ( stream_index: int ) const1
voidset_sync_stream ( stream_index: int, audio_stream: AudioStream )
voidset_sync_stream_volume ( stream_index: int, volume_db: float )

常量

MAX_STREAMS = 32

Maximum amount of streams that can be synchronized.


属性说明

int stream_count = 0

  • void set_stream_count ( value: int )
  • int get_stream_count ( )

Set the total amount of streams that will be played back synchronized.


方法说明

AudioStream get_sync_stream ( stream_index: int ) const1

Get one of the synchronized streams, by index.


float get_sync_stream_volume ( stream_index: int ) const1

Get the volume of one of the synchronized streams, by index.


void set_sync_stream ( stream_index: int, audio_stream: AudioStream )

Set one of the synchronized streams, by index.


void set_sync_stream_volume ( stream_index: int, volume_db: float )

Set the volume of one of the synchronized streams, by index.

2

本方法通常需要用户覆盖才能生效。

1

本方法无副作用,不会修改该实例的任何成员变量。

3

本方法除了能接受在此处描述的参数外,还能够继续接受任意数量的参数。

4

本方法用于构造某个类型。

5

调用本方法无需实例,可直接使用类名进行调用。

6

本方法描述的是使用本类型作为左操作数的有效运算符。

7

这个值是由下列位标志构成位掩码的整数。

8

无返回值。