From 9e82b5233d081c4548bee849a0d6417227aeb781 Mon Sep 17 00:00:00 2001 From: Alessandro Ros Date: Fri, 19 Dec 2025 13:32:14 +0100 Subject: [PATCH] fix 1-minute offset when recording a H264 WebRTC track (#5275) (#5278) --- internal/protocols/webrtc/from_stream.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/protocols/webrtc/from_stream.go b/internal/protocols/webrtc/from_stream.go index dbd125ad..33113bc4 100644 --- a/internal/protocols/webrtc/from_stream.go +++ b/internal/protocols/webrtc/from_stream.go @@ -313,7 +313,7 @@ func setupVideoTrack( for _, pkt := range packets { ntp := u.NTP.Add(timestampToDuration(int64(pkt.Timestamp), 90000)) pkt.Timestamp += u.RTPPackets[0].Timestamp - track.WriteRTPWithNTP(pkt, ntp.Add(-1*time.Minute)) //nolint:errcheck + track.WriteRTPWithNTP(pkt, ntp) //nolint:errcheck } return nil