Display driver tutorial (2)

xiaoxiao2021-03-06  101

Third, Kernel Mode GDI

Below is the Windows 2000 display subsystem map:

From the figure we can see that GDI is split into two parts: Win32 (user mode GDI API) and Graphics Engine (GDI API of kernel mode). Note: The gray part is the system provided, we can't modify them. The application call WIN32 GDI function issues a graphic output request, which is sent to the kernel mode GDI, and the kernel mode GDI sends these requests to the corresponding graphics driver (such as graphics or printer driver). The GDI API in user mode believes that everyone is very familiar, I don't have more introduction. The following mainly introduces the GDI in kernel mode.

The kernel mode GDI mainly has the following functions:

Communicate with the graphics driver by calling the display device interface (DDI: DISPLAY DRIVER Interface) function provided by the graphics driver. Itself has graphical output capabilities, provided by a service function of an ENG head. The driver can call them directly to simplify graphics drive development. Maintain some important data structures, such as Brush, CLIP, and more. At the same time, the kernel mode GDI provides a function of accessing these structures so you can access these data structures in the driver.

转载请注明原文地址:https://www.9cbs.com/read-125210.html

New Post(0)