Index: trunk/i386/boot2/graphics.c =================================================================== --- trunk/i386/boot2/graphics.c (revision 2737) +++ trunk/i386/boot2/graphics.c (revision 2738) @@ -397,7 +397,7 @@ //========================================================================== // Simple decompressor for boot images encoded in RLE format. -char * decodeRLE( const void * rleData, int rleBlocks, int outBytes ) +char *decodeRLE( const void *rleData, int rleBlocks, int outBytes ) { char *out, *cp; @@ -859,14 +859,17 @@ unsigned short y, unsigned short width, unsigned short height, - unsigned char * data ) + unsigned char *data ) { unsigned short drawWidth; + long pixelBytes = VIDEO(depth) / 8; + unsigned char * vram = (unsigned char *) VIDEO(baseAddr) + VIDEO(rowBytes) * y + pixelBytes * x; drawWidth = MIN(width, VIDEO(width) - x); height = MIN(height, VIDEO(height) - y); + while ( height-- ) { bcopy( data, vram, drawWidth * pixelBytes ); @@ -927,12 +930,12 @@ void drawPreview(void *src, uint8_t * saveunder) { - uint8_t * screen; + uint8_t *screen; uint32_t rowBytes, pixelShift; uint32_t x, y; int32_t blob; uint32_t alpha, in, color, result; - uint8_t * out; + uint8_t *out; void *uncomp; int origwidth, origheight, origbpx; uint32_t saveindex[kIOHibernateProgressCount] = { 0 }; Index: trunk/i386/boot2/gui.c =================================================================== --- trunk/i386/boot2/gui.c (revision 2737) +++ trunk/i386/boot2/gui.c (revision 2738) @@ -1303,8 +1303,7 @@ // ==================================================================== -static inline -void vramwrite (void *data, int width, int height) +static inline void vramwrite (void *data, int width, int height) { if (VIDEO (depth) == 32 && VIDEO (rowBytes) == gui.backbuffer->width * 4) { @@ -1384,14 +1383,13 @@ struct putc_info //Azi: exists on console.c & printf.c { - char * str; - char * last_str; + char *str; + char *last_str; }; // ==================================================================== -static int -sputc(int c, struct putc_info * pi) //Azi: same as above +static int sputc(int c, struct putc_info * pi) //Azi: same as above { if (pi->last_str) { @@ -2294,9 +2292,9 @@ // ==================================================================== -uint16_t bootImageWidth = 0; -uint16_t bootImageHeight = 0; -uint8_t *bootImageData = NULL; +uint16_t bootImageWidth = 0; +uint16_t bootImageHeight = 0; +uint8_t *bootImageData = NULL; static bool usePngImage = true; //========================================================================== @@ -2331,10 +2329,12 @@ int length; const char *dummyVal; int oldScreenWidth, oldScreenHeight; - bool legacy_logo; - uint16_t x, y; - - if (getBoolForKey("Legacy Logo", &legacy_logo, &bootInfo->chameleonConfig) && legacy_logo) + bool legacy_logo = true; // ErmaC: Legacy Logo is enabled by default + uint16_t x, y; + + getBoolForKey("Legacy Logo", &legacy_logo, &bootInfo->chameleonConfig); + + if ( legacy_logo ) { usePngImage = false; } @@ -2398,25 +2398,25 @@ } else { - uint8_t *appleBootPict; - bootImageData = NULL; - bootImageWidth = kAppleBootWidth; - bootImageHeight = kAppleBootHeight; + uint8_t *appleBootPict; + bootImageData = NULL; + bootImageWidth = kAppleBootWidth; + bootImageHeight = kAppleBootHeight; - // Prepare the data for the default Apple boot image. - appleBootPict = (uint8_t *) decodeRLE(gAppleBootPictRLE, kAppleBootRLEBlocks, bootImageWidth * bootImageHeight); + // Prepare the data for the default Apple boot image. + appleBootPict = (uint8_t *) decodeRLE(gAppleBootPictRLE, kAppleBootRLEBlocks, bootImageWidth * bootImageHeight); if (appleBootPict) { - convertImage(bootImageWidth, bootImageHeight, appleBootPict, &bootImageData); + convertImage(bootImageWidth, bootImageHeight, appleBootPict, &bootImageData); if (bootImageData) { - x = (screen_params[0] - MIN(kAppleBootWidth, screen_params[0])) / 2; - y = (screen_params[1] - MIN(kAppleBootHeight, screen_params[1])) / 2; + x = (screen_params[0] - MIN(kAppleBootWidth, screen_params[0])) / 2; + y = (screen_params[1] - MIN(kAppleBootHeight, screen_params[1])) / 2; drawDataRectangle(x, y, kAppleBootWidth, kAppleBootHeight, bootImageData); free(bootImageData); } - free(appleBootPict); - } + free(appleBootPict); + } } } // ==================================================================== Index: trunk/doc/BootHelp.txt =================================================================== --- trunk/doc/BootHelp.txt (revision 2737) +++ trunk/doc/BootHelp.txt (revision 2738) @@ -68,7 +68,7 @@ "Boot Banner"=Yes|No Show boot banner in GUI mode (disabled by default). ShowInfo=No Disables display of partition and resolution details. "Boot Banner"=No will also disable this info. - "Legacy Logo"=Yes|No Use the legacy grey apple logo (disabled by default). + "Legacy Logo"=Yes|No Use the legacy grey apple logo (enabled by default). PciRoot= Use an alternate value for PciRoot (default value 0).