revid: added more to setupPipeline comment regarding parameters:

This commit is contained in:
Saxon 2019-04-10 14:05:53 +09:30
parent bab1e62798
commit 02287bfd80
1 changed files with 5 additions and 1 deletions

View File

@ -182,7 +182,11 @@ func (r *Revid) setConfig(config Config) error {
} }
// setupPipeline constructs the revid dataPipeline. Inputs, encoders and // setupPipeline constructs the revid dataPipeline. Inputs, encoders and
// senders are create and linked based on the current revid config. // senders are created and linked based on the current revid config.
//
// mtsEnc and flvEnc will be called to obtain an mts encoder and flv encoder
// respectively. multiWriter will be used to create an ioext.multiWriteCloser
// so that encoders can write to multiple senders.
func (r *Revid) setupPipeline(mtsEnc, flvEnc func(dst io.Writer, rate int) (io.Writer, error), multiWriter func(...io.WriteCloser) io.WriteCloser) error { func (r *Revid) setupPipeline(mtsEnc, flvEnc func(dst io.Writer, rate int) (io.Writer, error), multiWriter func(...io.WriteCloser) io.WriteCloser) error {
r.buffer = (*buffer)(ring.NewBuffer(ringBufferSize, ringBufferElementSize, writeTimeout)) r.buffer = (*buffer)(ring.NewBuffer(ringBufferSize, ringBufferElementSize, writeTimeout))