Linux-framebuffer Equipment Related parameters

Source: Internet
Author: User

If the application needs to know about the parameters of the framebuffer device, it must be done through the IOCTL () system call.

All the IOCTL command words are defined in header file <linux/fb.h>, however, the most common IOCTL command word is the following two: Fbioget_fscreeninfo and Fbioget_vscreeninfo.

The former returns fixed information related to framebuffer, the size of the actual frame cache space on the specific hardware, and the ability to accelerate the hardware.

The latter returns variable information that is related to framebuffer.

The variable is because the same graphics hardware can work in different modes.

In short, a hardware that supports 1024x768x24 graphics mode can often work in 800x600x16 graphics mode.

Variable information refers to information such as the length, width, and color depth of the framebuffer.

The two command-word-related structures are two: struct fb_fix_screeninfo and struct fb_var_screeninfo.

Both structures are large, which are used to hold fixed information about the framebuffer device, which is used to hold variable information about the framebuffer device.

These two structures are used when the IOCTL () is called.

The following fields of struct fb_var_screeninfo are commonly used in applications:

Xres, Yres, Bits_per_pixel, respectively, represent the resolution of the x-axis, the resolution of the y-axis, and the color depth per pixel (in units of color depth bit/pixel), whose type definitions are unsigned 32-bit integers.

Http://hi.baidu.com/atoe/blog/item/e8da6416912a8a4a20a4e94f.html

Http://hi.baidu.com/excellentderek/blog/item/f387e64e24b713cdd0c86a59.html

Fundamentals of graphic system development (very detailed)

Http://linux.chinaunix.net/bbs/thread-1063136-1-1.html

Linux-framebuffer Equipment Related parameters

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.