X-Git-Url: http://4ch.mooo.com/gitweb/?a=blobdiff_plain;f=src%2Ftest2.c;h=2f76a02e48a57f46b8193bc1e5cb1434594c6731;hb=11c259b8eefaa17c296f661da98d042162e5c57d;hp=5b3d32c0c962afe65d9857a1fb2c8751d7719d74;hpb=f66b2c6a16e6f6c2c9c07a39d1855b5ea178fead;p=16.git diff --git a/src/test2.c b/src/test2.c index 5b3d32c0..2f76a02e 100644 --- a/src/test2.c +++ b/src/test2.c @@ -1,19 +1,61 @@ -#include "src\lib\modex16.h" +#include +#include +#include "src/lib/modex16.h" +#include "src/lib/planar.h" +//#include "src/lib/bitmap.h" -word far* clock= (word far*) 0x046C; /* 18.2hz clock */ +word far* clockw= (word far*) 0x046C; /* 18.2hz clock */ -void main() { +void main() { + FILE *file; + bitmap_t bmp; + planar_buf_t *p; + word size; int i; - word start; - page_t page; + int plane; + int x,y; + //byte color; - page=modexDefaultPage(); + /* get the size we want */ + /*printf("Width: "); + scanf("%d", &bmp.width); + printf("Height: "); + scanf("%d", &bmp.height); + printf("Color: "); + scanf("%x", &color);*/ - modexEnter(); - start = *clock; - for(i=0; i<500; i++) { - modexShowPage(&page); - } - modexLeave(); + /* allocate the bmp and fill it with 42 */ + /*size = bmp.width * bmp.height; + bmp.data = malloc(size); + for(i=0; iheight; y++) { + for(x=0; x < p->pwidth; x++) { + printf("%02X ", (int) p->plane[plane][i++]); + } + printf("\n"); + } + } + /*__asm + { + mov ah,31h + int 21h + }*/ + +// file = fopen("ptmp0.pcx", "wb"); + + /* write the data to the file */ + //fwrite(p, 1, p->width*p->height, file); + //fclose(file); }