mirror of
https://github.com/nzp-team/fteqw.git
synced 2024-11-10 22:51:57 +00:00
503eff6421
I'm not sure if this will break anything. It shouldn't do, but it might. Not everything is ported over yet. Ideally there would be no more use of fopen anywhere else in the engine, and com_gamedir would be made static to fs.c There are a couple of other changes too. http/ftp stuff is currently disabled. git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@1728 fc73d0e0-1445-4013-8a0c-d673dee63da5
50 lines
1.2 KiB
C
50 lines
1.2 KiB
C
#ifndef _av_roq_h
|
|
#define _av_roq_h
|
|
|
|
#define RoQ_INFO 0x1001
|
|
#define RoQ_QUAD_CODEBOOK 0x1002
|
|
#define RoQ_QUAD_VQ 0x1011
|
|
#define RoQ_SOUND_MONO 0x1020
|
|
#define RoQ_SOUND_STEREO 0x1021
|
|
|
|
#define RoQ_ID_MOT 0x00
|
|
#define RoQ_ID_FCC 0x01
|
|
#define RoQ_ID_SLD 0x02
|
|
#define RoQ_ID_CCC 0x03
|
|
|
|
typedef struct {
|
|
unsigned char y0, y1, y2, y3, u, v;
|
|
} roq_cell;
|
|
|
|
typedef struct {
|
|
int idx[4];
|
|
} roq_qcell;
|
|
|
|
typedef struct {
|
|
vfsfile_t *fp;
|
|
unsigned int maxpos; //addition for pack files. all seeks add this, all tells subtract this.
|
|
int buf_size;
|
|
unsigned char *buf;
|
|
roq_cell cells[256];
|
|
roq_qcell qcells[256];
|
|
short snd_sqr_arr[256];
|
|
long roq_start, aud_pos, vid_pos;
|
|
long *frame_offset;
|
|
unsigned long num_frames, num_audio_bytes;
|
|
int width, height, frame_num, audio_channels;
|
|
unsigned char *y[2], *u[2], *v[2];
|
|
long stream_length;
|
|
int audio_buf_size, audio_size;
|
|
unsigned char *audio;
|
|
} roq_info;
|
|
|
|
/* -------------------------------------------------------------------------- */
|
|
void roq_init(void);
|
|
void roq_cleanup(void);
|
|
roq_info *roq_open(char *fname);
|
|
void roq_close(roq_info *ri);
|
|
int roq_read_frame(roq_info *ri);
|
|
int roq_read_audio(roq_info *ri);
|
|
|
|
#endif
|
|
|