Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to modify the location of LOGO in android

2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly explains "how to modify the location of LOGO in android". The content in the article is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn "how to modify the location of LOGO in android".

If the LOGO image you want to use is smaller than the screen resolution, you can first compile the LOGO image into the kernel according to the previous method, and then burn it to the development board. You can see that the LOGO image appears less than in the upper left corner. In this case, you need to adjust the position of LOGO.

First of all, the picture we use is the ppm file that comes with the default kernel, "logo_linux_clut224.ppm", that is, the picture of the little penguin, which has a very small resolution. We introduce how to modify the source code to move it to the middle of the screen.

Of the fb_show_logo_line function in the kernel source code "drivers/video/fbdev/core/fbmem.c"

Add code after the line "image.height = logo- > height;".

Image.dx= (info- > var.xres/2)-(image.width/2)

Image.dy= (info- > var.yres/2)-(image.height/2)

After modification, it is shown in figure 2.

Then modify: fb_do_show_logo (info, & image, rotate, n); change n to 1, after modification, as shown in figure 73.4.3.

Modify the fbcon_prepare_logo () function in source code "drivers/video/console/fbcon.c"

In the code logo_height = fb_prepare_logo (info, ops- > rotate); logo_lines = DIV_ROUND_UP (logo_height, vc- > vc_font.height)

Increase between:

Logo_height + = (info- > var.yres/2)-(logo_height/2)

As shown in figure 4.

After the code has been modified, recompiled and burned, and during kernel startup, you can see the linux kernel's little penguin LOGO in the middle of the screen.

Thank you for reading, the above is the content of "how to modify the location of LOGO in android". After the study of this article, I believe you have a deeper understanding of how to modify the location of LOGO in android, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report