Commit f5aed5af authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Remove CDDAX module

No maintainer, buggy code and no major feature in.
Sorry guys
parent 2146ab41
...@@ -102,6 +102,7 @@ Removed modules: ...@@ -102,6 +102,7 @@ Removed modules:
* WinCE interface * WinCE interface
* opie, qte and qte_main * opie, qte and qte_main
* opengllayer * opengllayer
* cddax. Use cdda instead
Changes between 1.0.2 and 1.0.3: Changes between 1.0.2 and 1.0.3:
......
...@@ -189,7 +189,7 @@ case "${host_os}" in ...@@ -189,7 +189,7 @@ case "${host_os}" in
bsdi*) bsdi*)
SYS=bsdi SYS=bsdi
CFLAGS_save="${CFLAGS_save} -pthread"; CFLAGS="${CFLAGS_save}" CFLAGS_save="${CFLAGS_save} -pthread"; CFLAGS="${CFLAGS_save}"
VLC_ADD_LIBS([dvd dvdcss vcd cdda vcdx cddax],[-ldvd]) VLC_ADD_LIBS([dvd dvdcss vcd cdda vcdx],[-ldvd])
;; ;;
*bsd*) *bsd*)
SYS="${host_os}" SYS="${host_os}"
...@@ -246,8 +246,6 @@ case "${host_os}" in ...@@ -246,8 +246,6 @@ case "${host_os}" in
echo " Assuming --enable-theora" echo " Assuming --enable-theora"
enable_shout="yes" enable_shout="yes"
echo " Assuming --enable-shout" echo " Assuming --enable-shout"
enable_cddax="yes"
echo " Assuming --enable-cddax"
enable_vcdx="yes" enable_vcdx="yes"
echo " Assuming --enable-vcdx" echo " Assuming --enable-vcdx"
enable_caca="yes" enable_caca="yes"
...@@ -348,7 +346,7 @@ case "${host_os}" in ...@@ -348,7 +346,7 @@ case "${host_os}" in
VLC_ADD_LIBS([libvlccore],[-lws2_32 -lnetapi32 -lwinmm]) VLC_ADD_LIBS([libvlccore],[-lws2_32 -lnetapi32 -lwinmm])
VLC_ADD_LDFLAGS([vlc],[-mwindows]) VLC_ADD_LDFLAGS([vlc],[-mwindows])
VLC_ADD_LIBS([activex mozilla],[-lgdi32]) VLC_ADD_LIBS([activex mozilla],[-lgdi32])
VLC_ADD_LIBS([cdda vcdx cddax sdl_image aout_sdl vout_sdl],[-lwinmm]) VLC_ADD_LIBS([cdda vcdx sdl_image aout_sdl vout_sdl],[-lwinmm])
VLC_ADD_LIBS([access_http access_mms access_udp access_tcp access_ftp access_rtmp access_output_udp access_output_shout access_output_rtmp sap slp oldhttp stream_out_standard stream_out_rtp stream_out_raop vod_rtsp access_realrtsp rtp oldtelnet oldrc netsync gnutls growl_udp flac ts audioscrobbler lua remoteosd zvbi audiobargraph_a],[-lws2_32]) VLC_ADD_LIBS([access_http access_mms access_udp access_tcp access_ftp access_rtmp access_output_udp access_output_shout access_output_rtmp sap slp oldhttp stream_out_standard stream_out_rtp stream_out_raop vod_rtsp access_realrtsp rtp oldtelnet oldrc netsync gnutls growl_udp flac ts audioscrobbler lua remoteosd zvbi audiobargraph_a],[-lws2_32])
VLC_ADD_LIBS([access_file], [-lshlwapi]) VLC_ADD_LIBS([access_file], [-lshlwapi])
dnl dnl
...@@ -604,7 +602,7 @@ fi ...@@ -604,7 +602,7 @@ fi
SOCKET_LIBS="" SOCKET_LIBS=""
AC_CHECK_FUNCS(connect,,[ AC_CHECK_FUNCS(connect,,[
AC_CHECK_LIB(socket,connect,[ AC_CHECK_LIB(socket,connect,[
VLC_ADD_LIBS([libvlccore cdda cddax],-lsocket) VLC_ADD_LIBS([libvlccore cdda],-lsocket)
SOCKET_LIBS="-lsocket" SOCKET_LIBS="-lsocket"
]) ])
]) ])
...@@ -2489,44 +2487,8 @@ then ...@@ -2489,44 +2487,8 @@ then
fi fi
dnl dnl
dnl VCDX and CDDAX modules dnl VCDX modules
dnl dnl
AC_ARG_ENABLE(cddax,
AS_HELP_STRING([--enable-cddax],[audio CD plugin with CD Text and CD paranoia
via libcdio (default disabled)]))
AC_ARG_ENABLE(libcddb,
[ --enable-libcddb CDDB support for libcdio audio CD (default enabled)])
if test "${enable_cddax}" = "yes"
then
if test "$have_libcdio" = "yes"
then
AC_DEFINE(HAVE_CDDAX, 1, [Define for the audio CD plugin using libcdio])
VLC_ADD_LIBS([cddax],[$LIBCDIO_LIBS])
VLC_ADD_CFLAGS([cddax],[$LIBCDIO_CFLAGS])
VLC_ADD_PLUGIN([cddax])
PKG_CHECK_MODULES(LIBCDIO_PARANOIA, libcdio_paranoia >= 0.72, [
VLC_ADD_LIBS([cddax],[$LIBCDIO_CDDA_LIBS $LIBCDIO_CDDA_LIBS $LIBCDIO_PARANOIA_LIBS])],
AC_MSG_WARN([CD Paranoia support disabled because no libcdio >= 0.72 found]))
else
AC_MSG_WARN([cddax plugin disabled because ok libcdio library not found or disabled])
HAVE_CDDAX=no
fi
if test "$enable_libcddb" != "no"; then
PKG_CHECK_MODULES(LIBCDDB, libcddb >= 0.9.5, [
HAVE_LIBCDDB=yes
AC_DEFINE(HAVE_LIBCDDB, 1, [Define this if you have libcddb installed])
VLC_ADD_LIBS([cddax],[$LIBCDDB_LIBS])
VLC_ADD_CFLAGS([cddax],[$LIBCDDB_CFLAGS])
],
[AC_MSG_WARN(new enough libcddb not found. CDDB access disabled)
HAVE_LIBCDDB=no])
fi
fi
AC_ARG_ENABLE(vcdx, AC_ARG_ENABLE(vcdx,
[ --enable-vcdx VCD with navigation via libvcdinfo (default disabled)]) [ --enable-vcdx VCD with navigation via libvcdinfo (default disabled)])
...@@ -2610,8 +2572,8 @@ then ...@@ -2610,8 +2572,8 @@ then
then then
VLC_ADD_PLUGIN([vcd]) VLC_ADD_PLUGIN([vcd])
VLC_ADD_PLUGIN([cdda]) VLC_ADD_PLUGIN([cdda])
VLC_ADD_LDFLAGS([vcd vcdx cdda cddax],[-Wl,-framework,IOKit,-framework,CoreFoundation]) VLC_ADD_LDFLAGS([vcd vcdx cdda],[-Wl,-framework,IOKit,-framework,CoreFoundation])
VLC_ADD_LIBS([vcdx cddax cdda],[-liconv]) VLC_ADD_LIBS([vcdx cdda],[-liconv])
fi fi
if test "$enable_libcddb" != "no"; then if test "$enable_libcddb" != "no"; then
...@@ -5167,7 +5129,6 @@ AC_CONFIG_FILES([ ...@@ -5167,7 +5129,6 @@ AC_CONFIG_FILES([
modules/access/dshow/Makefile modules/access/dshow/Makefile
modules/access/dvb/Makefile modules/access/dvb/Makefile
modules/access/mms/Makefile modules/access/mms/Makefile
modules/access/cdda/Makefile
modules/access/rtp/Makefile modules/access/rtp/Makefile
modules/access/rtsp/Makefile modules/access/rtsp/Makefile
modules/access/vcd/Makefile modules/access/vcd/Makefile
......
...@@ -69,7 +69,6 @@ $Id$ ...@@ -69,7 +69,6 @@ $Id$
* canvas: Automatically resize and padd a video * canvas: Automatically resize and padd a video
* cc: CC 608/708 subtitles decoder * cc: CC 608/708 subtitles decoder
* cdda: input module to read audio CDs * cdda: input module to read audio CDs
* cddax: input module to read audio CDs via libcdio
* cdg: CD-G decoder * cdg: CD-G decoder
* chain: Video filtering using a chain of video filter modules * chain: Video filtering using a chain of video filter modules
* chorus_flanger: variable delay audio filter * chorus_flanger: variable delay audio filter
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
# obviously does not. Here is a fix for that. # obviously does not. Here is a fix for that.
LIBTOOL=@LIBTOOL@ --tag=CC LIBTOOL=@LIBTOOL@ --tag=CC
BASE_SUBDIRS = dvb mms cdda rtp rtsp vcd vcdx screen bd zip BASE_SUBDIRS = dvb mms rtp rtsp vcd vcdx screen bd zip
EXTRA_SUBDIRS = bda dshow EXTRA_SUBDIRS = bda dshow
SUBDIRS = $(BASE_SUBDIRS) SUBDIRS = $(BASE_SUBDIRS)
DIST_SUBDIRS = $(BASE_SUBDIRS) $(EXTRA_SUBDIRS) DIST_SUBDIRS = $(BASE_SUBDIRS) $(EXTRA_SUBDIRS)
......
SOURCES_cddax = \
access.c \
access.h \
callback.c \
callback.h \
cdda.c \
cdda.h \
info.c \
info.h \
$(NULL)
This diff is collapsed.
/*****************************************************************************
* access.h : access headers for CD digital audio input module
*****************************************************************************
* Copyright (C) 2004 the VideoLAN team
* $Id$
*
* Authors: 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
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
/*****************************************************************************
* Open: open cdda device or image file and initialize structures
* for subsequent operations.
*****************************************************************************/
int CDDAOpen ( vlc_object_t * );
/*****************************************************************************
* CDDAClose: closes cdda and frees any resources associded with it.
*****************************************************************************/
void CDDAClose ( vlc_object_t * );
/*****************************************************************************
* callback.c : Callbacks for CD digital audio input module
*****************************************************************************
* Copyright (C) 2004 the VideoLAN team
* $Id$
*
* Authors: 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
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
#include "callback.h"
#include "cdda.h"
int
CDDADebugCB ( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val, void *p_data )
{
VLC_UNUSED(p_this);
VLC_UNUSED(psz_name);
VLC_UNUSED(oldval);
VLC_UNUSED(p_data);
cdda_data_t *p_cdda;
if (NULL == p_cdda_input) return VLC_EGENERIC;
p_cdda = (cdda_data_t *)p_cdda_input->p_sys;
if (p_cdda->i_debug & (INPUT_DBG_CALL|INPUT_DBG_EXT))
{
msg_Dbg( p_cdda_input, "old debug (x%0x) %d, new debug (x%0x) %d",
p_cdda->i_debug, p_cdda->i_debug, val.i_int, val.i_int);
}
p_cdda->i_debug = val.i_int;
return VLC_SUCCESS;
}
/* FIXME: could probably shorten some of the below boilerplate code...
*/
int
CDDBEnabledCB ( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val, void *p_data )
{
VLC_UNUSED(p_this);
VLC_UNUSED(psz_name);
VLC_UNUSED(oldval);
VLC_UNUSED(p_data);
cdda_data_t *p_cdda;
if (NULL == p_cdda_input) return VLC_EGENERIC;
p_cdda = (cdda_data_t *)p_cdda_input->p_sys;
#ifdef HAVE_LIBCDDB
if (p_cdda->i_debug & (INPUT_DBG_CALL|INPUT_DBG_EXT))
{
msg_Dbg( p_cdda_input, "old CDDB Enabled (x%0x) %d, new (x%0x) %d",
p_cdda->b_cddb_enabled, p_cdda->b_cddb_enabled,
val.b_bool, val.b_bool);
}
p_cdda->b_cddb_enabled = val.b_bool;
#endif
return VLC_SUCCESS;
}
int
CDTextEnabledCB ( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val, void *p_data )
{
VLC_UNUSED(p_this);
VLC_UNUSED(psz_name);
VLC_UNUSED(oldval);
VLC_UNUSED(p_data);
cdda_data_t *p_cdda;
if (NULL == p_cdda_input) return VLC_EGENERIC;
p_cdda = (cdda_data_t *)p_cdda_input->p_sys;
if (p_cdda->i_debug & (INPUT_DBG_CALL|INPUT_DBG_EXT))
{
msg_Dbg( p_cdda_input, "old CDText Enabled %d, new %d",
p_cdda->b_cdtext, val.b_bool);
}
p_cdda->b_cdtext = val.b_bool;
return VLC_SUCCESS;
}
int
CDDANavModeCB( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val, void *p_data )
{
VLC_UNUSED(p_this);
VLC_UNUSED(psz_name);
VLC_UNUSED(oldval);
VLC_UNUSED(p_data);
cdda_data_t *p_cdda;
if (NULL == p_cdda_input) return VLC_EGENERIC;
p_cdda = (cdda_data_t *)p_cdda_input->p_sys;
if (p_cdda->i_debug & (INPUT_DBG_CALL|INPUT_DBG_EXT))
{
msg_Dbg( p_cdda_input,
"old Navigation Mode Enabled %d, new %d",
p_cdda->b_nav_mode, val.b_bool);
}
p_cdda->b_nav_mode = val.b_bool;
return VLC_SUCCESS;
}
int
CDTextPreferCB ( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val, void *p_data )
{
VLC_UNUSED(p_this);
VLC_UNUSED(psz_name);
VLC_UNUSED(oldval);
VLC_UNUSED(p_data);
cdda_data_t *p_cdda;
if (NULL == p_cdda_input) return VLC_EGENERIC;
p_cdda = (cdda_data_t *)p_cdda_input->p_sys;
#ifdef HAVE_LIBCDDB
if ( p_cdda->i_debug & (INPUT_DBG_CALL|INPUT_DBG_EXT))
{
msg_Dbg( p_cdda_input, "old CDText Prefer (x%0x) %d, new (x%0x) %d",
p_cdda->b_cdtext_prefer, p_cdda->b_cdtext_prefer,
val.b_bool, val.b_bool);
}
p_cdda->b_cdtext_prefer = val.b_bool;
#endif
return VLC_SUCCESS;
}
int
CDDABlocksPerReadCB ( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val, void *p_data )
{
VLC_UNUSED(p_this);
VLC_UNUSED(psz_name);
VLC_UNUSED(oldval);
VLC_UNUSED(p_data);
cdda_data_t *p_cdda;
if (NULL == p_cdda_input) return VLC_EGENERIC;
p_cdda = (cdda_data_t *)p_cdda_input->p_sys;
if (p_cdda->i_debug & (INPUT_DBG_CALL|INPUT_DBG_EXT))
{
msg_Dbg( p_cdda_input, "old blocks per read: %d, new %d",
p_cdda->i_blocks_per_read, val.i_int);
}
if (0 == val.i_int) val.i_int = DEFAULT_BLOCKS_PER_READ;
if ( val.i_int >= MIN_BLOCKS_PER_READ && val.i_int <= MAX_BLOCKS_PER_READ )
p_cdda->i_blocks_per_read = val.i_int;
else
{
msg_Warn( p_cdda_input,
"number of blocks (%d) has to be between %d and %d. No change.",
val.i_int, MIN_BLOCKS_PER_READ, MAX_BLOCKS_PER_READ );
}
return VLC_SUCCESS;
}
/*****************************************************************************
* callback.h : Callbacks for CD digital audio input module
*****************************************************************************
* Copyright (C) 2004 the VideoLAN team
* $Id$
*
* Authors: 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
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <vlc_common.h>
/*
Minimum, maximum and default number of blocks we allow on read.
*/
#define MIN_BLOCKS_PER_READ 1
#define MAX_BLOCKS_PER_READ 25
#define DEFAULT_BLOCKS_PER_READ 20
int CDDADebugCB ( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val,
void *p_data );
int CDDBEnabledCB( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val,
void *p_data );
int CDTextEnabledCB( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val,
void *p_data );
int CDTextPreferCB( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val,
void *p_data );
int CDDANavModeCB( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val,
void *p_data );
int CDDABlocksPerReadCB ( vlc_object_t *p_this, const char *psz_name,
vlc_value_t oldval, vlc_value_t val,
void *p_data );
/*****************************************************************************
* cdda.c : CD digital audio input module for vlc using libcdio
*****************************************************************************
* Copyright (C) 2000, 2003, 2004, 2005 the VideoLAN team
* $Id$
*
* Authors: 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
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
/*****************************************************************************
* Preamble
*****************************************************************************/
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include "callback.h"
#include "access.h"
#include <cdio/version.h>
#include <vlc_plugin.h>
/*****************************************************************************
* Module descriptor
*****************************************************************************/
/*****************************************************************************
* Option help text
*****************************************************************************/
#if LIBCDIO_VERSION_NUM >= 72
static const char *const psz_paranoia_list[] = { "none", "overlap", "full" };
static const char *const psz_paranoia_list_text[] = { N_("none"), N_("overlap"),
N_("full") };
#endif
#define DEBUG_LONGTEXT N_( \
"This integer when viewed in binary is a debugging mask\n" \
"meta info 1\n" \
"events 2\n" \
"MRL 4\n" \
"external call 8\n" \
"all calls (0x10) 16\n" \
"LSN (0x20) 32\n" \
"seek (0x40) 64\n" \
"libcdio (0x80) 128\n" \
"libcddb (0x100) 256\n" )
#define CACHING_LONGTEXT N_( \
"Caching value for CDDA streams. This " \
"value should be set in millisecond units." )
#define BLOCKS_PER_READ_LONGTEXT N_( \
"How many CD blocks to get on a single CD read. " \
"Generally on newer/faster CDs, this increases throughput at the " \
"expense of a little more memory usage and initial delay. SCSI-MMC " \
"limitations generally don't allow for more than 25 blocks per access.")
#define CDDB_TITLE_FMT_LONGTEXT N_( \
"Format used in the GUI Playlist Title. Similar to the Unix date \n" \
"Format specifiers that start with a percent sign. Specifiers are: \n" \
" %a : The artist (for the album)\n" \
" %A : The album information\n" \
" %C : Category\n" \
" %e : The extended data (for a track)\n" \
" %I : CDDB disk ID\n" \
" %G : Genre\n" \
" %M : The current MRL\n" \
" %m : The CD-DA Media Catalog Number (MCN)\n" \
" %n : The number of tracks on the CD\n" \
" %p : The artist/performer/composer in the track\n" \
" %T : The track number\n" \
" %s : Number of seconds in this track\n" \
" %S : Number of seconds in the CD\n" \
" %t : The track title or MRL if no title\n" \
" %Y : The year 19xx or 20xx\n" \
" %% : a % \n")
#define TITLE_FMT_LONGTEXT N_( \
"Format used in the GUI Playlist Title. Similar to the Unix date \n" \
"Format specifiers that start with a percent sign. Specifiers are: \n" \
" %M : The current MRL\n" \
" %m : The CD-DA Media Catalog Number (MCN)\n" \
" %n : The number of tracks on the CD\n" \
" %T : The track number\n" \
" %s : Number of seconds in this track\n" \
" %S : Number of seconds in the CD\n" \
" %t : The track title or MRL if no title\n" \
" %% : a % \n")
#define PARANOIA_TEXT N_("Enable CD paranoia?")
#define PARANOIA_LONGTEXT N_( \
"Select whether to use CD Paranoia for jitter/error correction.\n" \
"none: no paranoia - fastest.\n" \
"overlap: do only overlap detection - not generally recommended.\n" \
"full: complete jitter and error correction detection - slowest.\n" )
/*****************************************************************************
* Module descriptor
*****************************************************************************/
vlc_module_begin ()
add_usage_hint( N_("cddax://[device-or-file][@[T]track]") )
set_description( N_("Compact Disc Digital Audio (CD-DA) input") )
set_capability( "access", 10 /* compare with priority of cdda */ )
set_shortname( N_("Audio Compact Disc"))
set_callbacks( CDDAOpen, CDDAClose )
add_shortcut( "cddax" )
add_shortcut( "cd" )
set_category( CAT_INPUT )
set_subcategory( SUBCAT_INPUT_ACCESS )
/* Configuration options */
add_integer ( MODULE_STRING "-debug", 0, CDDADebugCB,
N_("Additional debug"),
DEBUG_LONGTEXT, true )
add_integer( MODULE_STRING "-caching",
DEFAULT_PTS_DELAY / MILLISECONDS_PER_SEC, NULL,
N_("Caching value in microseconds"),
CACHING_LONGTEXT, true )
add_integer( MODULE_STRING "-blocks-per-read",
DEFAULT_BLOCKS_PER_READ, CDDABlocksPerReadCB,
N_("Number of blocks per CD read"),
BLOCKS_PER_READ_LONGTEXT, true )
add_string( MODULE_STRING "-title-format",
"Track %T. %t", NULL,
N_("Format to use in playlist \"title\" field when no CDDB"),
TITLE_FMT_LONGTEXT, true )
#if LIBCDIO_VERSION_NUM >= 73
add_bool( MODULE_STRING "-analog-output", false, NULL,
N_("Use CD audio controls and output?"),
N_("If set, audio controls and audio jack output are used"),
false )
#endif
add_bool( MODULE_STRING "-cdtext-enabled", true, CDTextEnabledCB,
N_("Do CD-Text lookups?"),
N_("If set, get CD-Text information"),
false )
add_bool( MODULE_STRING "-navigation-mode", true,
#ifdef FIXED
CDDANavModeCB,
#else
NULL,
#endif
N_("Use Navigation-style playback?"),
N_("Tracks are navigated via Navagation rather than "
"a playlist entries"),
false )
#if LIBCDIO_VERSION_NUM >= 72
add_string( MODULE_STRING "-paranoia", NULL, NULL,
PARANOIA_TEXT,
PARANOIA_LONGTEXT,
false )
change_string_list( psz_paranoia_list, psz_paranoia_list_text, 0 );
#endif /* LIBCDIO_VERSION_NUM >= 72 */
#ifdef HAVE_LIBCDDB
set_section( N_("CDDB" ), 0 )
add_string( MODULE_STRING "-cddb-title-format",
"Track %T. %t - %p %A", NULL,
N_("Format to use in playlist \"title\" field when using CDDB"),
CDDB_TITLE_FMT_LONGTEXT, true )
add_bool( MODULE_STRING "-cddb-enabled", true, CDDBEnabledCB,
N_("CDDB lookups"),
N_("If set, lookup CD-DA track information using the CDDB "
"protocol"),
false )
add_string( MODULE_STRING "-cddb-server", "freedb.freedb.org", NULL,
N_("CDDB server"),
N_( "Contact this CDDB server look up CD-DA information"),
true )
add_integer( MODULE_STRING "-cddb-port", 8880, NULL,
N_("CDDB server port"),
N_("CDDB server uses this port number to communicate on"),
true )
add_string( MODULE_STRING "-cddb-email", "me@home", NULL,
N_("email address reported to CDDB server"),
N_("email address reported to CDDB server"),
true )
add_bool( MODULE_STRING "-cddb-enable-cache", true, NULL,
N_("Cache CDDB lookups?"),
N_("If set cache CDDB information about this CD"),
false )
add_bool( MODULE_STRING "-cddb-httpd", false, NULL,
N_("Contact CDDB via the HTTP protocol?"),
N_("If set, the CDDB server gets information via the CDDB HTTP "
"protocol"),
true )
add_integer( MODULE_STRING "-cddb-timeout", 10, NULL,
N_("CDDB server timeout"),
N_("Time (in seconds) to wait for a response from the "
"CDDB server"),
false )
add_string( MODULE_STRING "-cddb-cachedir", "~/.cddbslave", NULL,
N_("Directory to cache CDDB requests"),
N_("Directory to cache CDDB requests"),
true )
add_bool( MODULE_STRING "-cdtext-prefer", true, CDTextPreferCB,
N_("Prefer CD-Text info to CDDB info?"),
N_("If set, CD-Text information will be preferred "
"to CDDB information when both are available"),
false )
#endif /*HAVE_LIBCDDB*/
vlc_module_end ()
/*****************************************************************************
* cdda.h : CD-DA input module header for vlc using libcdio.
*****************************************************************************
* Copyright (C) 2003 the VideoLAN team
* $Id$
*
* 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
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
#include <vlc_input.h>
#include <vlc_access.h>
#include <cdio/cdio.h>
#include <cdio/cdtext.h>
#if LIBCDIO_VERSION_NUM >= 73
#include <cdio/audio.h>
#include <cdio/mmc.h>
#endif
#include <vlc_meta.h>
#include <vlc_codecs.h>
#ifdef HAVE_LIBCDDB
#include <cddb/cddb.h>
#endif
#define CDDA_MRL_PREFIX "cddax://"
/* Frequency of sample in bits per second. */
#define CDDA_FREQUENCY_SAMPLE 44100
/*****************************************************************************
* Debugging
*****************************************************************************/
#define INPUT_DBG_META 1 /* Meta information */
#define INPUT_DBG_EVENT 2 /* Trace keyboard events */
#define INPUT_DBG_MRL 4 /* MRL debugging */
#define INPUT_DBG_EXT 8 /* Calls from external routines */
#define INPUT_DBG_CALL 16 /* all calls */
#define INPUT_DBG_LSN 32 /* LSN changes */
#define INPUT_DBG_SEEK 64 /* Seeks to set location */
#define INPUT_DBG_CDIO 128 /* Debugging from CDIO */
#define INPUT_DBG_CDDB 256 /* CDDB debugging */
#define INPUT_DEBUG 1
#if INPUT_DEBUG
#define dbg_print(mask, s, args...) \
if (p_cdda->i_debug & mask) \
msg_Dbg(p_access, "%s: "s, __func__ , ##args)
#else
#define dbg_print(mask, s, args...)
#endif
#if LIBCDIO_VERSION_NUM >= 72
#include <cdio/cdda.h>
#include <cdio/paranoia.h>
#else
#define CdIo_t CdIo
#endif
/*****************************************************************************
* cdda_data_t: CD audio information
*****************************************************************************/
typedef struct cdda_data_s
{
CdIo_t *p_cdio; /* libcdio CD device */
track_t i_tracks; /* # of tracks */
track_t i_first_track; /* # of first track */
track_t i_titles; /* # of titles in playlist */
/* Current position */
track_t i_track; /* Current track */
lsn_t i_lsn; /* Current Logical Sector Number */
lsn_t first_frame; /* LSN of first frame of this track */
lsn_t last_frame; /* LSN of last frame of this track */
lsn_t last_disc_frame; /* LSN of last frame on CD */
int i_blocks_per_read; /* # blocks to get in a read */
int i_debug; /* Debugging mask */
/* Information about CD */
vlc_meta_t *p_meta;
char * psz_mcn; /* Media Catalog Number */
char * psz_source; /* CD drive or CD image filename */
input_title_t *p_title[CDIO_CD_MAX_TRACKS]; /* This *is* 0 origin, not
track number origin */
#if LIBCDIO_VERSION_NUM >= 72
/* Paranoia support */
paranoia_mode_t e_paranoia; /* Use cd paranoia for reads? */
cdrom_drive_t *paranoia_cd; /* Place to store drive
handle given by paranoia. */
cdrom_paranoia_t *paranoia;
#endif
#ifdef HAVE_LIBCDDB
bool b_cddb_enabled; /* Use CDDB at all? */
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 */
} cddb;
#endif
bool b_audio_ctl; /* Use CD-Text audio controls and
audio output? */
bool b_cdtext; /* Use CD-Text at all? If not,
cdtext_preferred is meaningless. */
bool b_cdtext_prefer; /* Prefer CD-Text info over
CDDB? If no CDDB, the issue
is moot. */
const cdtext_t *p_cdtext[CDIO_CD_MAX_TRACKS]; /* CD-Text info. Origin is NOT
0 origin but origin of track
number (usually 1).
*/
WAVEHEADER waveheader; /* Wave header for the output data */
bool b_header;
bool b_nav_mode; /* If false we view the entire CD as
as a unit rather than each track
as a unit. If b_nav_mode then the
slider area represents the Disc rather
than a track
*/
input_thread_t *p_input;
} cdda_data_t;
/* FIXME: This variable is a hack. Would be nice to eliminate. */
extern access_t *p_cdda_input;
This diff is collapsed.
/*****************************************************************************
* info.h : CD digital audio input information routine headers
*****************************************************************************
* Copyright (C) 2004 the VideoLAN team
* $Id$
*
* Authors: 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
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
/*
Fills out playlist information.
*/
int CDDAFixupPlaylist( access_t *p_access, cdda_data_t *p_cdda,
bool b_single_track );
/*
Sets CDDA Meta Information. In the Control routine,
we handle Meta Information requests and basically copy what we've
saved here.
*/
void CDDAMetaInfo( access_t *p_access, track_t i_track );
char *CDDAFormatTitle( const access_t *p_access, track_t i_track );
...@@ -219,14 +219,6 @@ modules/access/bda/bdadefs.h ...@@ -219,14 +219,6 @@ modules/access/bda/bdadefs.h
modules/access/bda/bdagraph.cpp modules/access/bda/bdagraph.cpp
modules/access/bda/bdagraph.h modules/access/bda/bdagraph.h
modules/access/cdda.c modules/access/cdda.c
modules/access/cdda/access.c
modules/access/cdda/access.h
modules/access/cdda/callback.c
modules/access/cdda/callback.h
modules/access/cdda/cdda.c
modules/access/cdda/cdda.h
modules/access/cdda/info.c
modules/access/cdda/info.h
modules/access/dc1394.c modules/access/dc1394.c
modules/access/directory.c modules/access/directory.c
modules/access/dshow/common.h modules/access/dshow/common.h
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment