Skip to content

Restore video RTP timestamps for RTSP streams#19

Open
joeblack2k wants to merge 1 commit intothemactep:stablefrom
joeblack2k:codex/rtsp-video-timestamps-stable
Open

Restore video RTP timestamps for RTSP streams#19
joeblack2k wants to merge 1 commit intothemactep:stablefrom
joeblack2k:codex/rtsp-video-timestamps-stable

Conversation

@joeblack2k
Copy link
Copy Markdown

Summary

  • restore H264NALUnit timestamp fields with defensive zero-init
  • propagate encoder timestamps onto outgoing video NAL units in VideoWorker
  • use propagated video timestamps in IMPDeviceSource with fallback to gettimeofday() only when no encoder timestamp is available

Why

Direct RTSP from a Thingino camera on eufy_t8400x_t31x_sc3338_syn4343 was producing repeated timestamp errors in ffmpeg/Frigate:

  • DTS discontinuity
  • Application provided invalid, non monotonically increasing dts

A live binary-only deployment of this patch removed those warnings completely in direct source tests:

  • before: 12 warnings in an 8-second direct RTSP probe
  • after: 0 warnings in the same 8-second probe
  • after: 0 warnings in a longer 20-second probe

Notes

  • audio timestamp behavior is unchanged
  • video still falls back to gettimeofday() if no propagated timestamp is present, so the change is low risk for streams that do not populate encoder timestamps

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant