/// <summary> /// Stop a playing channel. /// </summary> /// <param name="channel">Channel id.</param> public void StopChannel(SoundChannelId channel) { if (channel.IsValid) { _BonEngineBind.BON_Sfx_StopChannel(channel); } }
/// <summary> /// Set sound channel panning, /// </summary> /// <param name="channel">Channel id.</param> /// <param name="panLeft">Pan sound left - value should be 0.0-1.0.</param> /// <param name="panRight">Pan sound right - value should be 0.0-1.0.</param> public void SetChannelPanning(SoundChannelId channel, float panLeft, float panRight) { if (channel.IsValid) { _BonEngineBind.BON_Sfx_SetChannelPanning(channel, panLeft, panRight); } }
/// <summary> /// Set sound channel distance, /// </summary> /// <param name="channel">Channel id.</param> /// <param name="distance">Channel distance.</param> public void SetChannelDistance(SoundChannelId channel, float distance) { if (channel.IsValid) { _BonEngineBind.BON_Sfx_SetChannelDistance(channel, distance); } }
/// <summary> /// Set sound channel distance, /// </summary> /// <param name="channel">Channel id.</param> /// <param name="volume">Channel volume.</param> public void SetChannelVolume(SoundChannelId channel, int volume) { if (channel.IsValid) { _BonEngineBind.BON_Sfx_SetChannelVolume(channel, volume); } }
/// <summary> /// Fade out a channel. /// </summary> /// <param name="channel">Channel id to fade out.</param> /// <param name="fadeOutTime">Fade out time, in seconds.</param> public void FadeOutChannel(SoundChannelId channel, float fadeOutTime) { if (channel.IsValid) { _BonEngineBind.BON_Sfx_FadeOutChannel(channel, fadeOutTime); } }