]> git.sesse.net Git - vlc/blobdiff - modules/access/cdda/cdda.h
2nd attempt to get libcdio cdda working.
[vlc] / modules / access / cdda / cdda.h
index 18c9f52a180f51c78132d80b4c231ad487aa0e38..3f43dd068da8bcfb38f14c22c7580121112d434d 100644 (file)
@@ -3,9 +3,9 @@
  *          using libcdio, libvcd and libvcdinfo
  *****************************************************************************
  * Copyright (C) 2003 VideoLAN
- * $Id: cdda.h,v 1.3 2003/11/30 22:26:49 rocky Exp $
+ * $Id$
  *
- * Authors: Rocky Bernstein <rocky@panix.com> 
+ * Author: Rocky Bernstein <rocky@panix.com>
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111, USA.
  *****************************************************************************/
 
-#include "../vcdx/cdrom.h"
+#include <cdio/cdio.h>
+#include "vlc_meta.h"
 
 #ifdef HAVE_LIBCDDB
 #include <cddb/cddb.h>
 #endif
 
 /*****************************************************************************
- * Debugging 
+ * Debugging
  *****************************************************************************/
 #define INPUT_DBG_META        1 /* Meta information */
 #define INPUT_DBG_EVENT       2 /* Trace keyboard events */
@@ -45,9 +46,9 @@
 #if INPUT_DEBUG
 #define dbg_print(mask, s, args...) \
    if (p_cdda->i_debug & mask) \
-     msg_Dbg(p_input, "%s: "s, __func__ , ##args)
+     msg_Dbg(p_access, "%s: "s, __func__ , ##args)
 #else
-#define dbg_print(mask, s, args...) 
+#define dbg_print(mask, s, args...)
 #endif
 
 /*****************************************************************************
  *****************************************************************************/
 typedef struct cdda_data_s
 {
-    cddev_t     *p_cddev;                           /* CD device descriptor */
-    int         i_nb_tracks;                        /* Nb of tracks (titles) */
-    int         i_track;                                    /* Current track */
-    lsn_t       i_sector;                                  /* Current Sector */
-    lsn_t *     p_sectors;                                  /* Track sectors */
-    vlc_bool_t  b_end_of_track;           /* If the end of track was reached */
+    CdIo       *p_cdio;                   /* libcdio CD device */
+    int         i_tracks;                 /* # of tracks (titles) */
+    int         i_first_track;            /* # of first track */
+
+    /* Current position */
+    int         i_track;                  /* Current track */
+    lsn_t       i_lsn;                    /* Current Logical Sector Number */
+    lsn_t *     p_lsns;                   /* Track LSNs */
+
     int         i_debug;                  /* Debugging mask */
-    char *      mcn;                      /* Media Catalog Number            */
-    intf_thread_t *p_intf;
+    char *      psz_mcn;                  /* Media Catalog Number            */
+    vlc_meta_t  *p_meta;
+
+    input_title_t *p_title[CDIO_CD_MAX_TRACKS]; 
+
 
 #ifdef HAVE_LIBCDDB
     int         i_cddb_enabled;
   struct  {
     bool             have_info;      /* True if we have any info */
     cddb_disc_t     *disc;           /* libcdio uses this to get disc info */
-    int              disc_length;    /* Length in frames of cd. Used in 
-                                       CDDB lookups */
+    int              disc_length;    /* Length in frames of cd. Used in
+                                        CDDB lookups */
   } cddb;
 #endif
 
+    WAVEHEADER  waveheader;               /* Wave header for the output data */
+    vlc_bool_t  b_header;
 
 } cdda_data_t;