]> icculus.org git repositories - taylor/freespace2.git/blob - include/cfilearchive.h
fix issue with looping audio streams
[taylor/freespace2.git] / include / cfilearchive.h
1 /*
2  * Copyright (C) Volition, Inc. 1999.  All rights reserved.
3  *
4  * All source code herein is the property of Volition, Inc. You may not sell 
5  * or otherwise commercially exploit the source or things you created based on
6  * the source.
7  */
8
9 /*
10  * $Logfile: /Freespace2/code/CFile/CfileArchive.h $
11  * $Revision$
12  * $Date$
13  * $Author$
14  *
15  * External def's for CfileArchive.cpp.  This should only be used 
16  * internally by cfile stuff.
17  *
18  * $Log$
19  * Revision 1.2  2002/06/09 04:41:12  relnev
20  * added copyright header
21  *
22  * Revision 1.1.1.1  2002/05/03 03:28:11  root
23  * Initial import.
24  *
25  * 
26  * 2     10/07/98 10:52a Dave
27  * Initial checkin.
28  * 
29  * 1     10/07/98 10:48a Dave
30  * 
31  * 4     5/11/98 10:59a John
32  * Moved the low-level file reading code into cfilearchive.cpp.
33  * 
34  * 3     4/30/98 4:53p John
35  * Restructured and cleaned up cfile code.  Added capability to read off
36  * of CD-ROM drive and out of multiple pack files.
37  * 
38  * 2     12/28/97 12:42p John
39  * Put in support for reading archive files; Made missionload use the
40  * cf_get_file_list function.   Moved demos directory out of data tree.
41  * 
42  * 1     12/28/97 11:48a John
43  *
44  * $NoKeywords: $
45  */
46
47 #ifndef _CFILEARCHIVE_H
48 #define _CFILEARCHIVE_H
49
50 #ifndef _CFILE_INTERNAL 
51 #error This file should only be included internally in CFILE!!
52 #endif
53
54 // The following Cfile_block data is private to cfile.cpp
55 // DO NOT MOVE the Cfile_block* information to cfile.h / do not extern this data
56 //
57 #define CFILE_BLOCK_UNUSED              0
58 #define CFILE_BLOCK_USED                1
59
60 typedef struct Cfile_block {
61         int             type;                           // CFILE_BLOCK_UNUSED, CFILE_BLOCK_USED
62         int             dir_type;               // directory location
63         FILE            *fp;                            // File pointer if opening an individual file
64         int             lib_offset;
65         int             raw_position;
66         int             size;                           // for packed files
67         
68 } Cfile_block;
69
70 #define MAX_CFILE_BLOCKS        64
71 extern Cfile_block Cfile_block_list[MAX_CFILE_BLOCKS];
72 extern CFILE Cfile_list[MAX_CFILE_BLOCKS];
73
74 // Called once to setup the low-level reading code.
75 void cf_init_lowlevel_read_code( CFILE * cfile, int offset, int size );
76
77 #endif
78