r34477 - trunk/gui/interface.c
Author: ib Date: Sat Dec 31 13:55:28 2011 New Revision: 34477 Log: Retrieve DVD's titles, chapters and angles by stream control commands. Don't access the private vmg_file member structure. Modified: trunk/gui/interface.c Modified: trunk/gui/interface.c ============================================================================== --- trunk/gui/interface.c Sat Dec 31 13:45:46 2011 (r34476) +++ trunk/gui/interface.c Sat Dec 31 13:55:28 2011 (r34477) @@ -638,10 +638,13 @@ int gui(int what, void *data) #ifdef CONFIG_DVDREAD case STREAMTYPE_DVD: + guiInfo.Tracks = 0; + stream_control(stream, STREAM_CTRL_GET_NUM_TITLES, &guiInfo.Tracks); + guiInfo.Chapters = 0; + stream_control(stream, STREAM_CTRL_GET_NUM_CHAPTERS, &guiInfo.Chapters); + guiInfo.Angles = 0; + stream_control(stream, STREAM_CTRL_GET_NUM_ANGLES, &guiInfo.Angles); dvd = stream->priv; - guiInfo.Tracks = dvd->vmg_file->tt_srpt->nr_of_srpts; - guiInfo.Chapters = dvd->vmg_file->tt_srpt->title[dvd_title].nr_of_ptts; - guiInfo.Angles = dvd->vmg_file->tt_srpt->title[dvd_title].nr_of_angles; guiInfo.AudioStreams = dvd->nr_of_channels; memcpy(guiInfo.AudioStream, dvd->audio_streams, sizeof(dvd->audio_streams)); guiInfo.Subtitles = dvd->nr_of_subtitles;
participants (1)
-
ib