home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C++ Games Programming
/
CPPGAMES.ISO
/
thx
/
include
/
viddir.h
< prev
next >
Wrap
C/C++ Source or Header
|
1995-05-08
|
2KB
|
65 lines
// ---------- viddir.h
#ifndef VIDDIR_H
#define VIDDIR_H
#include "director.h"
#include "settings.h"
const int BUFFERPAGE = 2;
struct FlicHdr {
long int size;
char signature[2];
short int frames;
short int width;
short int height;
short int bitspixel;
short int reserved;
long int delay;
char filler2[108];
};
struct patch_struct {
int x1,y1,x2,y2;
};
class VideoDirector : public Director {
static int vpage;
static patch_struct patch[NUMPATCHES];
static int patchcount;
static int flicplaying;
static int flicframes;
static int flicnonstop;
static int delay;
static int first;
static char flic_context[16];
static FlicHdr flic_header;
void on_hs(int);
protected:
VideoDirector();
virtual ~VideoDirector();
void init_video();
void fill_background_buffer(int frompage);
void restore_page();
virtual void iterate_director();
virtual void on_s(int = 0);
public:
static void swap_video_pages();
static void synch_video_pages();
static void synch_patch(int,int,int,int);
static int set_synch_patch(int x1,int y1,int x2,int y2);
static int synch_patches(int frvpage = 1);
static void restore_patch(int x1,int y1,int x2,int y2);
static void flush_patch(int x1,int y1,int x2,int y2);
static int show_pcx(char* fname);
static void show_video(char* fname,int x,int y,int nonstop=0);
static void stop_video();
static int video_playing() { return flicplaying; }
static int active_page() { return 1-vpage; }
static int visual_page() { return vpage; }
static int install_palette(char*);
};
#endif