예제 #1
0
        public IAudioPlayer CreatePlayer(Uri source)
        {
            var player = new UnityAudioPlayer(this)
            {
                Source = source
            };

            ConfigurePlayer(player);

            return(player);
        }
예제 #2
0
 internal void ConfigurePlayer(UnityAudioPlayer player)
 {
     Call(() =>
     {
         if (UseResources)
         {
             player.LoadResource();
         }
         else
         {
             StartCoroutine(player.LoadCoroutine());
         }
     });
 }
예제 #3
0
 void RemovePlayingPlayer(UnityAudioPlayer player)
 {
     lock (m_playingPlayers) {
         m_playingPlayers.Remove(player);
     }
 }
예제 #4
0
 void AddPlayingPlayer(UnityAudioPlayer player)
 {
     lock (m_playingPlayers) {
         m_playingPlayers.Add(player);
     }
 }