#ifndef __GFX_H_INCLUDED__
#define __GFX_H_INCLUDED__

/* includes */
#include <stdio.h>
#include <stdlib.h>
#include <dos.h>
#include <sys/nearptr.h>
#include <sys/farptr.h>
#include <go32.h>
#include <time.h>

/********************************************************* GLOBALS *********/

extern char *scrptr;                      //pointer to screen data for the
                                          //FAST screen write/read

typedef struct                          //for to load the palette...
{
        unsigned char red, green, blue;
} pal;

extern pal palette[256];                       // ... and for to set it!

extern char screenbuffer[64000];               //this is for my buffer
extern int graphicsmode;

extern union REGS r;                           //how am I supposed to twiddle
                                        //any frobs without this? :)
/* gfx.c */
void initraw();
void setpalette(pal *palptr);
void set320x200(void);
void settextmode(void);
inline void setpixel(long x, long y, char col);
inline void setbpixel(long x, long y, char col);
inline void buffertoscreen(void);
void loadpal(char *filen);
void blitchar(char c, int x, int y);
void blitstr(char *s,int x, int y);
void melt();

#endif
