fix h264 mp4 bug
This commit is contained in:
parent
030575e585
commit
61aa8e4f72
@ -6,6 +6,8 @@ import (
|
|||||||
"io"
|
"io"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
|
"github.com/deepch/vdk/codec/h265parser"
|
||||||
|
|
||||||
"github.com/deepch/vdk/av"
|
"github.com/deepch/vdk/av"
|
||||||
"github.com/deepch/vdk/codec/aacparser"
|
"github.com/deepch/vdk/codec/aacparser"
|
||||||
"github.com/deepch/vdk/codec/h264parser"
|
"github.com/deepch/vdk/codec/h264parser"
|
||||||
@ -120,7 +122,7 @@ func (self *Stream) fillTrackAtom() (err error) {
|
|||||||
self.trackAtom.Header.TrackWidth = float64(width)
|
self.trackAtom.Header.TrackWidth = float64(width)
|
||||||
self.trackAtom.Header.TrackHeight = float64(height)
|
self.trackAtom.Header.TrackHeight = float64(height)
|
||||||
} else if self.Type() == av.H265 {
|
} else if self.Type() == av.H265 {
|
||||||
codec := self.CodecData.(h264parser.CodecData)
|
codec := self.CodecData.(h265parser.CodecData)
|
||||||
width, height := codec.Width(), codec.Height()
|
width, height := codec.Width(), codec.Height()
|
||||||
self.sample.SampleDesc.HV1Desc = &mp4io.HV1Desc{
|
self.sample.SampleDesc.HV1Desc = &mp4io.HV1Desc{
|
||||||
DataRefIdx: 1,
|
DataRefIdx: 1,
|
||||||
|
Loading…
Reference in New Issue
Block a user