mirror of
https://github.com/vivier/EMILE.git
synced 2024-10-10 16:23:42 +00:00
correct clear function
This commit is contained in:
parent
76c643fe44
commit
49fe95e510
@ -288,7 +288,6 @@ vga_init()
|
|||||||
&vga.height,
|
&vga.height,
|
||||||
&vga.depth,
|
&vga.depth,
|
||||||
(unsigned long*)&vga.video);
|
(unsigned long*)&vga.video);
|
||||||
|
|
||||||
vga.pos_x = 0;
|
vga.pos_x = 0;
|
||||||
vga.pos_y = 0;
|
vga.pos_y = 0;
|
||||||
vga.siz_w = vga.width / 8;
|
vga.siz_w = vga.width / 8;
|
||||||
@ -327,7 +326,7 @@ vga_clear()
|
|||||||
int i,j;
|
int i,j;
|
||||||
unsigned char bg;
|
unsigned char bg;
|
||||||
unsigned long bg32;
|
unsigned long bg32;
|
||||||
unsigned long *base = (unsigned long*)vga.base;
|
unsigned long *base;
|
||||||
unsigned char *next;
|
unsigned char *next;
|
||||||
|
|
||||||
if (vga.depth <= 8)
|
if (vga.depth <= 8)
|
||||||
@ -343,6 +342,8 @@ vga_clear()
|
|||||||
|
|
||||||
for (j = 0; j < vga.height; j++)
|
for (j = 0; j < vga.height; j++)
|
||||||
{
|
{
|
||||||
|
base = (unsigned long*)(vga.base + vga.row_bytes * j);
|
||||||
|
|
||||||
for (i = 0; i < (vga.row_bytes >> 2); i++)
|
for (i = 0; i < (vga.row_bytes >> 2); i++)
|
||||||
*base++ = bg32;
|
*base++ = bg32;
|
||||||
next = (unsigned char*)base;
|
next = (unsigned char*)base;
|
||||||
|
Loading…
Reference in New Issue
Block a user