summaryrefslogtreecommitdiffstats
path: root/libmpdemux/demuxer.h
diff options
context:
space:
mode:
authorwm4 <wm4@mplayer2.org>2011-10-23 04:51:44 +0200
committerUoti Urpala <uau@mplayer2.org>2011-10-25 22:09:33 +0300
commite3f5043233336d8b4b0731c6a8b42a8fda5535ac (patch)
tree2a1c05f2b117da2276f57ddf8b0409504c536689 /libmpdemux/demuxer.h
parentc0b7851f23b561aa708a78f00961652603a18013 (diff)
downloadmpv-e3f5043233336d8b4b0731c6a8b42a8fda5535ac.tar.bz2
mpv-e3f5043233336d8b4b0731c6a8b42a8fda5535ac.tar.xz
core, demux: fix --identify chapter output with ordered chapters
Information about individual chapters was printed during demuxer opening phase, and total chapter count (ID_CHAPTERS) was printed according to mpctx->demuxer->num_chapters. When playing a file with ordered chapters, this meant that chapter information about every source file was printed individually (even though only the chapters from the first file would be used for playback) and the total chapter count could be wrong. Remove the printing of chapter information from the demuxer layer and print the chapter information and count actually used for playback in core print_file_properties(). Also somewhat simplify the internal chapters API and remove possible inconsistencies.
Diffstat (limited to 'libmpdemux/demuxer.h')
-rw-r--r--libmpdemux/demuxer.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/libmpdemux/demuxer.h b/libmpdemux/demuxer.h
index 6cdad7911a..55fda059fe 100644
--- a/libmpdemux/demuxer.h
+++ b/libmpdemux/demuxer.h
@@ -400,15 +400,13 @@ int demuxer_add_attachment(struct demuxer *demuxer, struct bstr name,
struct bstr type, struct bstr data);
int demuxer_add_chapter(struct demuxer *demuxer, struct bstr name,
uint64_t start, uint64_t end);
-int demuxer_seek_chapter(struct demuxer *demuxer, int chapter, double *seek_pts,
- char **chapter_name);
+int demuxer_seek_chapter(struct demuxer *demuxer, int chapter,
+ double *seek_pts);
/// Get current chapter index if available.
int demuxer_get_current_chapter(struct demuxer *demuxer, double time_now);
/// Get chapter name by index if available.
char *demuxer_chapter_name(struct demuxer *demuxer, int chapter);
-/// Get chapter display name by index.
-char *demuxer_chapter_display_name(struct demuxer *demuxer, int chapter);
/// Get chapter start time and end time by index if available.
float demuxer_chapter_time(struct demuxer *demuxer, int chapter, float *end);
/// Get total chapter number.