如何使用我自己的自定义启动动画编译 AOSP 项目?

How to compile an AOSP project with my own custom bootanimation?

我正在尝试使用自定义启动动画编译 AOSP,但没有成功。我只是 运行 没有办法...要更改启动动画,我已经完成了:

  1. 创建了具有以下结构的 .zip 文件: bootanimation.zip{ desc.txt 第0部分{ 000.png、001.png、……、010.png } 第1部分 { 011.png, 012.png, ... ..., 021.png } }

  2. 已编辑 system/core/include/private/android_filesystem_config.h

  3. 的权限
  4. 将 bootanimation.zip 文件放入 /system/media/

但是,Android开机时,只显示Google商标,跳过了开机动画。有人可以指出我遗漏了什么吗?

PS: 我正在成功编译 AOSP。它启动时所有功能都正常。我的问题仅在于已编译项目的引导动画定制。

好的。我已经解决了我的问题。 问题是,除了我所做的所有事情之外,bootanimation.zip 文件必须使用 存储方法 .

进行压缩

@mthama 写道:

Ok. I've solved my problem. The issue was that besides all the things I've done, the bootanimation.zip file MUST be compressed with store method.

解决方案是在打包存档时不使用任何压缩。这可以在 Linux 上使用以下命令实现:

zip -0r bootanimation.zip desc.txt part0 part1

-0 选项表示不使用任何压缩,-r 选项表示递归地包含 part0part1 的内容。

还有一些方法可以通过图形界面来实现,例如使用 7-Zip,如此答案所示:https://superuser.com/a/337087/295453