annotate libmpdvdkit2/ioctl.h @ 9076:92014b66ed3d

ability to disable the nonsense expand filter is a must! otherwise it's impossible to render subtitles earlier in the filter chain and then scale them down with a scale filter; huge subs will get rendered again on top!! (think dvd/vobsub where you can't just use smaller font size) if anyone has a better way to handle this, do it! (e.g. make it so that the first expand filter disabled osd for the rest of the filter chain)
author rfelker
date Fri, 24 Jan 2003 01:04:50 +0000
parents 0211de3039eb
children f0f0f176d298
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7027
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
1 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
2 * ioctl.h: DVD ioctl replacement function
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
3 *****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
4 * Copyright (C) 1999-2001 VideoLAN
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
5 * $Id$
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
6 *
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
7 * Authors: Samuel Hocevar <sam@zoy.org>
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
8 *
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
9 * This program is free software; you can redistribute it and/or modify
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
10 * it under the terms of the GNU General Public License as published by
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
11 * the Free Software Foundation; either version 2 of the License, or
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
12 * (at your option) any later version.
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
13 *
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
14 * This program is distributed in the hope that it will be useful,
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
17 * GNU General Public License for more details.
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
18 *
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
19 * You should have received a copy of the GNU General Public License
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
20 * along with this program; if not, write to the Free Software
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
21 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
22 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
23
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
24 int ioctl_ReadCopyright ( int, int, int * );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
25 int ioctl_ReadDiscKey ( int, int *, u8 * );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
26 int ioctl_ReadTitleKey ( int, int *, int, u8 * );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
27 int ioctl_ReportAgid ( int, int * );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
28 int ioctl_ReportChallenge ( int, int *, u8 * );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
29 int ioctl_ReportKey1 ( int, int *, u8 * );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
30 int ioctl_ReportASF ( int, int *, int * );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
31 int ioctl_InvalidateAgid ( int, int * );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
32 int ioctl_SendChallenge ( int, int *, u8 * );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
33 int ioctl_SendKey2 ( int, int *, u8 * );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
34
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
35 #define DVD_KEY_SIZE 5
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
36 #define DVD_CHALLENGE_SIZE 10
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
37 #define DVD_DISCKEY_SIZE 2048
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
38
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
39 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
40 * Common macro, BeOS specific
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
41 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
42 #if defined( SYS_BEOS )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
43 #define INIT_RDC( TYPE, SIZE ) \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
44 raw_device_command rdc; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
45 u8 p_buffer[ (SIZE) ]; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
46 memset( &rdc, 0, sizeof( raw_device_command ) ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
47 rdc.data = (char *)p_buffer; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
48 rdc.data_length = (SIZE); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
49 BeInitRDC( &rdc, (TYPE) );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
50 #endif
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
51
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
52 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
53 * Common macro, HP-UX specific
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
54 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
55 #if defined( HPUX_SCTL_IO )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
56 #define INIT_SCTL_IO( TYPE, SIZE ) \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
57 struct sctl_io sctl_io; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
58 u8 p_buffer[ (SIZE) ]; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
59 memset( &sctl_io, 0, sizeof( sctl_io ) ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
60 sctl_io.data = (void *)p_buffer; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
61 sctl_io.data_length = (SIZE); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
62 HPUXInitSCTL( &sctl_io, (TYPE) );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
63 #endif
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
64
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
65 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
66 * Common macro, Solaris specific
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
67 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
68 #if defined( SOLARIS_USCSI )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
69 #define USCSI_TIMEOUT( SC, TO ) ( (SC)->uscsi_timeout = (TO) )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
70 #define USCSI_RESID( SC ) ( (SC)->uscsi_resid )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
71 #define INIT_USCSI( TYPE, SIZE ) \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
72 struct uscsi_cmd sc; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
73 union scsi_cdb rs_cdb; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
74 u8 p_buffer[ (SIZE) ]; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
75 memset( &sc, 0, sizeof( struct uscsi_cmd ) ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
76 sc.uscsi_cdb = (caddr_t)&rs_cdb; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
77 sc.uscsi_bufaddr = p_buffer; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
78 sc.uscsi_buflen = (SIZE); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
79 SolarisInitUSCSI( &sc, (TYPE) );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
80 #endif
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
81
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
82 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
83 * Common macro, Darwin specific
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
84 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
85 #if defined( DARWIN_DVD_IOCTL )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
86 #define INIT_DVDIOCTL( DKDVD_TYPE, BUFFER_TYPE, FORMAT ) \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
87 DKDVD_TYPE dvd; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
88 BUFFER_TYPE dvdbs; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
89 memset( &dvd, 0, sizeof(dvd) ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
90 memset( &dvdbs, 0, sizeof(dvdbs) ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
91 dvd.format = FORMAT; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
92 dvd.buffer = &dvdbs; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
93 dvd.bufferLength = sizeof(dvdbs);
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
94 #endif
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
95
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
96 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
97 * Common macro, win32 (ASPI) specific
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
98 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
99 #if defined( WIN32 )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
100 #define INIT_SSC( TYPE, SIZE ) \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
101 struct SRB_ExecSCSICmd ssc; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
102 u8 p_buffer[ (SIZE) ]; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
103 memset( &ssc, 0, sizeof( struct SRB_ExecSCSICmd ) ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
104 ssc.SRB_BufPointer = (char *)p_buffer; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
105 ssc.SRB_BufLen = (SIZE); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
106 WinInitSSC( &ssc, (TYPE) );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
107 #endif
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
108
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
109 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
110 * Common macro, QNX specific
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
111 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
112 #if defined( __QNXNTO__ )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
113 #define INIT_CPT( TYPE, SIZE ) \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
114 CAM_PASS_THRU * p_cpt; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
115 uint8_t * p_buffer; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
116 int structSize = sizeof( CAM_PASS_THRU ) + (SIZE); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
117 p_cpt = (CAM_PASS_THRU *) malloc ( structSize ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
118 p_buffer = (uint8_t *) p_cpt + sizeof( CAM_PASS_THRU ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
119 memset( p_cpt, 0, structSize ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
120 p_cpt->cam_data_ptr = sizeof( CAM_PASS_THRU ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
121 p_cpt->cam_dxfer_len = (SIZE); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
122 QNXInitCPT( p_cpt, (TYPE) );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
123 #endif
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
124
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
125 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
126 * Common macro, OS2 specific
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
127 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
128 #if defined( SYS_OS2 )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
129 #define INIT_SSC( TYPE, SIZE ) \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
130 struct OS2_ExecSCSICmd sdc; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
131 u8 p_buffer[ (SIZE) ]; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
132 unsigned long ulParamLen; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
133 unsigned long ulDataLen; \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
134 memset( &sdc, 0, sizeof( OS2_ExecSCSICmd ) ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
135 memset( &p_buffer, 0, SIZE ); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
136 sdc.data_length = (SIZE); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
137 ulParamLen = sizeof(sdc); \
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
138 OS2InitSDC( &sdc, (TYPE) )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
139 #endif
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
140
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
141 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
142 * Additional types, OpenBSD specific
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
143 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
144 #if defined( HAVE_OPENBSD_DVD_STRUCT )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
145 typedef union dvd_struct dvd_struct;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
146 typedef union dvd_authinfo dvd_authinfo;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
147 #endif
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
148
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
149 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
150 * Various DVD I/O tables
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
151 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
152 #if defined( SYS_BEOS ) || defined( WIN32 ) || defined ( SOLARIS_USCSI ) || defined ( HPUX_SCTL_IO ) || defined ( __QNXNTO__ ) || defined ( SYS_OS2 )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
153 /* The generic packet command opcodes for CD/DVD Logical Units,
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
154 * From Table 57 of the SFF8090 Ver. 3 (Mt. Fuji) draft standard. */
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
155 # define GPCMD_READ_DVD_STRUCTURE 0xad
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
156 # define GPCMD_REPORT_KEY 0xa4
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
157 # define GPCMD_SEND_KEY 0xa3
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
158 /* DVD struct types */
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
159 # define DVD_STRUCT_PHYSICAL 0x00
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
160 # define DVD_STRUCT_COPYRIGHT 0x01
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
161 # define DVD_STRUCT_DISCKEY 0x02
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
162 # define DVD_STRUCT_BCA 0x03
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
163 # define DVD_STRUCT_MANUFACT 0x04
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
164 /* Key formats */
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
165 # define DVD_REPORT_AGID 0x00
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
166 # define DVD_REPORT_CHALLENGE 0x01
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
167 # define DVD_SEND_CHALLENGE 0x01
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
168 # define DVD_REPORT_KEY1 0x02
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
169 # define DVD_SEND_KEY2 0x03
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
170 # define DVD_REPORT_TITLE_KEY 0x04
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
171 # define DVD_REPORT_ASF 0x05
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
172 # define DVD_SEND_RPC 0x06
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
173 # define DVD_REPORT_RPC 0x08
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
174 # define DVD_INVALIDATE_AGID 0x3f
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
175 #endif
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
176
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
177 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
178 * win32 ioctl specific
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
179 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
180 #if defined( WIN32 )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
181
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
182 #define WIN32_LEAN_AND_MEAN
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
183 #include <windows.h>
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
184
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
185 #define IOCTL_DVD_START_SESSION CTL_CODE(FILE_DEVICE_DVD, 0x0400, METHOD_BUFFERED, FILE_READ_ACCESS)
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
186 #define IOCTL_DVD_READ_KEY CTL_CODE(FILE_DEVICE_DVD, 0x0401, METHOD_BUFFERED, FILE_READ_ACCESS)
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
187 #define IOCTL_DVD_SEND_KEY CTL_CODE(FILE_DEVICE_DVD, 0x0402, METHOD_BUFFERED, FILE_READ_ACCESS)
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
188 #define IOCTL_DVD_END_SESSION CTL_CODE(FILE_DEVICE_DVD, 0x0403, METHOD_BUFFERED, FILE_READ_ACCESS)
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
189 #define IOCTL_DVD_GET_REGION CTL_CODE(FILE_DEVICE_DVD, 0x0405, METHOD_BUFFERED, FILE_READ_ACCESS)
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
190 #define IOCTL_DVD_SEND_KEY2 CTL_CODE(FILE_DEVICE_DVD, 0x0406, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
8637
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
191 #define IOCTL_DVD_READ_STRUCTURE CTL_CODE(FILE_DEVICE_DVD, 0x0450, METHOD_BUFFERED, FILE_READ_ACCESS)
7027
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
192 #define IOCTL_SCSI_PASS_THROUGH_DIRECT CTL_CODE(FILE_DEVICE_CONTROLLER, 0x0405, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
193
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
194 #define DVD_CHALLENGE_KEY_LENGTH (12 + sizeof(DVD_COPY_PROTECT_KEY))
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
195 #define DVD_BUS_KEY_LENGTH (8 + sizeof(DVD_COPY_PROTECT_KEY))
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
196 #define DVD_TITLE_KEY_LENGTH (8 + sizeof(DVD_COPY_PROTECT_KEY))
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
197 #define DVD_DISK_KEY_LENGTH (2048 + sizeof(DVD_COPY_PROTECT_KEY))
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
198 #define DVD_ASF_LENGTH (sizeof(DVD_ASF) + sizeof(DVD_COPY_PROTECT_KEY))
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
199 #define DVD_REGION_LENGTH (sizeof(DVD_REGION))
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
200
8637
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
201 #define DVD_COPYRIGHT_MASK 0x00000040
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
202 #define DVD_NOT_COPYRIGHTED 0x00000000
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
203 #define DVD_COPYRIGHTED 0x00000040
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
204
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
205 #define DVD_SECTOR_PROTECT_MASK 0x00000020
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
206 #define DVD_SECTOR_NOT_PROTECTED 0x00000000
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
207 #define DVD_SECTOR_PROTECTED 0x00000020
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
208
7027
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
209 #define SCSI_IOCTL_DATA_OUT 0
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
210 #define SCSI_IOCTL_DATA_IN 1
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
211
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
212 typedef ULONG DVD_SESSION_ID, *PDVD_SESSION_ID;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
213
8637
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
214 typedef enum DVD_STRUCTURE_FORMAT {
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
215 DvdPhysicalDescriptor,
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
216 DvdCopyrightDescriptor,
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
217 DvdDiskKeyDescriptor,
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
218 DvdBCADescriptor,
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
219 DvdManufacturerDescriptor,
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
220 DvdMaxDescriptor
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
221 } DVD_STRUCTURE_FORMAT, *PDVD_STRUCTURE_FORMAT;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
222
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
223 typedef struct DVD_READ_STRUCTURE {
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
224 LARGE_INTEGER BlockByteOffset;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
225 DVD_STRUCTURE_FORMAT Format;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
226 DVD_SESSION_ID SessionId;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
227 UCHAR LayerNumber;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
228 } DVD_READ_STRUCTURE, *PDVD_READ_STRUCTURE;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
229
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
230 typedef struct _DVD_COPYRIGHT_DESCRIPTOR {
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
231 UCHAR CopyrightProtectionType;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
232 UCHAR RegionManagementInformation;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
233 USHORT Reserved;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
234 } DVD_COPYRIGHT_DESCRIPTOR, *PDVD_COPYRIGHT_DESCRIPTOR;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
235
7027
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
236 typedef enum
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
237 {
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
238 DvdChallengeKey = 0x01,
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
239 DvdBusKey1,
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
240 DvdBusKey2,
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
241 DvdTitleKey,
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
242 DvdAsf,
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
243 DvdSetRpcKey = 0x6,
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
244 DvdGetRpcKey = 0x8,
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
245 DvdDiskKey = 0x80,
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
246 DvdInvalidateAGID = 0x3f
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
247 } DVD_KEY_TYPE;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
248
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
249 typedef struct _DVD_COPY_PROTECT_KEY
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
250 {
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
251 ULONG KeyLength;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
252 DVD_SESSION_ID SessionId;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
253 DVD_KEY_TYPE KeyType;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
254 ULONG KeyFlags;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
255 union
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
256 {
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
257 struct
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
258 {
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
259 ULONG FileHandle;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
260 ULONG Reserved; // used for NT alignment
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
261 };
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
262 LARGE_INTEGER TitleOffset;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
263 } Parameters;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
264 UCHAR KeyData[0];
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
265 } DVD_COPY_PROTECT_KEY, *PDVD_COPY_PROTECT_KEY;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
266
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
267 typedef struct _DVD_ASF
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
268 {
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
269 UCHAR Reserved0[3];
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
270 UCHAR SuccessFlag:1;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
271 UCHAR Reserved1:7;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
272 } DVD_ASF, * PDVD_ASF;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
273
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
274 typedef struct _DVD_REGION {
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
275 UCHAR CopySystem;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
276 UCHAR RegionData;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
277 UCHAR SystemRegion;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
278 UCHAR ResetCount;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
279 } DVD_REGION, *PDVD_REGION;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
280
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
281 typedef struct _SCSI_PASS_THROUGH_DIRECT
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
282 {
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
283 USHORT Length;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
284 UCHAR ScsiStatus;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
285 UCHAR PathId;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
286 UCHAR TargetId;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
287 UCHAR Lun;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
288 UCHAR CdbLength;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
289 UCHAR SenseInfoLength;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
290 UCHAR DataIn;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
291 ULONG DataTransferLength;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
292 ULONG TimeOutValue;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
293 PVOID DataBuffer;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
294 ULONG SenseInfoOffset;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
295 UCHAR Cdb[16];
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
296 } SCSI_PASS_THROUGH_DIRECT, *PSCSI_PASS_THROUGH_DIRECT;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
297
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
298 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
299 * win32 aspi specific
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
300 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
301
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
302 #define WIN2K ( GetVersion() < 0x80000000 )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
303 #define ASPI_HAID 0
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
304 #define ASPI_TARGET 0
8637
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
305 #define DTYPE_CDROM 0x05
7027
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
306
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
307 #define SENSE_LEN 0x0E
8637
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
308 #define SC_GET_DEV_TYPE 0x01
7027
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
309 #define SC_EXEC_SCSI_CMD 0x02
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
310 #define SC_GET_DISK_INFO 0x06
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
311 #define SS_COMP 0x01
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
312 #define SS_PENDING 0x00
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
313 #define SS_NO_ADAPTERS 0xE8
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
314 #define SRB_DIR_IN 0x08
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
315 #define SRB_DIR_OUT 0x10
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
316 #define SRB_EVENT_NOTIFY 0x40
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
317
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
318 struct w32_aspidev
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
319 {
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
320 long hASPI;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
321 short i_sid;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
322 int i_blocks;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
323 long (*lpSendCommand)( void* );
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
324 };
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
325
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
326 #pragma pack(1)
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
327
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
328 struct SRB_GetDiskInfo
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
329 {
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
330 unsigned char SRB_Cmd;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
331 unsigned char SRB_Status;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
332 unsigned char SRB_HaId;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
333 unsigned char SRB_Flags;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
334 unsigned long SRB_Hdr_Rsvd;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
335 unsigned char SRB_Target;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
336 unsigned char SRB_Lun;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
337 unsigned char SRB_DriveFlags;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
338 unsigned char SRB_Int13HDriveInfo;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
339 unsigned char SRB_Heads;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
340 unsigned char SRB_Sectors;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
341 unsigned char SRB_Rsvd1[22];
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
342 };
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
343
8637
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
344 struct SRB_GDEVBlock
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
345 {
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
346 unsigned char SRB_Cmd;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
347 unsigned char SRB_Status;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
348 unsigned char SRB_HaId;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
349 unsigned char SRB_Flags;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
350 unsigned long SRB_Hdr_Rsvd;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
351 unsigned char SRB_Target;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
352 unsigned char SRB_Lun;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
353 unsigned char SRB_DeviceType;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
354 unsigned char SRB_Rsvd1;
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
355 };
0211de3039eb update libdvdcss in libmpdvdkit to latest version (1.2.4)
arpi
parents: 7027
diff changeset
356
7027
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
357 struct SRB_ExecSCSICmd
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
358 {
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
359 unsigned char SRB_Cmd;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
360 unsigned char SRB_Status;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
361 unsigned char SRB_HaId;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
362 unsigned char SRB_Flags;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
363 unsigned long SRB_Hdr_Rsvd;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
364 unsigned char SRB_Target;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
365 unsigned char SRB_Lun;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
366 unsigned short SRB_Rsvd1;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
367 unsigned long SRB_BufLen;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
368 unsigned char *SRB_BufPointer;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
369 unsigned char SRB_SenseLen;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
370 unsigned char SRB_CDBLen;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
371 unsigned char SRB_HaStat;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
372 unsigned char SRB_TargStat;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
373 unsigned long *SRB_PostProc;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
374 unsigned char SRB_Rsvd2[20];
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
375 unsigned char CDBByte[16];
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
376 unsigned char SenseArea[SENSE_LEN+2];
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
377 };
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
378
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
379 #pragma pack()
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
380
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
381 #endif
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
382
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
383 /*****************************************************************************
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
384 * OS2 ioctl specific
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
385 *****************************************************************************/
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
386 #if defined( SYS_OS2 )
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
387
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
388 #define CDROMDISK_EXECMD 0x7A
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
389
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
390 #define EX_DIRECTION_IN 0x01
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
391 #define EX_PLAYING_CHK 0x02
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
392
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
393 #pragma pack(1)
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
394
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
395 struct OS2_ExecSCSICmd
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
396 {
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
397 unsigned long id_code; // 'CD01'
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
398 unsigned short data_length; // length of the Data Packet
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
399 unsigned short cmd_length; // length of the Command Buffer
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
400 unsigned short flags; // flags
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
401 unsigned char command[16]; // Command Buffer for SCSI command
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
402
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
403 } OS2_ExecSCSICmd;
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
404
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
405 #pragma pack()
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
406
c9a4dfaa9868 importing libdvdcss 1.2.2 files
arpi
parents:
diff changeset
407 #endif