summaryrefslogtreecommitdiffstats
path: root/stream/stream_dvd.c
diff options
context:
space:
mode:
authornicodvb <nicodvb@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-08-21 19:13:36 +0000
committernicodvb <nicodvb@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-08-21 19:13:36 +0000
commit66e04345bef5476f3d35ebc43c471d659d037bdb (patch)
tree21359973a28ebafd8f0d23cf28eccea7a1d9e9c5 /stream/stream_dvd.c
parent28a6ef459131dd2c556050990aabe83b237bb496 (diff)
downloadmpv-66e04345bef5476f3d35ebc43c471d659d037bdb.tar.bz2
mpv-66e04345bef5476f3d35ebc43c471d659d037bdb.tar.xz
implemented STREAM_CTRL_GET_NUM_CHAPTERS
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@19482 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'stream/stream_dvd.c')
-rw-r--r--stream/stream_dvd.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/stream/stream_dvd.c b/stream/stream_dvd.c
index 224e9f7a23..e842357d46 100644
--- a/stream/stream_dvd.c
+++ b/stream/stream_dvd.c
@@ -514,6 +514,12 @@ static int control(stream_t *stream,int cmd,void* arg)
*((unsigned int *)arg) = mp_get_titleset_length(d->vts_file, d->tt_srpt, d->cur_title-1);
return 1;
}
+ case STREAM_CTRL_GET_NUM_CHAPTERS:
+ {
+ if(! d->cur_pgc->nr_of_programs) return STREAM_UNSUPORTED;
+ *((unsigned int *)arg) = d->cur_pgc->nr_of_programs;
+ return 1;
+ }
case STREAM_CTRL_SEEK_TO_CHAPTER:
{
int r = seek_to_chapter(stream, d->vts_file, d->tt_srpt, d->cur_title-1, *((unsigned int *)arg));