Main Page | Modules | Alphabetical List | Data Structures | File List | Data Fields | Globals

agl_ios.h

Go to the documentation of this file.
00001 00002 /* 00003 ______ __ ___ __ 00004 /\ _ \ /\ \ /\_ \ /\_\ 00005 \ \ \_\ \ \ \ \ __ ___ \//\ \ \/_/_ 00006 \ \ __ \ `/__ \ /'__`\ / __`\ \ \ \ /\ \ 00007 \ \ \/\ \/\\_\ \_/\ \_\ \/\ \_\ \_ \_\ \_ \_\ \_ 00008 \ \_\ \_\ \_____\ \___\ \ \______\/\____\/\____\ 00009 \/_/\/_/\/_____/\/___L\ \/______/\/____/\/____/ 00010 /\____/ 00011 \_/__/ 00012 00013 00014 00015 00016 An advanced game library 00017 00018 (c) Stephane APIOU 2003 00019 00020 00021 This program is free software; you can redistribute it and/or modify 00022 it under the terms of the GNU General Public License as published by 00023 the Free Software Foundation; either version 2 of the License, or 00024 (at your option) any later version. 00025 00026 This program is distributed in the hope that it will be useful, 00027 but WITHOUT ANY WARRANTY; without even the implied warranty of 00028 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00029 GNU General Public License for more details. 00030 00031 You should have received a copy of the GNU General Public License 00032 along with this program; if not, write to the Free Software 00033 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00034 00035 00036 00037 */ 00038 00040 00049 #ifndef _adgali_ios_h 00050 #define _adgali_ios_h 00051 00052 #include <stdio.h> 00053 00055 00056 struct _agl_iosio; 00057 00059 00063 typedef struct agl_ios 00064 { 00065 agl_handle handle; 00066 struct _agl_iosio *pio; 00067 char *filename; 00068 void *priv; 00069 } agl_ios; 00070 00071 typedef struct _agl_iosio 00072 { 00073 char *desc; 00074 int (*is) (agl_module *, char *, agl_ios *); 00075 agl_ios *(*open) (agl_module *, char *, agl_ios *); 00076 long (*seek) (agl_ios *, long, int); 00077 long (*read) (agl_ios *, void *, long, long, void *); 00078 long (*write) (agl_ios *, void *, long, long, void *); 00079 int (*close) (agl_ios *); 00080 } agl_iosio; 00081 00082 00083 extern agl_ios *agl_ios_open(agl_handle handle, char *address); 00084 00086 00099 #define agl_ios_seek(ios, offset, whence) ((ios)->pio->seek(ios, offset, whence)) 00100 00102 00108 #define agl_ios_tell(ios) ((ios)->pio->seek(ios, 0, SEEK_CUR)) 00109 00111 00122 #define agl_ios_read(ios, buf, size, maxnum, supp) ((ios)->pio->read(ios, buf, size, maxnum ,supp)) 00123 00125 00136 #define agl_ios_write(ios, buf, size, maxnum, supp) ((ios)->pio->write(ios, buf, size, maxnum ,supp)) 00137 00139 00146 #define agl_ios_close(ios) ((ios)->pio->close(ios)) 00147 00148 00149 #endif /* _agl_ios_h */

Doc generated at 29 Sep 2004 for, adgali 0.2.4 written by Stephane APIOU, © 2001 Generated by Doxygen 1.3.8 ,