Exemplo n.º 1
0
        private void VideoStartLoaded(object sender, EventArgs e)
        {
            MediaPlayerStart.Pause();
            GotoSubtitlePosition(MediaPlayerStart);

            _startGoBackPosition = MediaPlayerStart.CurrentPosition;
            _startStopPosition   = _startGoBackPosition + 0.1;
            MediaPlayerStart.Play();

            if (MediaPlayerStart.VideoPlayer.GetType() == typeof(LibVlcDynamic))
            {
                MediaPlayerEnd.VideoPlayer = (MediaPlayerStart.VideoPlayer as LibVlcDynamic).MakeSecondMediaPlayer(MediaPlayerEnd.PanelPlayer, VideoFileName, VideoEndLoaded, VideoEndEnded);
            }
            else
            {
                Utilities.InitializeVideoPlayerAndContainer(MediaPlayerStart.VideoPlayer.VideoFileName, _videoInfo, MediaPlayerEnd, VideoEndLoaded, VideoEndEnded);
            }
            timer1.Start();
            timerProgressBarRefresh.Start();

            if (AudioTrackNumber > -1 && MediaPlayerStart.VideoPlayer is LibVlcDynamic)
            {
                var libVlc = (LibVlcDynamic)MediaPlayerStart.VideoPlayer;
                libVlc.AudioTrackNumber = AudioTrackNumber;
            }
        }
Exemplo n.º 2
0
 private void ButtonStartVerifyClick(object sender, EventArgs e)
 {
     if (MediaPlayerStart != null && MediaPlayerStart.VideoPlayer != null)
     {
         _startGoBackPosition = MediaPlayerStart.CurrentPosition;
         _startStopPosition   = _startGoBackPosition + Configuration.Settings.Tools.VerifyPlaySeconds;
         MediaPlayerStart.Play();
     }
 }