예제 #1
0
        static void Main(string[] args)
        {
            // load our sounds
            SoundBank.Init();

            // load and play our song
            OggMMLPlayer player = new OggMMLPlayer();

            player.FromFile("stones.mml");
            player.Play();

            while (player.Playing)
            {
                // update the audio device
                AudioManager.Instance.SourceManager.Update();

                // update our song
                player.Update();

                // be nice to the CPU
                System.Threading.Thread.Sleep(1);
            }

            // clean up
            AudioManager.Instance.Dispose();
        }
예제 #2
0
        static void Main(string[] args)
        {
            // load our sounds
            SoundBank.Init();

            // load and play our song
            OggMMLPlayer player = new OggMMLPlayer();
            player.FromFile("stones.mml");
            player.Play();

            while (player.Playing) {
                // update the audio device
                AudioManager.Instance.SourceManager.Update();

                // update our song
                player.Update();

                // be nice to the CPU
                System.Threading.Thread.Sleep(1);
            }

            // clean up
            AudioManager.Instance.Dispose();
        }