Exemplo n.º 1
0
        /// <summary>Initializes a new instance of the <see cref="AudioEncoder" /> class.</summary>
        /// <param name="options">Audio encoder options.</param>
        /// <param name="pipeOptions">Options for input/output pipes. Defaults to <see cref="PipeOptions.Default" />.</param>
        /// <exception cref="ArgumentNullException"><paramref name="options" /> is <c>null</c>.</exception>
        public AudioEncoder(AudioEncoderOptions options, PipeOptions?pipeOptions = null)
        {
            ThrowIfNull(options, nameof(options));

            _inputPipe  = new Pipe(pipeOptions ?? PipeOptions.Default);
            _outputPipe = new Pipe(pipeOptions ?? PipeOptions.Default);
        }
Exemplo n.º 2
0
 /// <summary>Initializes a new instance of the <see cref="AudioEncoder" /> class.</summary>
 /// <param name="options">Audio encoder options.</param>
 /// <param name="pipeOptions">Options for input/output pipes. Defaults to <see cref="PipeOptions.Default" />.</param>
 public AudioEncoder(AudioEncoderOptions options, PipeOptions?pipeOptions = null)
 {
     _inputPipe  = new Pipe(pipeOptions ?? PipeOptions.Default);
     _outputPipe = new Pipe(pipeOptions ?? PipeOptions.Default);
 }