libdvdcss
1.4.2
src
dvdcss
dvdcss.h
Go to the documentation of this file.
1
11
/*
12
* Copyright (C) 1998-2008 VideoLAN
13
*
14
* libdvdcss is free software; you can redistribute it and/or modify
15
* it under the terms of the GNU General Public License as published by
16
* the Free Software Foundation; either version 2 of the License, or
17
* (at your option) any later version.
18
*
19
* libdvdcss is distributed in the hope that it will be useful,
20
* but WITHOUT ANY WARRANTY; without even the implied warranty of
21
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22
* GNU General Public License for more details.
23
*
24
* You should have received a copy of the GNU General Public License along
25
* with libdvdcss; if not, write to the Free Software Foundation, Inc.,
26
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
27
*/
28
29
#ifndef DVDCSS_DVDCSS_H
30
#ifndef _DOXYGEN_SKIP_ME
31
#define DVDCSS_DVDCSS_H 1
32
#endif
33
34
#include <stdint.h>
35
36
#include "version.h"
37
38
#ifdef __cplusplus
39
extern
"C"
{
40
#endif
41
43
typedef
struct
dvdcss_s*
dvdcss_t
;
44
46
typedef
struct
dvdcss_stream_cb
47
{
49
int ( *
pf_seek
) (
void
*p_stream, uint64_t i_pos);
51
int ( *
pf_read
) (
void
*p_stream,
void
*buffer,
int
i_read);
53
int ( *
pf_readv
) (
void
*p_stream,
const
void
*p_iovec,
int
i_blocks);
54
}
dvdcss_stream_cb
;
55
56
58
#define DVDCSS_BLOCK_SIZE 2048
59
61
#define DVDCSS_NOFLAGS 0
62
64
#define DVDCSS_READ_DECRYPT (1 << 0)
65
67
#define DVDCSS_SEEK_MPEG (1 << 0)
68
70
#define DVDCSS_SEEK_KEY (1 << 1)
71
72
76
#if defined(LIBDVDCSS_EXPORTS)
77
#define LIBDVDCSS_EXPORT __declspec(dllexport) extern
78
#elif defined(LIBDVDCSS_IMPORTS)
79
#define LIBDVDCSS_EXPORT __declspec(dllimport) extern
80
#elif defined(SUPPORT_ATTRIBUTE_VISIBILITY_DEFAULT)
81
#define LIBDVDCSS_EXPORT __attribute__((visibility("default"))) extern
82
#else
83
#define LIBDVDCSS_EXPORT extern
84
#endif
85
86
87
/*
88
* Exported prototypes.
89
*/
90
LIBDVDCSS_EXPORT
dvdcss_t
dvdcss_open
(
const
char
*psz_target );
91
LIBDVDCSS_EXPORT
dvdcss_t
dvdcss_open_stream
(
void
*p_stream,
92
dvdcss_stream_cb
*p_stream_cb );
93
LIBDVDCSS_EXPORT
int
dvdcss_close
( dvdcss_t );
94
LIBDVDCSS_EXPORT
int
dvdcss_seek
( dvdcss_t,
95
int
i_blocks,
96
int
i_flags );
97
LIBDVDCSS_EXPORT
int
dvdcss_read
( dvdcss_t,
98
void
*p_buffer,
99
int
i_blocks,
100
int
i_flags );
101
LIBDVDCSS_EXPORT
int
dvdcss_readv
( dvdcss_t,
102
void
*p_iovec,
103
int
i_blocks,
104
int
i_flags );
105
LIBDVDCSS_EXPORT
const
char
*
dvdcss_error
(
const
dvdcss_t );
106
107
LIBDVDCSS_EXPORT
int
dvdcss_is_scrambled
( dvdcss_t );
108
109
#ifdef __cplusplus
110
}
111
#endif
112
113
#endif
/* DVDCSS_DVDCSS_H */
Generated on Fri Aug 31 2018 21:24:44 for libdvdcss by
1.8.3.1