From 58497380e5222749892414089d26916095c0485c Mon Sep 17 00:00:00 2001 From: Uoti Urpala Date: Sun, 29 Mar 2009 22:45:06 +0300 Subject: Initial ordered chapters support Add basic support for Matroska ordered chapters. The switching between segments is implemented as a general edit timeline that could also be used for other purposes. Some things still need improvement. In particular the current code does not try to do any proper mapping between audio/video/subtitle streams of different files and there should be options for better control of how MPlayer searches other files for the required content. --- mencoder.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'mencoder.c') diff --git a/mencoder.c b/mencoder.c index 1661722679..6fb7f03600 100644 --- a/mencoder.c +++ b/mencoder.c @@ -1469,7 +1469,7 @@ if(sh_audio && !demuxer2){ } else #endif - update_subtitles(sh_video, d_dvdsub, 0); + update_subtitles(sh_video, d_dvdsub, 0, 0); frame_data = (s_frame_data){ .start = NULL, .in_size = 0, .frame_time = 0., .already_read = 0 }; -- cgit v1.2.3 From f12c83b85b135c1cb9fb34e978eb0c8051450da8 Mon Sep 17 00:00:00 2001 From: Uoti Urpala Date: Wed, 1 Apr 2009 19:55:26 +0300 Subject: Change demuxer_seek_chapter() parameters Remove the "num_chapters" and "mode" parameters that aren't needed by any callers. Change "float *seek_pts" to "double *". Allocate the string returned via "chapter_name" with talloc. --- mencoder.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'mencoder.c') diff --git a/mencoder.c b/mencoder.c index 6fb7f03600..6915a6efa3 100644 --- a/mencoder.c +++ b/mencoder.c @@ -575,8 +575,8 @@ if(stream->type==STREAMTYPE_DVDNAV){ } if(dvd_chapter>1) { - float pts; - if (demuxer_seek_chapter(demuxer, dvd_chapter-1, 1, &pts, NULL, NULL) >= 0 && pts > -1.0) + double pts; + if (demuxer_seek_chapter(demuxer, dvd_chapter-1, &pts, NULL) >= 0 && pts > -1.0) seek_to_sec = pts; } -- cgit v1.2.3