mirror of
https://github.com/bluenviron/mediamtx.git
synced 2025-12-25 20:41:59 -08:00
hls client: skip packets received before the 1st packet of the leading
track, for MPEG-TS segments too
This commit is contained in:
parent
7981522bf6
commit
0daf8a17b7
1 changed files with 5 additions and 3 deletions
|
|
@ -58,9 +58,11 @@ func (t *clientProcessorFMP4Track) processPartTrack(ctx context.Context, pt *fmp
|
|||
return err
|
||||
}
|
||||
|
||||
err = t.onEntry(pts, sample.Payload)
|
||||
if err != nil {
|
||||
return err
|
||||
if pts >= 0 { // silently discard packets prior to the first packet of the leading track
|
||||
err = t.onEntry(pts, sample.Payload)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
rawDTS += uint64(sample.Duration)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue