h265 video mp4 support

This commit is contained in:
Andrey Semochkin
2021-02-09 04:27:04 +03:00
parent ae4ae47c04
commit 01cae17ec2
7 changed files with 320 additions and 250 deletions

View File

@@ -195,6 +195,9 @@ func (element *Muxer) WritePacket(pkt av.Packet) (err error) {
}
if tmp, ok := element.streams[pkt.Idx]; ok {
element.StreamACK.Reset(10 * time.Second)
if len(pkt.Data) < 5 {
return nil
}
switch tmp.codec.Type() {
case av.H264:
codec := tmp.codec.(h264parser.CodecData)