Esempio n. 1
0
        public void Play()
        {
            _waveOut.Stop();
            _audioBufferPlaybackPosition = 0;
            _waveOut.Play();

            PlaybackStarted?.Invoke();
        }
Esempio n. 2
0
 void SendPlaybackStarted(object sender, EventArgs e)
 {
     _isPlaying = true;
     State      = PlaybackState.Playing;
     StartPostionPollingTimer();
     PlaybackStarted?.Invoke(this, EventArgs.Empty);
     _controlsAlwaysVisible = false;
     ShowController();
 }
Esempio n. 3
0
        public void StartPlaying()
        {
            if (PlaybackState != PlaybackState.Stopped || _inStream == null)
            {
                return;
            }

            CreateWaveOut();
            _inStream.Position = 0;
            _waveOut.Play();
            PlaybackStarted.Invoke(this, EventArgs.Empty);
            _timer.Start();
        }
Esempio n. 4
0
 /// <summary>
 /// Play the current sequence.
 /// </summary>
 public void playCurrentSequence()
 {
     if (currentSequence != null && !playing)
     {
         currentTime = 0.0f;
         playing     = true;
         medicalController.OnLoopUpdate += medicalController_OnLoopUpdate;
         if (PlaybackStarted != null)
         {
             PlaybackStarted.Invoke(this);
         }
     }
 }
Esempio n. 5
0
 protected void InvokePlackbackStarted(MediaItem startedItem)
 {
     PlaybackStarted?.Invoke(this, new PlaybackStartEventArgs(startedItem));
 }
 private void OnPlaybackStarted()
 {
     PlaybackStarted?.Invoke(this, EventArgs.Empty);
 }