Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prefer Using Source Time if Provided #2185

Merged
merged 2 commits into from
Nov 24, 2021

Conversation

maxsharabayko
Copy link
Collaborator

The source time for a message can be provided using the SRT_MSGCTRL structure:

typedef struct SRT_MsgCtrl_
{
   //
   int64_t srctime;             // Source time, in microseconds since SRT internal clock epoch
   //
} SRT_MSGCTRL;

Currently, inside SRT a message gets two timestamps:

  1. Submission timestamp (tsOriginTime), which is used for:
    • SND Too-Late Packet Drop;
    • TTL Message Drop (not to be confused with IP_TTL);
    • SND buffer timespan (stats).
  2. Source timestamp if provided (tsSourceTime)
    • Data Packet Timestamp

This PR keeps only one timestamp for everything (source time if provided, otherwise submission time).

Note: Extracted from #2180.

@maxsharabayko maxsharabayko added [core] Area: Changes in SRT library core Type: Maintenance Work required to maintain or clean up the code labels Nov 12, 2021
@maxsharabayko maxsharabayko added this to the v1.4.5 milestone Nov 12, 2021
@maxsharabayko maxsharabayko merged commit b99e41c into Haivision:master Nov 24, 2021
@maxsharabayko maxsharabayko deleted the develop/one-source-time branch November 24, 2021 08:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[core] Area: Changes in SRT library core Type: Maintenance Work required to maintain or clean up the code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant