diff --git a/revid/revid.go b/revid/revid.go index bcb120dd..d3cf36bb 100644 --- a/revid/revid.go +++ b/revid/revid.go @@ -346,6 +346,12 @@ func (r *Revid) setupPipeline(mtsEnc func(dst io.WriteCloser, rate float64) (io. case config.InputFile: r.input = file.New() + switch r.cfg.InputCodec { + case codecutil.H264: + r.lexTo = h264.Lex + case codecutil.MJPEG: + r.lexTo = mjpeg.Lex + } case config.InputRTSP: r.input = geovision.New(r.cfg.Logger)