Graphics Device Interface: Graphical Device Interface

Source: Internet
Author: User
[ Edit this section]

Graphics Device Interface: Graphical Device Interface

GDI is the abbreviation of graphics device interface. It refers to the graphic device interface. Its main task is to take charge of the system and drawing.ProgramInformation exchange between them to process the graphic output of all Windows programs.

In Windows, most applications with graphical interfaces are inseparable from GDI. With the many functions provided by GDI, We can conveniently output graphics on screens, printers, and other output devices, text and other operations. With the advent of GDI, programmers can convert the output of applications into outputs on hardware devices without having to care about hardware devices and device drivers, thus realizing the isolation between program developers and hardware devices, this greatly facilitates development.

How is GDI output?

To output graphics or text on the screen or other output devices, we must first obtain the handle of an object called the device description table (DC: device context), taking it as a parameter, call a variety of GDI functions to achieve the output of various text or graphics. The device description table is a data structure in which GDI stores data. The property content in this structure is related to a specific output device (display, printer, and so on, the attribute defines the working details of the GDI function. Here, the attribute determines the color of the text, the way in which the X and Y coordinates are mapped to the display area of the window, and so on.

Once the device description table handle is obtained, the system uses the default property value to fill the device description table structure.

If necessary, we can use some GDI functions to obtain and change the property values in the device description table.

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.