vo_corevideo: Avoid some code duplication.
[mplayer/glamo.git] / libdvdcss / device.h
blob33c53ac64f3d8e9b37ecf7732e5f56911a9f1a8e
1 /*****************************************************************************
2 * device.h: DVD device access
3 *****************************************************************************
4 * Copyright (C) 1998-2002 VideoLAN
5 * $Id$
7 * Authors: Stéphane Borel <stef@via.ecp.fr>
8 * Sam Hocevar <sam@zoy.org>
9 * Håkan Hjort <d95hjort@dtek.chalmers.se>
11 * This program is free software; you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License as published by
13 * the Free Software Foundation; either version 2 of the License, or
14 * (at your option) any later version.
16 * This program is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU General Public License for more details.
21 * You should have received a copy of the GNU General Public License along
22 * with libdvdcss; if not, write to the Free Software Foundation, Inc.,
23 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
24 *****************************************************************************/
26 /*****************************************************************************
27 * iovec structure: vectored data entry
28 *****************************************************************************/
29 #if defined( WIN32 ) && !defined( SYS_CYGWIN )
30 # include <io.h> /* read() */
31 #else
32 # include <sys/types.h>
33 # include <sys/uio.h> /* struct iovec */
34 #endif
36 #if defined( WIN32 ) && !defined( SYS_CYGWIN )
37 struct iovec
39 void *iov_base; /* Pointer to data. */
40 size_t iov_len; /* Length of data. */
42 #endif
44 /*****************************************************************************
45 * Device reading prototypes
46 *****************************************************************************/
47 int _dvdcss_use_ioctls ( dvdcss_t );
48 void _dvdcss_check ( dvdcss_t );
49 int _dvdcss_open ( dvdcss_t );
50 int _dvdcss_close ( dvdcss_t );
52 /*****************************************************************************
53 * Device reading prototypes, raw-device specific
54 *****************************************************************************/
55 #if !defined(WIN32) && !defined(SYS_OS2)
56 int _dvdcss_raw_open ( dvdcss_t, char const * );
57 #endif