148 |
typedef uint64_t file_offset_t; |
typedef uint64_t file_offset_t; |
149 |
|
|
150 |
/** Whether file stream is open in read or in read/write mode. */ |
/** Whether file stream is open in read or in read/write mode. */ |
151 |
typedef enum { |
enum stream_mode_t { |
152 |
stream_mode_read = 0, |
stream_mode_read = 0, |
153 |
stream_mode_read_write = 1, |
stream_mode_read_write = 1, |
154 |
stream_mode_closed = 2 |
stream_mode_closed = 2 |
155 |
} stream_mode_t; |
}; |
156 |
|
|
157 |
/** Current state of the file stream. */ |
/** Current state of the file stream. */ |
158 |
typedef enum { |
enum stream_state_t { |
159 |
stream_ready = 0, |
stream_ready = 0, |
160 |
stream_end_reached = 1, |
stream_end_reached = 1, |
161 |
stream_closed = 2 |
stream_closed = 2 |
162 |
} stream_state_t; |
}; |
163 |
|
|
164 |
/** File stream position dependent to these relations. */ |
/** File stream position dependent to these relations. */ |
165 |
typedef enum { |
enum stream_whence_t { |
166 |
stream_start = 0, |
stream_start = 0, |
167 |
stream_curpos = 1, |
stream_curpos = 1, |
168 |
stream_backward = 2, |
stream_backward = 2, |
169 |
stream_end = 3 |
stream_end = 3 |
170 |
} stream_whence_t; |
}; |
171 |
|
|
172 |
/** Alignment of data bytes in memory (system dependant). */ |
/** Alignment of data bytes in memory (system dependant). */ |
173 |
typedef enum { |
enum endian_t { |
174 |
endian_little = 0, |
endian_little = 0, |
175 |
endian_big = 1, |
endian_big = 1, |
176 |
endian_native = 2 |
endian_native = 2 |
177 |
} endian_t; |
}; |
178 |
|
|
179 |
/** General RIFF chunk structure of a RIFF file. */ |
/** General RIFF chunk structure of a RIFF file. */ |
180 |
enum layout_t { |
enum layout_t { |