first commit

This commit is contained in:
Andrey Semochkin
2019-11-30 21:53:21 +01:00
commit 087a2b4c2d
60 changed files with 19091 additions and 0 deletions

26
format/ts/handler.go Normal file
View File

@@ -0,0 +1,26 @@
package ts
import (
"io"
"github.com/deepch/vdk/av"
"github.com/deepch/vdk/av/avutil"
)
func Handler(h *avutil.RegisterHandler) {
h.Ext = ".ts"
h.Probe = func(b []byte) bool {
return b[0] == 0x47 && b[188] == 0x47
}
h.ReaderDemuxer = func(r io.Reader) av.Demuxer {
return NewDemuxer(r)
}
h.WriterMuxer = func(w io.Writer) av.Muxer {
return NewMuxer(w)
}
h.CodecTypes = CodecTypes
}