changeset 2914:1ccec8cd9310

Screen clearing instead of stupid BIOSes
author nick
date Thu, 15 Nov 2001 16:45:26 +0000
parents 74731185c5c9
children 80954dfeabed
files libvo/vo_vesa.c
diffstat 1 files changed, 13 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libvo/vo_vesa.c	Thu Nov 15 16:44:43 2001 +0000
+++ b/libvo/vo_vesa.c	Thu Nov 15 16:45:26 2001 +0000
@@ -457,6 +457,17 @@
     }
 }
 
+static void clear_screen( void )
+{
+    int x_res = video_mode_info.XResolution;
+    int y_res = video_mode_info.YResolution;
+    int x, y;
+
+    for (y = 0; y < y_res; ++y)
+	for (x = 0; x < x_res; ++x)
+	    __vbeSetPixel(x, y, 0, 0, 0);
+}
+
 static char *model2str(unsigned char type)
 {
   char *retval;
@@ -854,6 +865,8 @@
 	  printf("vo_vesa: VESA initialization complete\n");
 	  fflush(stdout);
 	}
+	/* Clear screen for stupid BIOSes */
+	clear_screen();
 	if(HAS_DGA() && vo_doublebuffering)
 	{
 	    for(i=0;i<MAX_BUFFERS;i++)