Commit 9b393dab authored by Stéphane Borel's avatar Stéphane Borel

*dvd and dvdread support for input III.

Dvdread is known to segfault at title change. I'm working on this.
parent d0bf23fa
...@@ -6387,7 +6387,7 @@ if test "${with_dvdcss+set}" = set; then ...@@ -6387,7 +6387,7 @@ if test "${with_dvdcss+set}" = set; then
case "x${withval}" in case "x${withval}" in
xlocal-static|xyes) xlocal-static|xyes)
# local libdvdcss, statically linked # local libdvdcss, statically linked
#BUILTINS="${BUILTINS} dvd" BUILTINS="${BUILTINS} dvd"
if test x${CAN_BUILD_LIBDVDCSS} = x1 if test x${CAN_BUILD_LIBDVDCSS} = x1
then then
NEED_LIBDVDCSS=1 NEED_LIBDVDCSS=1
...@@ -6398,7 +6398,7 @@ if test "${with_dvdcss+set}" = set; then ...@@ -6398,7 +6398,7 @@ if test "${with_dvdcss+set}" = set; then
;; ;;
xlocal-shared) xlocal-shared)
# local libdvdcss, dynamically linked # local libdvdcss, dynamically linked
#PLUGINS="${PLUGINS} dvd" PLUGINS="${PLUGINS} dvd"
if test x${CAN_BUILD_LIBDVDCSS} = x1 if test x${CAN_BUILD_LIBDVDCSS} = x1
then then
NEED_LIBDVDCSS=1 NEED_LIBDVDCSS=1
...@@ -6408,7 +6408,7 @@ if test "${with_dvdcss+set}" = set; then ...@@ -6408,7 +6408,7 @@ if test "${with_dvdcss+set}" = set; then
;; ;;
xno) xno)
# don't use libdvdcss at all, build a DVD module that can dlopen() it # don't use libdvdcss at all, build a DVD module that can dlopen() it
#BUILTINS="${BUILTINS} dvd" BUILTINS="${BUILTINS} dvd"
DUMMY_LIBDVDCSS=1 DUMMY_LIBDVDCSS=1
SRC_DVD_EXTRA="${SRC_DVD_EXTRA} dummy_dvdcss.c" SRC_DVD_EXTRA="${SRC_DVD_EXTRA} dummy_dvdcss.c"
CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA" CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA"
...@@ -6417,7 +6417,7 @@ if test "${with_dvdcss+set}" = set; then ...@@ -6417,7 +6417,7 @@ if test "${with_dvdcss+set}" = set; then
;; ;;
*) *)
# existing libdvdcss # existing libdvdcss
#PLUGINS="${PLUGINS} dvd" PLUGINS="${PLUGINS} dvd"
if test "x$withval" != "xyes" if test "x$withval" != "xyes"
then then
LIB_DVD="${LIB_DVD} -L"$withval"/lib" LIB_DVD="${LIB_DVD} -L"$withval"/lib"
...@@ -6430,14 +6430,14 @@ else ...@@ -6430,14 +6430,14 @@ else
# if libdvdcss is in the archive, or to use the dummy replacement otherwise. # if libdvdcss is in the archive, or to use the dummy replacement otherwise.
if test x${CAN_BUILD_LIBDVDCSS} = x1 if test x${CAN_BUILD_LIBDVDCSS} = x1
then then
#BUILTINS="${BUILTINS} dvd" BUILTINS="${BUILTINS} dvd"
NEED_LIBDVDCSS=1 NEED_LIBDVDCSS=1
STATIC_LIBDVDCSS=1 STATIC_LIBDVDCSS=1
CFLAGS_DVD="${CFLAGS_DVD} -I../../extras/libdvdcss" CFLAGS_DVD="${CFLAGS_DVD} -I../../extras/libdvdcss"
LIB_DVD="${LIB_DVD} lib/libdvdcss.a ${LIB_LIBDVDCSS}" LIB_DVD="${LIB_DVD} lib/libdvdcss.a ${LIB_LIBDVDCSS}"
else else
# XXX: no check for libdl is done, don't try this at home ! # XXX: no check for libdl is done, don't try this at home !
#BUILTINS="${BUILTINS} dvd" BUILTINS="${BUILTINS} dvd"
DUMMY_LIBDVDCSS=1 DUMMY_LIBDVDCSS=1
SRC_DVD_EXTRA="${SRC_DVD_EXTRA} dummy_dvdcss.c" SRC_DVD_EXTRA="${SRC_DVD_EXTRA} dummy_dvdcss.c"
CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA" CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA"
......
...@@ -788,7 +788,7 @@ AC_ARG_WITH(dvdcss, ...@@ -788,7 +788,7 @@ AC_ARG_WITH(dvdcss,
[ case "x${withval}" in [ case "x${withval}" in
xlocal-static|xyes) xlocal-static|xyes)
# local libdvdcss, statically linked # local libdvdcss, statically linked
#BUILTINS="${BUILTINS} dvd" BUILTINS="${BUILTINS} dvd"
if test x${CAN_BUILD_LIBDVDCSS} = x1 if test x${CAN_BUILD_LIBDVDCSS} = x1
then then
NEED_LIBDVDCSS=1 NEED_LIBDVDCSS=1
...@@ -799,7 +799,7 @@ AC_ARG_WITH(dvdcss, ...@@ -799,7 +799,7 @@ AC_ARG_WITH(dvdcss,
;; ;;
xlocal-shared) xlocal-shared)
# local libdvdcss, dynamically linked # local libdvdcss, dynamically linked
#PLUGINS="${PLUGINS} dvd" PLUGINS="${PLUGINS} dvd"
if test x${CAN_BUILD_LIBDVDCSS} = x1 if test x${CAN_BUILD_LIBDVDCSS} = x1
then then
NEED_LIBDVDCSS=1 NEED_LIBDVDCSS=1
...@@ -809,7 +809,7 @@ AC_ARG_WITH(dvdcss, ...@@ -809,7 +809,7 @@ AC_ARG_WITH(dvdcss,
;; ;;
xno) xno)
# don't use libdvdcss at all, build a DVD module that can dlopen() it # don't use libdvdcss at all, build a DVD module that can dlopen() it
#BUILTINS="${BUILTINS} dvd" BUILTINS="${BUILTINS} dvd"
DUMMY_LIBDVDCSS=1 DUMMY_LIBDVDCSS=1
SRC_DVD_EXTRA="${SRC_DVD_EXTRA} dummy_dvdcss.c" SRC_DVD_EXTRA="${SRC_DVD_EXTRA} dummy_dvdcss.c"
CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA" CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA"
...@@ -818,7 +818,7 @@ AC_ARG_WITH(dvdcss, ...@@ -818,7 +818,7 @@ AC_ARG_WITH(dvdcss,
;; ;;
*) *)
# existing libdvdcss # existing libdvdcss
#PLUGINS="${PLUGINS} dvd" PLUGINS="${PLUGINS} dvd"
if test "x$withval" != "xyes" if test "x$withval" != "xyes"
then then
LIB_DVD="${LIB_DVD} -L"$withval"/lib" LIB_DVD="${LIB_DVD} -L"$withval"/lib"
...@@ -830,14 +830,14 @@ AC_ARG_WITH(dvdcss, ...@@ -830,14 +830,14 @@ AC_ARG_WITH(dvdcss,
# if libdvdcss is in the archive, or to use the dummy replacement otherwise. # if libdvdcss is in the archive, or to use the dummy replacement otherwise.
[ if test x${CAN_BUILD_LIBDVDCSS} = x1 [ if test x${CAN_BUILD_LIBDVDCSS} = x1
then then
#BUILTINS="${BUILTINS} dvd" BUILTINS="${BUILTINS} dvd"
NEED_LIBDVDCSS=1 NEED_LIBDVDCSS=1
STATIC_LIBDVDCSS=1 STATIC_LIBDVDCSS=1
CFLAGS_DVD="${CFLAGS_DVD} -I../../extras/libdvdcss" CFLAGS_DVD="${CFLAGS_DVD} -I../../extras/libdvdcss"
LIB_DVD="${LIB_DVD} lib/libdvdcss.a ${LIB_LIBDVDCSS}" LIB_DVD="${LIB_DVD} lib/libdvdcss.a ${LIB_LIBDVDCSS}"
else else
# XXX: no check for libdl is done, don't try this at home ! # XXX: no check for libdl is done, don't try this at home !
#BUILTINS="${BUILTINS} dvd" BUILTINS="${BUILTINS} dvd"
DUMMY_LIBDVDCSS=1 DUMMY_LIBDVDCSS=1
SRC_DVD_EXTRA="${SRC_DVD_EXTRA} dummy_dvdcss.c" SRC_DVD_EXTRA="${SRC_DVD_EXTRA} dummy_dvdcss.c"
CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA" CFLAGS_DVD="${CFLAGS_DVD} -DGOD_DAMN_DMCA"
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* dvd.c : DVD input module for vlc * dvd.c : DVD input module for vlc
***************************************************************************** *****************************************************************************
* Copyright (C) 2000-2001 VideoLAN * Copyright (C) 2000-2001 VideoLAN
* $Id: dvd.c,v 1.21 2002/03/01 00:33:18 massiot Exp $ * $Id: dvd.c,v 1.22 2002/03/01 01:12:28 stef Exp $
* *
* Authors: Samuel Hocevar <sam@zoy.org> * Authors: Samuel Hocevar <sam@zoy.org>
* *
...@@ -37,8 +37,8 @@ ...@@ -37,8 +37,8 @@
/***************************************************************************** /*****************************************************************************
* Capabilities defined in the other files. * Capabilities defined in the other files.
*****************************************************************************/ *****************************************************************************/
void _M( access_getfunctions )( function_list_t * p_function_list ); void _M( access_getfunctions)( function_list_t * p_function_list );
void _M( demux_getfunctions )( function_list_t * p_function_list ); void _M( demux_getfunctions)( function_list_t * p_function_list );
/***************************************************************************** /*****************************************************************************
* Local prototypes. * Local prototypes.
...@@ -58,17 +58,19 @@ MODULE_CONFIG_STOP ...@@ -58,17 +58,19 @@ MODULE_CONFIG_STOP
MODULE_INIT_START MODULE_INIT_START
#ifdef GOD_DAMN_DMCA #ifdef GOD_DAMN_DMCA
SET_DESCRIPTION( "DVD input module, uses libdvdcss if present" ) SET_DESCRIPTION( "DVD input module, uses libdvdcss if present" )
ADD_CAPABILITY( DEMUX, 190 )
ADD_CAPABILITY( ACCESS, 90 )
#else #else
SET_DESCRIPTION( "DVD input module, linked with libdvdcss" ) SET_DESCRIPTION( "DVD input module, linked with libdvdcss" )
ADD_CAPABILITY( DEMUX, 200 )
ADD_CAPABILITY( ACCESS, 100 )
#endif #endif
ADD_CAPABILITY( ACCESS, 0 )
ADD_CAPABILITY( DEMUX, 0 )
ADD_SHORTCUT( "dvd" ) ADD_SHORTCUT( "dvd" )
MODULE_INIT_STOP MODULE_INIT_STOP
MODULE_ACTIVATE_START MODULE_ACTIVATE_START
_M( access_getfunctions )( &p_module->p_functions->access ); _M( access_getfunctions)( &p_module->p_functions->access );
_M( demux_getfunctions )( &p_module->p_functions->demux ); _M( demux_getfunctions)( &p_module->p_functions->demux );
#ifdef GOD_DAMN_DMCA #ifdef GOD_DAMN_DMCA
ProbeLibDVDCSS(); ProbeLibDVDCSS();
#endif #endif
......
This diff is collapsed.
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* input_dvd.h: thread structure of the DVD plugin * input_dvd.h: thread structure of the DVD plugin
***************************************************************************** *****************************************************************************
* Copyright (C) 1999-2001 VideoLAN * Copyright (C) 1999-2001 VideoLAN
* $Id: input_dvd.h,v 1.24 2001/06/12 22:14:44 sam Exp $ * $Id: input_dvd.h,v 1.25 2002/03/01 01:12:28 stef Exp $
* *
* Author: Stéphane Borel <stef@via.ecp.fr> * Author: Stéphane Borel <stef@via.ecp.fr>
* *
...@@ -36,9 +36,6 @@ typedef struct thread_dvd_data_s ...@@ -36,9 +36,6 @@ typedef struct thread_dvd_data_s
{ {
dvdcss_handle dvdhandle; /* libdvdcss handle */ dvdcss_handle dvdhandle; /* libdvdcss handle */
int i_block_once; // Nb of block read once by
// readv
/* Navigation information */ /* Navigation information */
int i_title; int i_title;
int i_title_id; int i_title_id;
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* dvdread.c : DvdRead input module for vlc * dvdread.c : DvdRead input module for vlc
***************************************************************************** *****************************************************************************
* Copyright (C) 2001 VideoLAN * Copyright (C) 2001 VideoLAN
* $Id: dvdread.c,v 1.10 2002/02/26 01:17:13 stef Exp $ * $Id: dvdread.c,v 1.11 2002/03/01 01:12:28 stef Exp $
* *
* Authors: Samuel Hocevar <sam@zoy.org> * Authors: Samuel Hocevar <sam@zoy.org>
* *
...@@ -32,7 +32,8 @@ ...@@ -32,7 +32,8 @@
/***************************************************************************** /*****************************************************************************
* Capabilities defined in the other files. * Capabilities defined in the other files.
*****************************************************************************/ *****************************************************************************/
void _M( input_getfunctions )( function_list_t * p_function_list ); void _M( access_getfunctions)( function_list_t * p_function_list );
void _M( demux_getfunctions)( function_list_t * p_function_list );
/***************************************************************************** /*****************************************************************************
* Build configuration tree. * Build configuration tree.
...@@ -42,13 +43,14 @@ MODULE_CONFIG_STOP ...@@ -42,13 +43,14 @@ MODULE_CONFIG_STOP
MODULE_INIT_START MODULE_INIT_START
SET_DESCRIPTION( "DVDRead input module" ) SET_DESCRIPTION( "DVDRead input module" )
ADD_CAPABILITY( INPUT, 110 ) ADD_CAPABILITY( DEMUX, 210 )
ADD_CAPABILITY( ACCESS, 110 )
ADD_SHORTCUT( "dvdread" ) ADD_SHORTCUT( "dvdread" )
MODULE_INIT_STOP MODULE_INIT_STOP
MODULE_ACTIVATE_START MODULE_ACTIVATE_START
_M( input_getfunctions )( &p_module->p_functions->input ); _M( access_getfunctions)( &p_module->p_functions->access );
_M( demux_getfunctions)( &p_module->p_functions->demux );
MODULE_ACTIVATE_STOP MODULE_ACTIVATE_STOP
MODULE_DEACTIVATE_START MODULE_DEACTIVATE_START
......
This diff is collapsed.
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* input_dvdread.h: thread structure of the DVD plugin * input_dvdread.h: thread structure of the DVD plugin
***************************************************************************** *****************************************************************************
* Copyright (C) 1999-2001 VideoLAN * Copyright (C) 1999-2001 VideoLAN
* $Id: input_dvdread.h,v 1.4 2002/01/23 03:15:31 stef Exp $ * $Id: input_dvdread.h,v 1.5 2002/03/01 01:12:28 stef Exp $
* *
* Author: Stphane Borel <stef@via.ecp.fr> * Author: Stphane Borel <stef@via.ecp.fr>
* *
...@@ -66,7 +66,5 @@ typedef struct thread_dvd_data_s ...@@ -66,7 +66,5 @@ typedef struct thread_dvd_data_s
boolean_t b_eoc; boolean_t b_eoc;
int i_angle_nb; int i_angle_nb;
int i_angle; int i_angle;
int i_block_once; // Nb of block read once
} thread_dvd_data_t; } thread_dvd_data_t;
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
* decoders. * decoders.
***************************************************************************** *****************************************************************************
* Copyright (C) 1998-2001 VideoLAN * Copyright (C) 1998-2001 VideoLAN
* $Id: input.c,v 1.180 2002/03/01 00:33:18 massiot Exp $ * $Id: input.c,v 1.181 2002/03/01 01:12:28 stef Exp $
* *
* Authors: Christophe Massiot <massiot@via.ecp.fr> * Authors: Christophe Massiot <massiot@via.ecp.fr>
* Alexis Guillard <alexis.guillard@bt.com> * Alexis Guillard <alexis.guillard@bt.com>
...@@ -129,6 +129,20 @@ input_thread_t *input_CreateThread ( playlist_item_t *p_item, int *pi_status ) ...@@ -129,6 +129,20 @@ input_thread_t *input_CreateThread ( playlist_item_t *p_item, int *pi_status )
/* Set status */ /* Set status */
p_input->i_status = THREAD_CREATE; p_input->i_status = THREAD_CREATE;
/* Demux */
p_input->pf_init = NULL;
p_input->pf_end = NULL;
p_input->pf_demux = NULL;
p_input->pf_rewind = NULL;
/* Access */
p_input->pf_open = NULL;
p_input->pf_close = NULL;
p_input->pf_read = NULL;
p_input->pf_seek = NULL;
p_input->pf_set_area = NULL;
p_input->pf_set_program = NULL;
/* Initialize statistics */ /* Initialize statistics */
p_input->c_loops = 0; p_input->c_loops = 0;
p_input->stream.c_packets_read = 0; p_input->stream.c_packets_read = 0;
......
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