#include <go32.h>
#include <conio.h>
#include <stdio.h>
#include <sys/movedata.h>
#include <dos.h>
#include "palette.h"
#include "pcx.h"
#define flip(c) _dosmemputl(c, 64000/4, 0xA0000)
void main() {
char palette[256*3];
char dblbuf[64000];
textmode(0x13);
loadpcx("PICTURE.PCX", dblbuf);
loadpal("PICTURE.PCX", palette);
setpal(palette);
flip(dblbuf);
getch();
fadetoblack(palette);
textmode(0x3);
}