九鼎创展论坛中文版English
登录 | 立即注册 设为首页收藏本站 切换到宽版
查看: 6046|回复: 2

如何更换uboot中的logo

[复制链接]
发表于 2013-2-26 11:21:13 | 显示全部楼层 |阅读模式
uboot中的logo为一数组,文件所在路径为
  1. uboot/drivers/video/logo.c
复制代码
结构体类型如下:
  1. /*
  2. * the gimp's c source format picture
  3. */
  4. struct picture
  5. {
  6.         /* width of the picture*/
  7.         u32 width;

  8.         /* height of the picture*/
  9.         u32 height;

  10.         /* bytes per pixel */
  11.         u32 bytes_per_pixel;

  12.         /* the pixel data */
  13.         u8 * data;
  14. };
复制代码
可通过gimp生成,gimp为linux下的PS软件,在ubuntu下,安装命令如下:
  1. sudo apt-get install gimp
复制代码
转换方法,在gimp中先打开待转换的图片,然后另存为“C程序代码”即可,替换logo.c文件中的如下数组
  1. /*
  2. * default xboot's logo
  3. */
  4. static const struct picture default_xboot_logo = {
  5.         250, 186, 3, (u8 *)
  6.   ...........
  7. };
复制代码
回复

使用道具 举报

发表于 2013-2-26 18:06:46 | 显示全部楼层
嗯嗯,我测试过,可以
回复 支持 反对

使用道具 举报

发表于 2013-8-21 10:15:16 | 显示全部楼层
兑尊 发表于 2013-2-26 18:06
嗯嗯,我测试过,可以

gimp中先打开待转换的图片,然后另存为“C程序代码,怎么做,我上面的另存为不行啊?你们是什么格式的图片呢?
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|手机版|小黑屋|深圳市九鼎创展科技官方论坛 ( 粤ICP备11028681号-2  

GMT+8, 2024-3-29 16:18 , Processed in 0.021435 second(s), 21 queries .

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表