|
Packit |
015a35 |
/*
|
|
Packit |
015a35 |
* Copyright (C) 2001, 2002 Samuel Hocevar <sam@zoy.org>,
|
|
Packit |
015a35 |
* HÃ¥kan Hjort <d95hjort@dtek.chalmers.se>
|
|
Packit |
015a35 |
*
|
|
Packit |
015a35 |
* This file is part of libdvdread.
|
|
Packit |
015a35 |
*
|
|
Packit |
015a35 |
* libdvdread is free software; you can redistribute it and/or modify
|
|
Packit |
015a35 |
* it under the terms of the GNU General Public License as published by
|
|
Packit |
015a35 |
* the Free Software Foundation; either version 2 of the License, or
|
|
Packit |
015a35 |
* (at your option) any later version.
|
|
Packit |
015a35 |
*
|
|
Packit |
015a35 |
* libdvdread is distributed in the hope that it will be useful,
|
|
Packit |
015a35 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
Packit |
015a35 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
Packit |
015a35 |
* GNU General Public License for more details.
|
|
Packit |
015a35 |
*
|
|
Packit |
015a35 |
* You should have received a copy of the GNU General Public License along
|
|
Packit |
015a35 |
* with libdvdread; if not, write to the Free Software Foundation, Inc.,
|
|
Packit |
015a35 |
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
Packit |
015a35 |
*/
|
|
Packit |
015a35 |
|
|
Packit |
015a35 |
#ifndef LIBDVDREAD_DVD_INPUT_H
|
|
Packit |
015a35 |
#define LIBDVDREAD_DVD_INPUT_H
|
|
Packit |
015a35 |
|
|
Packit |
015a35 |
/**
|
|
Packit |
015a35 |
* Defines and flags. Make sure they fit the libdvdcss API!
|
|
Packit |
015a35 |
*/
|
|
Packit |
015a35 |
#define DVDINPUT_NOFLAGS 0
|
|
Packit |
015a35 |
|
|
Packit |
015a35 |
#define DVDINPUT_READ_DECRYPT (1 << 0)
|
|
Packit |
015a35 |
|
|
Packit |
015a35 |
typedef struct dvd_input_s *dvd_input_t;
|
|
Packit |
015a35 |
|
|
Packit |
015a35 |
#if defined( __MINGW32__ )
|
|
Packit |
015a35 |
# undef lseek
|
|
Packit |
015a35 |
# define lseek _lseeki64
|
|
Packit |
015a35 |
# undef off_t
|
|
Packit |
015a35 |
# define off_t off64_t
|
|
Packit |
015a35 |
# undef stat
|
|
Packit |
015a35 |
# define stat _stati64
|
|
Packit |
015a35 |
# undef fstat
|
|
Packit |
015a35 |
# define fstat _fstati64
|
|
Packit |
015a35 |
# undef wstat
|
|
Packit |
015a35 |
# define wstat _wstati64
|
|
Packit |
015a35 |
#endif
|
|
Packit |
015a35 |
|
|
Packit |
015a35 |
#ifdef __ANDROID__
|
|
Packit |
015a35 |
# undef lseek
|
|
Packit |
015a35 |
# define lseek lseek64
|
|
Packit |
015a35 |
# undef off_t
|
|
Packit |
015a35 |
# define off_t off64_t
|
|
Packit |
015a35 |
#endif
|
|
Packit |
015a35 |
|
|
Packit |
015a35 |
/**
|
|
Packit |
015a35 |
* Function pointers that will be filled in by the input implementation.
|
|
Packit |
015a35 |
* These functions provide the main API.
|
|
Packit |
015a35 |
*/
|
|
Packit |
015a35 |
extern dvd_input_t (*dvdinput_open) (const char *,
|
|
Packit |
015a35 |
void *, dvd_reader_stream_cb *);
|
|
Packit |
015a35 |
extern int (*dvdinput_close) (dvd_input_t);
|
|
Packit |
015a35 |
extern int (*dvdinput_seek) (dvd_input_t, int);
|
|
Packit |
015a35 |
extern int (*dvdinput_title) (dvd_input_t, int);
|
|
Packit |
015a35 |
extern int (*dvdinput_read) (dvd_input_t, void *, int, int);
|
|
Packit |
015a35 |
extern char * (*dvdinput_error) (dvd_input_t);
|
|
Packit |
015a35 |
|
|
Packit |
015a35 |
/**
|
|
Packit |
015a35 |
* Setup function accessed by dvd_reader.c. Returns 1 if there is CSS support.
|
|
Packit |
015a35 |
*/
|
|
Packit |
015a35 |
int dvdinput_setup(void);
|
|
Packit |
015a35 |
|
|
Packit |
015a35 |
#endif /* LIBDVDREAD_DVD_INPUT_H */
|