-\r
-void\r
-DrawPBuf(page_t *page, int x, int y, planar_buf_t *p, byte sprite)\r
-{\r
- word plane;\r
- int px, py, i;\r
-// word offset = (word) page->data;\r
-\r
- px=x;\r
- py=y;\r
- // TODO Make this fast. It's SLOOOOOOW\r
-// for(plane=0; plane < 4; plane++) {\r
-// i=0;\r
-// modexSelectPlane(PLANE(plane+x));\r
-// for(px = plane; px < p->width; px+=4) {\r
-// offset=px;\r
-// for(py=0; py<p->height/2; py++) {\r
-// //SELECT_ALL_PLANES();\r
-// if(!sprite || p->plane[offset])\r
-// page->data = &(p->plane[offset][i++]);\r
-// offset+=p->width;\r
-// offset++;\r
-// }\r
-// }\r
-// }\r
-// z=0;\r
- for(plane=0; plane < 4; plane++) {\r
- //modexputPixel(page, 120, 90+z, z+1);\r
- //z++;\r
- i=0;\r
- modexSelectPlane(PLANE(plane+x));\r
- //modexSelectPlane(plane);\r
- for(; y < p->height; y++) {\r
- //for(px=0; px < p->width; px++) {\r
- //printf("%02X ", (int) p->plane[plane][i++]);\r
- strncpy(page->data + (((page->width/4) * (y+page->dy)) + ((x+page->dx) / 4))\r
-,&(p->plane[plane][i+=p->pwidth]), p->pwidth);\r
- //}\r
- }\r
- //getch();\r
- x=px;\r
- y=py;\r
- }\r
-}\r