.off = offsetof(mpegts_service_t, s_dvb_forcecaid),
.opts = PO_EXPERT | PO_HEXA,
},
+ {
+ .type = PT_INT,
+ .id = "pts_shift",
+ .name = N_("Shift PTS (ms)"),
+ .desc = N_("Add this value to PTS for the teletext subtitles. The time value is in milliseconds and may be negative."),
+ .off = offsetof(mpegts_service_t, s_pts_shift),
+ .opts = PO_EXPERT,
+ },
{
.type = PT_TIME,
.id = "created",
if(SCT_ISAUDIO(st->es_type) && pkt->pkt_pts != PTS_UNSET &&
(t->s_current_pts == PTS_UNSET ||
pkt->pkt_pts > t->s_current_pts ||
- pkt->pkt_pts < t->s_current_pts - 180000))
- t->s_current_pts = pkt->pkt_pts;
+ pkt->pkt_pts < t->s_current_pts - 180000)) {
+ t->s_current_pts = (pkt->pkt_pts + (int64_t)t->s_pts_shift * 900) % PTS_MASK;
+ }
pkt_trace(LS_PARSER, pkt, st->es_index, st->es_type, "deliver");