Module Name:    xsrc
Committed By:   macallan
Date:           Thu Sep 10 21:20:19 UTC 2009

Modified Files:
        xsrc/external/mit/xf86-video-sunleo/dist/src: leo_accel.c leo_driver.c

Log Message:
first steps to make this driver actually work:
- accept 24bit colour, not just 32 ( this changed ages ago - didn't anyone
  test this driver on actual hardware? )
- fix colour weights
- use the right WID so we actually see what we draw
TODO:
- figure out why output is greyscale from the red channel only
- add actual acceleration


To generate a diff of this commit:
cvs rdiff -u -r1.1.1.1 -r1.2 \
    xsrc/external/mit/xf86-video-sunleo/dist/src/leo_accel.c \
    xsrc/external/mit/xf86-video-sunleo/dist/src/leo_driver.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: xsrc/external/mit/xf86-video-sunleo/dist/src/leo_accel.c
diff -u xsrc/external/mit/xf86-video-sunleo/dist/src/leo_accel.c:1.1.1.1 xsrc/external/mit/xf86-video-sunleo/dist/src/leo_accel.c:1.2
--- xsrc/external/mit/xf86-video-sunleo/dist/src/leo_accel.c:1.1.1.1	Fri Sep  4 20:12:48 2009
+++ xsrc/external/mit/xf86-video-sunleo/dist/src/leo_accel.c	Thu Sep 10 21:20:19 2009
@@ -118,10 +118,10 @@
 	/* We will now clear the screen: we'll draw a rectangle covering all the
 	 * viewscreen, using a 'blackness' ROP.
 	 */
-	ld0->wid = 1;
+	ld0->wid = 0x10;
 	ld0->widclip = 0;
 	ld0->wmask = 0xffff;
-	ld0->planemask = 0xffffff;
+	ld0->planemask = 0x00ffffff;
 	ld0->rop = LEO_ATTR_WE_ENABLE|LEO_ATTR_RGBE_ENABLE|LEO_ATTR_FORCE_WID;
 	ld0->fg = 0;
 	ld0->vclipmin = 0;
@@ -138,7 +138,7 @@
 	while (lc0->csr & LEO_CSR_BLT_BUSY);
 	
 	lc0->addrspace = LEO_ADDRSPC_OBGR;
-	ld0->rop = LEO_ATTR_RGBE_ENABLE|LEO_ROP_NEW;
+	ld0->rop = LEO_ATTR_RGBE_ENABLE|LEO_ROP_NEW|LEO_ATTR_FORCE_WID;
 
 	/* Success */
 	return TRUE;
Index: xsrc/external/mit/xf86-video-sunleo/dist/src/leo_driver.c
diff -u xsrc/external/mit/xf86-video-sunleo/dist/src/leo_driver.c:1.1.1.1 xsrc/external/mit/xf86-video-sunleo/dist/src/leo_driver.c:1.2
--- xsrc/external/mit/xf86-video-sunleo/dist/src/leo_driver.c:1.1.1.1	Fri Sep  4 20:12:48 2009
+++ xsrc/external/mit/xf86-video-sunleo/dist/src/leo_driver.c	Thu Sep 10 21:20:19 2009
@@ -1,4 +1,3 @@
-
 /*
  * Leo (ZX) framebuffer driver.
  *
@@ -339,6 +338,7 @@
 	/* Check that the returned depth is one we support */
 	switch (pScrn->depth) {
 	case 32:
+	case 24:
 	    /* OK */
 	    break;
 	default:
@@ -362,7 +362,7 @@
      * xf86SetWeight references it.
      */
     if (pScrn->depth > 8) {
-	rgb weight = {10, 11, 11};
+	rgb weight = {0, 0, 0};
 	rgb mask = {0xff, 0xff00, 0xff0000};
 
 	if (!xf86SetWeight(pScrn, weight, mask)) {

Reply via email to