rk fb: fix bmp logo support

This commit is contained in:
yxj
2013-03-20 16:42:28 +08:00
parent 7e4cfd6383
commit 5a6fbdee60
6 changed files with 31 additions and 15 deletions

View File

@@ -98,16 +98,21 @@ config LOGO_LINUX_800x480_CLUT224
bool "Standard 224-color 800x480 Linux logo "
default n
config LOGO_LOWERPOWER_WARNING
bool "warning: lowerpower when poweron"
default n
menuconfig LOGO_LINUX_BMP
bool "Bmp logo support"
default n
config LOGO_LOWERPOWER_WARNING
bool "warning: lowerpower when poweron"
default n
config LOGO_LINUX_BMP_SUNSET
bool "Bmp logo sunset"
depends on LOGO_LINUX_BMP
default n
config LOGO_LINUX_BMP_ANDROID
bool "Bmp logo android"
depends on LOGO_LINUX_BMP
default n
endif # LOGO

View File

@@ -19,6 +19,7 @@ obj-$(CONFIG_LOGO_M32R_CLUT224) += logo_m32r_clut224.o
obj-$(CONFIG_LOGO_G3_CLUT224) += logo_g3_clut224.o
obj-$(CONFIG_LOGO_LINUX_800x480_CLUT224) += logo_linux_800x480_clut224.o
obj-$(CONFIG_LOGO_LINUX_BMP_SUNSET) += logo_sunset_bmp.o
obj-$(CONFIG_LOGO_LINUX_BMP_ANDROID) += logo_android_bmp.o
obj-$(CONFIG_LOGO_LOWERPOWER_WARNING) += logo_linux_lowerpower_clut224.o
obj-$(CONFIG_LOGO_CHARGER_CLUT224) += logo_charger00_clut224.o logo_charger01_clut224.o logo_charger02_clut224.o logo_charger03_clut224.o logo_charger04_clut224.o logo_charger05_clut224.o logo_charger06_clut224.o logo_charger07_clut224.o logo_charger08_clut224.o

View File

@@ -141,9 +141,14 @@ const struct linux_logo * __init_refok fb_find_logo(int depth)
if (depth >= 24)
{
#ifdef CONFIG_LOGO_LINUX_BMP
#ifdef CONFIG_LOGO_LINUX_BMP
#ifdef CONFIG_LOGO_LINUX_BMP_SUNSET
logo = &logo_sunset_bmp;
#endif
#ifdef CONFIG_LOGO_LINUX_BMP_ANDROID
logo = &logo_android_bmp;
#endif
#endif
}
else

View File

Before

Width:  |  Height:  |  Size: 115 KiB

After

Width:  |  Height:  |  Size: 115 KiB

View File

@@ -669,19 +669,23 @@ static struct fb_ops fb_ops = {
static struct fb_var_screeninfo def_var = {
.red = {11,5,0},//default set to rgb565,the boot logo is rgb565
.green = {5,6,0},
.blue = {0,5,0},
.transp = {0,0,0},
#ifdef CONFIG_LOGO_LINUX_BMP
.nonstd = HAL_PIXEL_FORMAT_RGBA_8888,
.red = {16,8,0},
.green = {8,8,0},
.blue = {0,8,0},
.transp = {0,0,0},
.nonstd = HAL_PIXEL_FORMAT_BGRA_8888,
#else
.nonstd = HAL_PIXEL_FORMAT_RGB_565, //(ypos<<20+xpos<<8+format) format
.red = {11,5,0},
.green = {5,6,0},
.blue = {0,5,0},
.transp = {0,0,0},
.nonstd = HAL_PIXEL_FORMAT_RGB_565, //(ypos<<20+xpos<<8+format) format
#endif
.grayscale = 0, //(ysize<<20+xsize<<8)
.activate = FB_ACTIVATE_NOW,
.accel_flags = 0,
.vmode = FB_VMODE_NONINTERLACED,
.grayscale = 0, //(ysize<<20+xsize<<8)
.activate = FB_ACTIVATE_NOW,
.accel_flags = 0,
.vmode = FB_VMODE_NONINTERLACED,
};
static struct fb_fix_screeninfo def_fix = {

View File

@@ -54,6 +54,7 @@ extern const struct linux_logo logo_m32r_clut224;
extern const struct linux_logo logo_spe_clut224;
extern const struct linux_logo logo_g3_clut224;
extern const struct linux_logo logo_sunset_bmp;
extern const struct linux_logo logo_android_bmp;
extern const struct linux_logo logo_linux_800x480_clut224;
extern const struct linux_logo *fb_find_logo(int depth);