Android Recovery display Chinese, the need for friends can refer to the next.
First download Open source recovery source, address is https://github.com/xiaolu/android_bootable_recovery
Interface of the Chinese display part of the source code in the bootable/recovery/minui/directory, you can directly open-source Minui copy to your bootable/recovery source directory
Then change the bootable/recovery/minui/graphics_cn.c name to GRAPHICS.C (before the default graphics.c is to display the English source),
Open and edit the beginning section
.........
#include <pixelflinger/pixelflinger.h>
Here to use fontcn30_18x48.h this Chinese font file, if you want to change the fonts, you can use the directory of other library files
Like Fontcn36_22x56.h.
#define Board_use_custom_recovery_font "Fontcn30_18x48.h"
#ifdef Board_use_custom_recovery_font
#include Board_use_custom_recovery_font
#else
#include "font_10x18.h"//This is the default use of the English font file
#endif
#include "minui.h"
If the recovery interface is not working properly: only half of the screen is displayed, the feeling is compressed and the color is not soft
That's probably the problem here, you need to define this Recovery_bgra macro so that the value of Pixel_size is 4.
Use 2 by default
#define Recovery_bgra
#if defined (Recovery_bgra)
#define Pixel_format ggl_pixel_format_bgra_8888
#define PIXEL_SIZE 4
#elif defined (RECOVERY_RGBX)
#define Pixel_format ggl_pixel_format_rgbx_8888
#define PIXEL_SIZE 4
#else
#define Pixel_format ggl_pixel_format_rgb_565
#define PIXEL_SIZE 2
#define RECOVERY_RGB_565
#endif
No problem, the compilation is successful, burned to the phone can see the Chinese.
Android Recovery Chinese Display