public void Seek(DateTime seekTo) { lock (PlayerLock) { if (_transformSource == null) { throw new ArgumentException("Unable to seek before starting player"); } if (_isLive) { _isLive = false; _pipeline.SetFlushing(true); _pipeline.Stop(); _pipeline = _config.PipelineFactory.CreatePipeline(_transformSource, _isLive); _pipeline.Start(); } _source.Seek(seekTo); } }
public void JumpToLive() { lock (PlayerLock) { if (!_isLive) { _isLive = true; _pipeline.SetFlushing(true); _pipeline.Stop(); _pipeline = _config.PipelineFactory.CreatePipeline(_transformSource, _isLive); _pipeline.SetFlushing(false); _pipeline.Start(); _source.JumpToLive(); } } }