summaryrefslogtreecommitdiff
path: root/src/drivers/video/vga.c
diff options
context:
space:
mode:
authorAndreas Baumann <mail@andreasbaumann.cc>2017-06-15 21:42:55 +0200
committerAndreas Baumann <mail@andreasbaumann.cc>2017-06-15 21:42:55 +0200
commit7a2e9a06e2d57b738361419d131ed9ace9333c24 (patch)
tree3377b4794ecb4b70817b98a6a5348f5ad6b9c6c2 /src/drivers/video/vga.c
parentab7e3f0739d11c4294cf331a07328d6d5aeb5a68 (diff)
downloadabaos-7a2e9a06e2d57b738361419d131ed9ace9333c24.tar.gz
abaos-7a2e9a06e2d57b738361419d131ed9ace9333c24.tar.bz2
added a clear screen method to graphics mode VGA driver
Diffstat (limited to 'src/drivers/video/vga.c')
-rw-r--r--src/drivers/video/vga.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/drivers/video/vga.c b/src/drivers/video/vga.c
index 83b3578..c385bea 100644
--- a/src/drivers/video/vga.c
+++ b/src/drivers/video/vga.c
@@ -262,7 +262,10 @@ void vga_draw_rectangle( vga_t *vga, const int x, const int y, const int w, cons
vga_set_pixel( vga, xx, yy, color );
}
}
-// memset( vga->mode.segment, get_color_index( color ),
-// vga->mode.x * vga->mode.y );
}
+void vga_clear_screen( vga_t *vga, const vga_color_t color )
+{
+ memset( vga->mode.segment, get_color_index( color ),
+ vga->mode.x * vga->mode.y );
+}