mirror of
https://github.com/bluenviron/mediamtx.git
synced 2026-01-25 12:59:15 -08:00
build(deps): bump github.com/bluenviron/gortsplib/v4 (#4850)
Some checks are pending
code_lint / golangci_lint (push) Waiting to run
code_lint / mod_tidy (push) Waiting to run
code_lint / api_docs (push) Waiting to run
code_test / test_64 (push) Waiting to run
code_test / test_32 (push) Waiting to run
code_test / test_e2e (push) Waiting to run
Some checks are pending
code_lint / golangci_lint (push) Waiting to run
code_lint / mod_tidy (push) Waiting to run
code_lint / api_docs (push) Waiting to run
code_test / test_64 (push) Waiting to run
code_test / test_32 (push) Waiting to run
code_test / test_e2e (push) Waiting to run
Bumps [github.com/bluenviron/gortsplib/v4](https://github.com/bluenviron/gortsplib) from 4.16.0 to 4.16.1. - [Commits](https://github.com/bluenviron/gortsplib/compare/v4.16.0...v4.16.1) --- updated-dependencies: - dependency-name: github.com/bluenviron/gortsplib/v4 dependency-version: 4.16.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This commit is contained in:
parent
19a47acca1
commit
9e073cd34f
3 changed files with 20 additions and 25 deletions
|
|
@ -5,7 +5,6 @@ import (
|
|||
"time"
|
||||
|
||||
"github.com/bluenviron/gortsplib/v4/pkg/rtcpreceiver"
|
||||
"github.com/bluenviron/gortsplib/v4/pkg/rtpreorderer"
|
||||
"github.com/pion/rtcp"
|
||||
"github.com/pion/rtp"
|
||||
"github.com/pion/webrtc/v4"
|
||||
|
|
@ -287,8 +286,9 @@ func (t *IncomingTrack) start() {
|
|||
t.packetsLost.Start()
|
||||
|
||||
t.rtcpReceiver = &rtcpreceiver.RTCPReceiver{
|
||||
ClockRate: int(t.track.SSRC()),
|
||||
Period: 1 * time.Second,
|
||||
ClockRate: int(t.track.SSRC()),
|
||||
UnrealiableTransport: true,
|
||||
Period: 1 * time.Second,
|
||||
WritePacketRTCP: func(p rtcp.Packet) {
|
||||
t.writeRTCP([]rtcp.Packet{p}) //nolint:errcheck
|
||||
},
|
||||
|
|
@ -342,29 +342,24 @@ func (t *IncomingTrack) start() {
|
|||
|
||||
// read incoming RTP packets.
|
||||
go func() {
|
||||
reorderer := &rtpreorderer.Reorderer{}
|
||||
reorderer.Initialize()
|
||||
|
||||
for {
|
||||
pkt, _, err2 := t.track.ReadRTP()
|
||||
if err2 != nil {
|
||||
return
|
||||
}
|
||||
|
||||
packets, lost := reorderer.Process(pkt)
|
||||
if lost != 0 {
|
||||
atomic.AddUint64(t.rtpPacketsLost, uint64(lost))
|
||||
t.packetsLost.Add(uint64(lost))
|
||||
// do not return
|
||||
}
|
||||
|
||||
atomic.AddUint64(t.rtpPacketsReceived, uint64(len(packets)))
|
||||
|
||||
err2 = t.rtcpReceiver.ProcessPacket(pkt, time.Now(), true)
|
||||
packets, lost, err2 := t.rtcpReceiver.ProcessPacket2(pkt, time.Now(), true)
|
||||
if err2 != nil {
|
||||
t.log.Log(logger.Warn, err2.Error())
|
||||
continue
|
||||
}
|
||||
if lost != 0 {
|
||||
atomic.AddUint64(t.rtpPacketsLost, lost)
|
||||
t.packetsLost.Add(lost)
|
||||
// do not return
|
||||
}
|
||||
|
||||
atomic.AddUint64(t.rtpPacketsReceived, uint64(len(packets)))
|
||||
|
||||
var ntp time.Time
|
||||
if t.useAbsoluteTimestamp {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue