fix: use engine's aac format

This commit is contained in:
langhuihui
2024-09-27 10:05:32 +08:00
parent c943c2a0ec
commit 4dc893e9fb
2 changed files with 9 additions and 4 deletions

View File

@@ -72,6 +72,7 @@ func (p *RTSPPublisher) SetTracks() error {
conf = f.StreamMuxConfig.Programs[0].Layers[0].AudioSpecificConfig
}
at := p.CreateAudioTrack(codec.CodecID_AAC, byte(f.PayloadType()), uint32(conf.SampleRate)).(*AAC)
at.AACFormat = f
at.AACDecoder.LATM = f.LATM
at.AACDecoder.IndexDeltaLength = f.IndexDeltaLength
at.AACDecoder.IndexLength = f.IndexLength