mts: Changed uses of NewEncoder in revid and senders_test to use extra argument.

This commit is contained in:
Trek H 2019-04-09 13:53:14 +09:30
parent d15d0ddb86
commit b09a6e210e
2 changed files with 3 additions and 3 deletions

View File

@ -258,7 +258,7 @@ func (r *Revid) setupPipeline(mtsEnc func(io.Writer, int) io.Writer, flvEnc func
}
func newMtsEncoder(dst io.Writer, fps int) io.Writer {
e := mts.NewEncoder(dst, float64(fps))
e := mts.NewEncoder(dst, float64(fps), mts.Video)
return e
}

View File

@ -111,7 +111,7 @@ func TestMtsSenderSegment(t *testing.T) {
tstSender := &sender{}
loadSender := newMtsSender(tstSender, log)
rb := ring.NewBuffer(rbSize, rbElementSize, wTimeout)
encoder := mts.NewEncoder((*buffer)(rb), 25)
encoder := mts.NewEncoder((*buffer)(rb), 25, mts.Video)
// Turn time based PSI writing off for encoder.
const psiSendCount = 10
@ -201,7 +201,7 @@ func TestMtsSenderDiscontinuity(t *testing.T) {
tstSender := &sender{testDiscontinuities: true, discontinuityAt: clipWithDiscontinuity}
loadSender := newMtsSender(tstSender, log)
rb := ring.NewBuffer(rbSize, rbElementSize, wTimeout)
encoder := mts.NewEncoder((*buffer)(rb), 25)
encoder := mts.NewEncoder((*buffer)(rb), 25, mts.Video)
// Turn time based PSI writing off for encoder.
const psiSendCount = 10