rm unused function prototypes
[libogc.git] / gc / ogc / disc_io.h
blob0a6ef3e5a401b488788bc480e506f70eb7963eea
1 /*
2 disc_io.h
3 Interface template for low level disc functions.
5 Copyright (c) 2006 Michael "Chishm" Chisholm
6 Based on code originally written by MightyMax
8 Redistribution and use in source and binary forms, with or without modification,
9 are permitted provided that the following conditions are met:
11 1. Redistributions of source code must retain the above copyright notice,
12 this list of conditions and the following disclaimer.
13 2. Redistributions in binary form must reproduce the above copyright notice,
14 this list of conditions and the following disclaimer in the documentation and/or
15 other materials provided with the distribution.
16 3. The name of the author may not be used to endorse or promote products derived
17 from this software without specific prior written permission.
19 THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
20 WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
21 AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE
22 LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
23 DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
24 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
27 EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 #ifndef OGC_DISC_IO_INCLUDE
31 #define OGC_DISC_IO_INCLUDE
33 #include <stdint.h>
34 #include <gctypes.h>
37 #define FEATURE_MEDIUM_CANREAD 0x00000001
38 #define FEATURE_MEDIUM_CANWRITE 0x00000002
39 #define FEATURE_GAMECUBE_SLOTA 0x00000010
40 #define FEATURE_GAMECUBE_SLOTB 0x00000020
41 #define FEATURE_GAMECUBE_DVD 0x00000040
42 #define FEATURE_WII_SD 0x00000100
43 #define FEATURE_WII_USB 0x00000200
44 #define FEATURE_WII_DVD 0x00000400
46 typedef uint32_t sec_t;
48 typedef bool (* FN_MEDIUM_STARTUP)(void) ;
49 typedef bool (* FN_MEDIUM_ISINSERTED)(void) ;
50 typedef bool (* FN_MEDIUM_READSECTORS)(sec_t sector, sec_t numSectors, void* buffer) ;
51 typedef bool (* FN_MEDIUM_WRITESECTORS)(sec_t sector, sec_t numSectors, const void* buffer) ;
52 typedef bool (* FN_MEDIUM_CLEARSTATUS)(void) ;
53 typedef bool (* FN_MEDIUM_SHUTDOWN)(void) ;
55 struct DISC_INTERFACE_STRUCT {
56 unsigned long ioType ;
57 unsigned long features ;
58 FN_MEDIUM_STARTUP startup ;
59 FN_MEDIUM_ISINSERTED isInserted ;
60 FN_MEDIUM_READSECTORS readSectors ;
61 FN_MEDIUM_WRITESECTORS writeSectors ;
62 FN_MEDIUM_CLEARSTATUS clearStatus ;
63 FN_MEDIUM_SHUTDOWN shutdown ;
64 } ;
66 typedef struct DISC_INTERFACE_STRUCT DISC_INTERFACE ;
68 #endif // define OGC_DISC_IO_INCLUDE