From 7d60f558d513911dbd2ecf7b248e8bfdaae1d62c Mon Sep 17 00:00:00 2001 From: Izaron Date: Mon, 12 Dec 2016 17:18:24 +0300 Subject: [PATCH] Fixed -unixts option --- src/lib_ccx/ccx_encoders_common.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/lib_ccx/ccx_encoders_common.c b/src/lib_ccx/ccx_encoders_common.c index 4c32e210..1c62861d 100644 --- a/src/lib_ccx/ccx_encoders_common.c +++ b/src/lib_ccx/ccx_encoders_common.c @@ -1077,6 +1077,13 @@ int encode_sub(struct encoder_ctx *context, struct cc_subtitle *sub) } data->end_time = data->end_time + context->subs_delay; + + if (utc_refvalue != UINT64_MAX) + { + data->start_time += utc_refvalue * 1000; + data->end_time += utc_refvalue * 1000; + } + switch (context->write_format) { case CCX_OF_SRT: