[MPlayer-dev-eng] Audio CD questions
Ingo Brückl
ib at wupperonline.de
Thu Dec 15 14:49:50 CET 2011
I'm currently adding audio CD playback support to the GUI (which works fine
so far except for #3 below) and have a few questions.
1. There seem to be several libraries possible to enable audio CD playback
(stream_cdda). I myself installed cdparanoia and get CONFIG_CDDA. In
configure I find CONFIG_LIBCDIO (and CONFIG_CDDB?) as well. So, is
#if defined(CDDA) || defined(LIBCDIO) what I should check?
2. STREAMTYPE_CDDA is the stream type to (always) go with, isn't it?
3. Although I get the correct numbers of total tracks with the
MSGTR_MPDEMUX_CDDA_AudioCDFoundWithNTracks message, stream_control()'s
STREAM_CTRL_GET_NUM_CHAPTERS returns nothing but 1, because start_track
and end_track in stream_cdda.c always seem to be 1 while the following
patch seems to work. Is it a bug or am I doing something wrong?
Index: stream/stream_cdda.c
===================================================================
--- stream/stream_cdda.c (revision 34441)
+++ stream/stream_cdda.c (working copy)
@@ -244,9 +244,7 @@
switch(cmd) {
case STREAM_CTRL_GET_NUM_CHAPTERS:
{
- int start_track = get_track_by_sector(p, p->start_sector);
- int end_track = get_track_by_sector(p, p->end_sector);
- *(unsigned int *)arg = end_track + 1 - start_track;
+ *(unsigned int *)arg = p->cd->tracks;
return STREAM_OK;
}
case STREAM_CTRL_SEEK_TO_CHAPTER:
Ingo
More information about the MPlayer-dev-eng
mailing list