Android System Display Frame

Source: Internet
Author: User

1 Linux Drive FrameBuffer

At the kernel level, the system screen is described using a hardware device called a framebuffer, and user-space applications can manipulate the hardware device through the device file/dev/fb0 or/dev/graphics/fb0. In fact, the framebuffer itself is not really a hardware, it's just an abstract representation of the graphics card, but we can indirectly manipulate the graphics memory and other registers in the video card by visiting the frame buffer.

2 Hardware Abstraction Layer (HAL) module Gralloc

In order to draw a specified picture on the screen, we need to:

1. Assign a graphics buffer that matches the screen size

2. Register (map) The allocated graphics buffers to the address space of the current process to

3. The contents of the picture to be drawn are written into the registered graphics buffer and rendered (copied) to the system frame buffer.

To achieve the above three operations, we also need to:

1. Load the Gralloc module

2. Open the GRALLOC device and FB device in the Gralloc module

wherein, the GRALLOC device is responsible for allocating the graphics buffer, the Gralloc module is responsible for registering the graphics buffer, and the FB device is responsible for rendering the graphics buffer

3 Surfaceflinger Service is responsible for drawing the Android app UI

This is to learn Loro notes, salute to Lao Luo.

Android System Display Frame

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.