From 85450d06a1b1a08fce277f7f14d5ee33b12f8eab Mon Sep 17 00:00:00 2001 From: wm4 Date: Mon, 16 Nov 2015 23:15:59 +0100 Subject: player: use demuxer ts offset to simplify timeline ts handling Use the demux_set_ts_offset() added in the previous commit to base each timeline segment to use timestamps according to its relative position within the overall timeline. As a consequence we don't need to care about these timestamps anymore, and everything becomes simpler. (Another minor but delicious nugget of sanity.) --- sub/osd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sub/osd.c') diff --git a/sub/osd.c b/sub/osd.c index b4de8fee92..3090c2e5e7 100644 --- a/sub/osd.c +++ b/sub/osd.c @@ -247,7 +247,7 @@ static void render_object(struct osd_state *osd, struct osd_object *obj, if (sub->render_bitmap_subs && sub->dec_sub) { double sub_pts = video_pts; if (sub_pts != MP_NOPTS_VALUE) - sub_pts -= sub->video_offset + opts->sub_delay; + sub_pts -= opts->sub_delay; sub_get_bitmaps(sub->dec_sub, obj->vo_res, sub_pts, out_imgs); } else { osd_object_get_bitmaps(osd, obj, out_imgs); -- cgit v1.2.3