Multi-screen display method and multi-screen display system
By optimizing the GPU-driven display process, configuring the registers of the GPU display interface to point to the same CRTC and maintaining consistent display timing and DPMS status, the black screen problem caused by insufficient number of independent display channels of the GPU is solved, and orderly display of multi-screen expansion and replication is realized, which improves system integration and reduces costs.
Patent Information
- Application Number
- CN202510640875.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-19
- Publication Date
- 2025-06-20
- Estimated Expiration
- 2045-05-19
AI Technical Summary
In GPU display, when there is a comprehensive display requirement for multi-screen expansion and multi-screen replication at the same time, due to the limited number of independent display channels of the GPU, the problem of black screen occurs during multi-screen display. The implementation of one-in-one and multiple-output functions through external conversion devices will lead to low system integration and high cost.
By optimizing the display process of each display interface of the GPU, determining the type and channel of the GPU display interface to be copied and copied, and using the configuration registers to point to the same CRTC, and maintaining the display timing and DPMS status consistent, thereby realizing orderly display of multi-screen expansion and multi-screen replication.
It solves the problem of black screen caused by insufficient independent display channels of GPU, realizes orderly display of multi-screen expansion and multi-screen replication, improves system integration and reduces costs.
Smart Images

Figure CN120183360A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of GPU displays, and more particularly, to a multi-screen display method and a multi-screen display system. Background Art
[0002] The display controller in the GPU chip contains multiple independent display channels, and each display channel corresponds to a CRTC (Cathode Ray Tube Contriller) controller. Each CRTC is responsible for generating the timing signals required for display (such as horizontal synchronization, vertical synchronization, pixel clock, etc.) and controlling the output of pixel data. Through the collaborative work with the video memory, encoder, connector, etc., the CRTC ensures that the display can correctly receive and process the image signal, so that the display can display the image according to the expected timing.
[0003] The number of CRTCs is determined during the chip design stage of the GPU. During multi-screen extended display, the image data corresponding to each screen is stored in the video memory at different addresses. The CRTC obtains the image data from the video memory corresponding to each screen, and converts the format into a format suitable for the connector and the corresponding display, ensuring that each screen can correctly display the image.
[0004] When there is a combined display requirement for both multi-screen extension and multi-screen replication, due to the limitation of the number of independent display channels of the GPU, a black screen problem may occur on the displays connected to the GPU display interface during multi-screen display; if an additional conversion device is used externally to implement the function of one input and multiple outputs of the GPU display interface, it will result in low system integration, which is not conducive to the miniaturization and lightweight design of the product and is costly. Summary of the Invention
[0005] In view of the technical problems existing in the prior art, the present invention provides a multi-screen display method and a multi-screen display system, which overcome the black screen problem caused by the limitation of the number of independent display channels of the GPU when there is a combined display requirement for both multi-screen extension and multi-screen replication.
[0006] According to a first aspect of the present invention, there is provided a multi-screen display method, including: Correspondingly connecting multiple GPU display interfaces to multiple displays; Determining the type and channel of the GPU display interface to be replicated, and automatically obtaining the type and channel of the replicated GPU display interface in the initial state by detecting the connection status of the GPU display interface when starting up; By configuring the registers of the GPU display interface to be replicated, making the GPU display interface to be replicated and the replicated GPU display interface point to the same CRTC, and making the display timings and DPMS states of the GPU display interface to be replicated and the replicated GPU display interface the same, the extended screen and the replicated screen are made to display normally in the initial state; Modify the type and channel of the replicated GPU display interface in the application program to achieve the orderly display of the extended screen and the replicated screen.
[0007] Based on the above technical solution, the present invention can also be improved as follows.
[0008] Optionally, the determining the type and channel of the GPU display interface to be replicated includes: Add a member bool mirror_status to the GPU device structure body, and assign an initial value of true to mirror_status during the initialization of the GPU device; add a member int mirror_num to each display interface structure body, and assign an initial value of 0 to mirror_num during the initialization of the display interface; In the initial case, sequentially detect the connection status of other GPU display interfaces that are not replicated in a certain order. If the display interface is connected and mirror_status is true or mirror_num is 1, it means that the display interface is the replicated display interface; at this time, set the value of mirror_status to 0 and set the value of mirror_num to 1; Automatically obtain the type and channel of the replicated GPU display interface in the initial state by detecting the connection status of the GPU display interface during startup.
[0009] Optionally, the making the GPU display interface to be replicated and the replicated GPU display interface point to the same CRTC by configuring the registers of the GPU display interface to be replicated, and making the display timings and DPMS states of the GPU display interface to be replicated and the replicated GPU display interface the same, and making the extended screen and the replicated screen display normally in the initial state includes: Add members struct drm_display_mode *mode and int dpms_status to the type structure body of each GPU display interface. mode and dpms_status respectively record the display timings and DPMS states of the GPU display interface; Make the GPU display interface to be replicated and the replicated GPU display interface point to the same CRTC by configuring the CRTC-related registers of the GPU display interface to be replicated; According to the display timing of the GPU display interface to be replicated, configure the display timing related registers of the GPU display interface to be replicated so that the display timings of the GPU display interface to be replicated and the GPU display interface to be replicated are the same; According to the DPMS state of the GPU display interface to be replicated, configure the DPMS state related registers of the GPU display interface to be replicated so that the DPMS states of the GPU display interface to be replicated and the GPU display interface to be replicated are the same, thereby realizing the normal display of the extended screen and the replicated screen in the initial state.
[0010] Optionally, it further includes: When it is necessary to change the GPU display interface to be replicated, configure the type and channel of the GPU display interface to be replicated in the application program; The application program sends a display interface replication request and data to the GPU kernel driver by calling IOCTL, and the data includes the types and channels of the GPU display interface to be replicated and the GPU display interface to be replicated; The GPU kernel driver obtains the display interface replication request and data sent by the application program, and configures the CRTC, display timing, and DPMS state related registers of the GPU display interface to be replicated according to the CRTC, display timing, and DPMS state of the GPU display interface to be replicated, so that the GPU display interface to be replicated and the GPU display interface to be replicated point to the same CRTC, and so that the display timings and DPMS states of the GPU display interface to be replicated and the GPU display interface to be replicated are the same.
[0011] Optionally, the configuration of the type and channel of the GPU display interface to be replicated in the application program includes: Obtain the instruction input into the application program, parse the instruction, obtain the type and channel of the GPU display interface to be replicated and save them; Judge whether it is a display interface replication instruction by means of string comparison; If so, confirm the type and channel of the GPU display interface to be replicated by comparing characters one by one and save them.
[0012] Optionally, the sending of the display interface replication request and data from the application program to the GPU kernel driver by calling IOCTL includes: Based on the GPU device file interface, the application program sends a display interface replication request and data to the GPU kernel driver by calling IOCTL; The GPU kernel driver obtains the display interface replication request and data sent by the application program, and realizes the orderly display of multi-screen extension and multi-screen replication by setting the CRTC, display timing, and DPMS related registers of the GPU display interface to be replicated and the GPU display interface to be replicated.
[0013] According to a second aspect of the present invention, a multi-screen display system is provided, including: A determination module, configured to determine the types and channels of the GPU display interface to be replicated and the GPU display interface to be replicated. At startup, the types and channels of the GPU display interface to be replicated in the initial state are automatically obtained by detecting the connection status of the GPU display interface; A configuration module, configured to make the GPU display interface to be replicated and the GPU display interface to be replicated point to the same CRTC by configuring the registers of the GPU display interface to be replicated, and to make the display timings and DPMS states of the GPU display interface to be replicated and the GPU display interface to be replicated the same, so that the extended screen and the replicated screen can be normally displayed in the initial state; A modification module, configured to modify the types and channels of the GPU display interface to be replicated in the application program to achieve the orderly display of the extended screen and the replicated screen.
[0014] A multi-screen display method and a multi-screen display system provided by the present invention, in the case of a comprehensive display requirement for multi-screen extension and multi-screen replication, by optimizing the display processes of each display interface of the GPU driver, making multiple display interfaces point to the same CRTC and keeping their timings and DPMS states consistent, solves the black screen problem caused by insufficient GPU independent display channel numbers for the multi-screen extension display requirement of hybrid replication. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] Figure 1 It is a flowchart of a multi-screen display method provided by an embodiment of the present invention; Figure 2 It is a display flowchart of the GPU display interface to be replicated and the GPU display interface to be replicated; Figure 3 It is a flowchart of configuring the communication between the GPU display interface to be replicated and the GPU display interface to be replicated and the GPU kernel driver in the application program; Figure 4 It is a flowchart of the GPU kernel driver configuring HDMI 3 and HDMI 0 to maintain the replicated mode display; Figure 5 It is a flowchart of configuring the relevant registers of the GPU display interface to be replicated; Figure 6 It is a flowchart of reconfiguring HDMI 3 to replicate HDMI 1 display; Figure 7 It is a schematic structural diagram of a multi-screen display system according to an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0016] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are some, but not all, of the embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention. Additionally, the technical features in each embodiment or individual embodiment provided by the present invention can be combined with each other arbitrarily to form a feasible technical solution. Such combination is not restricted by the sequence of steps and / or the structural composition mode, but must be based on the ability of those of ordinary skill in the art to implement. When the combination of technical solutions results in contradictions or cannot be implemented, it should be considered that such combination of technical solutions does not exist and is not within the protection scope required by the present invention.
[0017] Based on the defects of existing multi-screen displays, the present invention discloses a multi-screen display method. First, multiple GPU display interfaces are simultaneously connected to multiple displays in a corresponding manner. Then, the display processes of each GPU display interface are reasonably designed to enable the extended screen and the duplicated screen to be normally displayed in the initial state. Finally, in the application program, the types and channels of the GPU display interfaces to be duplicated and the duplicated ones are configured to achieve an orderly display of multi-screen extension and multi-screen duplication. The multi-screen display method proposed by the present invention realizes an orderly display of multi-screen extension and multi-screen duplication by optimizing the display processes of each GPU display interface driven by the GPU and designing the communication between the application program and the GPU driver. It not only meets the actual application requirements of multi-screen displays but also does not require an additional external conversion device. The system has a high degree of integration, which is conducive to the miniaturization and lightweight design of products and can reduce costs. It has a wide range of applications in daily office fields such as classroom teaching and work reporting.
[0018] Figure 1 The following is a flowchart of a multi-screen display method provided by the present invention. As Figure 1 shown, the method includes: Step 1: Connect multiple GPU display interfaces to multiple displays in a corresponding manner.
[0019] It can be understood that in the multi-screen display requirement, the GPU chip has multiple display interfaces, and one GPU display interface is connected to one display to achieve multi-screen display.
[0020] Step 2: Determine the type and channel of the GPU display interface to be duplicated, and automatically obtain the type and channel of the duplicated GPU display interface in the initial state by detecting the connection status of the GPU display interface when the device is powered on.
[0021] It can be understood that when there is a multi-screen duplication display situation, first determine the type and channel of the GPU display interface to be duplicated.
[0022] Among them, add a member bool mirror_status to the GPU device structure body, and assign an initial value of true to mirror_status during the initialization of the GPU device; add a member int mirror_num to each display interface structure body, and assign an initial value of 0 to mirror_num during the initialization of the display interface; The GPU display interface to be replicated among multiple GPU display interfaces is determined. In the initial situation, the GPU display interface to be replicated needs to be determined. In an embodiment of the present invention, according to the access situation of other GPU display interfaces, the GPU display interface to be replicated is determined in the order of the numbers of the accessed GPU display interfaces. Specifically, for example, there are a total of five display interfaces: HDMI 0, HDMI 1, HDMI 2, HDMI 3, and DP 0. If the HDMI 3 interface is determined to be the display interface to be replicated, the GPU display interface to be replicated can be determined by detecting the currently accessed display interface. If the HDMI 0 interface is accessed at this time and mirror_status is true or mirror_num is 1, then HDMI 0 is used as the GPU display interface to be replicated. If the HDMI 0 interface is not accessed at this time and the HDMI1 interface is accessed and mirror_status is true or mirror_num is 1, then HDMI 1 is the GPU display interface to be replicated. When both the HDMI 0 interface and the HDMI 1 interface are accessed and mirror_status is true or mirror_num is 1, then HDMI 1 is the GPU display interface to be replicated, and so on; The types and channels of the GPU display interface to be replicated and the GPU display interface to be replicated in the initial situation are determined, and the types and channels of the GPU display interface to be replicated and the GPU display interface to be replicated are saved, and the mirror_status value is set to false and the mirror_num value is set to 1. If HDMI 0 is the GPU display interface to be replicated, the mirror_status value is set to false, and the mirror_num value of HDMI 0 is set to 1; Step 3, by configuring the registers of the GPU display interface to be replicated, make the GPU display interface to be replicated and the GPU display interface to be replicated point to the same CRTC, and make the display timings and DPMS states of the GPU display interface to be replicated and the GPU display interface to be replicated the same, so as to realize the normal display of the extended screen and the replicated screen in the initial state.
[0023] It can be understood that, referring to Figure 2, after determining the GPU display interface to be replicated and the replicated GPU display interface in the initial situation, add struct drm_display_mode *mode and int dpms_status members to each GPU display interface type structure. Use mode and dpms_status to record the display timing and DPMS status of the replicated GPU display interface respectively.
[0024] Configure the relevant registers of the GPU display interface to be replicated according to the CRTC, display timing and DPMS status of the replicated GPU display interface.
[0025] Specifically, by configuring the CRTC-related registers of the GPU display interface to be replicated, make the GPU display interface to be replicated and the replicated GPU display interface point to the same CRTC; According to the display timing of the replicated GPU display interface, by configuring the display timing-related registers of the GPU display interface to be replicated, make the display timing of the GPU display interface to be replicated and the replicated GPU display interface the same; According to the DPMS status of the replicated GPU display interface, by configuring the DPMS status-related registers of the GPU display interface to be replicated, make the DPMS status of the GPU display interface to be replicated and the replicated GPU display interface the same, so as to realize the normal display of the extended screen and the replicated screen in the initial state.
[0026] Among them, it can be seen Figure 3 , during the subsequent display process, if it is necessary to modify the replicated GPU display interface (wherein, the type and channel of the GPU display interface to be replicated have been determined at startup), it is through configuring the type and channel of the replicated GPU display interface in the application program; the application program sends a display interface replication request and data to the GPU kernel driver by calling IOCTL, and the data includes the type and channel of the GPU display interface to be replicated and the replicated GPU display interface.
[0027] When the GPU kernel driver obtains the display interface replication request and data sent by the application program, configure the CRTC, display timing and DPMS status-related registers of the GPU display interface to be replicated according to the CRTC, display timing and DPMS status of the replicated GPU display interface, so that the GPU display interface to be replicated and the replicated GPU display interface point to the same CRTC, and make the display timing and DPMS status of the GPU display interface to be replicated and the replicated GPU display interface the same.
[0028] Among them, when the application sends a display interface copy request to the GPU kernel driver, the types and channels of the GPU display interface to be copied and the GPU display interface to be replicated are input into the application and saved; based on the GPU device file interface, the application sends a copy request and data to the GPU kernel driver through IOCTL.
[0029] Among them, the types and channels of the GPU display interface to be copied and the GPU display interface to be replicated are configured in the application, including: Obtain the instruction input into the application, parse the instruction, obtain the type and channel of the GPU display interface to be copied and save them; Judge whether it is a display interface copy instruction by means of string comparison; If so, confirm the type and channel of the GPU display interface to be replicated by comparing characters one by one and save them.
[0030] According to the CRTC, display timing and DPMS status of the GPU display interface to be replicated configured in the application, reconfigure the relevant registers of the GPU display interface to be copied. Specifically, it includes the following aspects of reconfiguration: Reset the CRTC-related registers of the GPU display interface to be copied so that it points to the same CRTC as the GPU display interface to be replicated; Reset the display timing-related registers of the GPU display interface to be copied so that its display timing is the same as that of the GPU display interface to be replicated; Reset the DPMS-related registers of the GPU display interface to be copied so that its DPMS status is the same as that of the GPU display interface to be replicated; Through the reconfiguration of the display interfaces and channels to be copied and replicated in the application, the orderly display of GPU multi-screen expansion and multi-screen replication is realized.
[0031] Next, a specific example is used to illustrate a multi-screen display method provided by the present invention.
[0032] S1. The GPU chip design supports 4 CRTC controllers and supports independent display of 4 display interfaces. Connect the 4 HDMI (HDMI 0, HDMI 1, HDMI 2, and HDMI 3) and 1 DP (DP 0) interfaces of the GPU board to the monitor at the same time, and specify HDMI3 as the display interface to be copied; S2. Add a member bool mirror_status to the GPU device structure, and assign an initial value of true to mirror_status during GPU device initialization; add a member int mirror_num to both the HDMI and DP interface structures, and assign an initial value of 0 to mirror_num during display interface initialization. Load the GPU driver and sequentially detect the connection status of HDMI 0, HDMI1, HDMI 2, and DP 0. Since HDMI 0 is connected and mirror_status is true or mirror_num is 1, it indicates that HDMI0 is the replicated display interface; at this time, set the value of mirror_status to 0 and set the mirror_num value of HDMI 0 to 1; S3. Add struct drm_display_mode *mode and int dpms_status members to both the HDMI and DP interface structures. Optimize the display process of HDMI 3 in the GPU driver to make the CRTC corresponding to HDMI 3 the same as that of HDMI 0; after setting the display timing of HDMI 0, record its display timing and DPMS status with mode and dpms_status respectively; based on the mode and dmps_status of HDMI0, set the same display timing and DPMS status for HDMI 3. When the GPU driver is loaded at startup and the desktop is lit, at this time, HDMI 0, HDMI 1, HDMI 2, and DP 0 achieve 4-screen extended mode display, and HDMI 3 and HDMI 0 maintain replicated mode display; S4. Enter hdmi 3 clone hdmi 1 in the application, and send the replication request and data to the GPU kernel driver through IOCTL; after the GPU kernel driver obtains the replication request and data, analyze the data and reset the registers related to the CRTC, display timing, and DPMS status of HDMI 3 to make HDMI 3 maintain replicated mode display with HDMI 1.
[0033] Among them, refer to Figure 4 , in one implementation, S2 specifically includes: S2.1. Load the GPU driver at startup and initialize the GPU hardware; S2.2. After detecting the hot plug interrupt, obtain the EDID (Extended Display Identification Data) of the GPU display interface connected to the display screen, parse it, and pass it to the operating system; S2.3. Sequentially detect the connection status of HDMI 0, HDMI 1, HDMI 2, and DP 0, and judge the values of mirror_status and mirror_num, to obtain the type and channel of the initially copied GPU display interface; S2.3. When it is detected that HDMI 0 is connected and the value of mirror_status is true, confirm that HDMI 0 is the display interface to be copied.
[0034] Among them, referring to Figure 5 , in one implementation, S3 specifically includes: S3.1. The GPU sequentially sets the relevant registers such as CRTC, display timing, and DPMS status for each of the display interfaces HDMI 0, HDMI 1, HDMI 2, HDMI 3, and DP 0; use mode and dpms_status to record the display timing and DPMS status of HDMI 0; S3.2. When it is detected that the current display interface is HDMI 3, configure the CRTC-related registers of HDMI 3 to make HDMI3 and HDMI 0 point to the same CRTC; based on the previously saved mode and dpms_status values of HDMI 0, configure the display timing and DPMS status-related registers of HDMI 3, and initially make HDMI 3 display in the same replication mode as HDMI 0.
[0035] Referring to Figure 6 , in one implementation, S4 specifically includes: S4.1. In the application, input "hdmi 3 clone hdmi 1" and parse it; S4.2. Obtain the type and channel of the display interface to be copied and save them; S4.3. Judge whether it is a clone instruction by means of string comparison; S4.4. Confirm the type and channel of the display interface to be copied by comparing characters one by one and save them; S4.5. Open the GPU device file and send a copy request and data to the GPU kernel driver through IOCTL; S4.6. After the GPU kernel driver receives the request and data from the application, parse the data and judge the type and channel of the display interface to be copied and the copied one; S4.7. Re - set the CRTC, display timing, and DPMS - related registers for the HDMI 3 to be replicated, so that HDMI 3 and HDMI 1 point to the same CRTC, and the display timing and DPMS status of HDMI 3 and HDMI 1 are the same, and HDMI 3 and HDMI 1 maintain the replicated - mode display.
[0036] See Figure 7 , a multi - screen display system according to an embodiment of the present invention is provided. The system includes: A determination module 701, configured to determine the types and channels of the GPU display interfaces to be replicated and the GPU display interfaces to be copied. At startup, the types and channels of the GPU display interfaces to be copied in the initial state are automatically obtained by detecting the connection status of the GPU display interfaces; A configuration module 702, configured to configure the registers of the GPU display interface to be replicated, so that the GPU display interface to be replicated and the GPU display interface to be copied point to the same CRTC, and the display timing and DPMS status of the GPU display interface to be replicated and the GPU display interface to be copied are the same, and the extended screen and the replicated screen are normally displayed in the initial state; A modification module 703, configured to modify the types and channels of the GPU display interfaces to be copied in the application program, so as to realize the orderly display of the extended screen and the replicated screen.
[0037] It can be understood that a multi - screen display system provided by the present invention corresponds to the multi - screen display methods provided in the foregoing embodiments. The relevant technical features of the multi - screen display system can refer to the relevant technical features of the multi - screen display methods, and will not be elaborated herein.
[0038] A multi - screen display method and a multi - screen display system provided by an embodiment of the present invention have the following beneficial effects: (1) When there are comprehensive display requirements for both multi - screen extension and multi - screen replication at the same time, due to the limited number of independent display channels of the GPU, the problem of black screens of the monitors connected to the GPU display interfaces will occur during multi - screen display; if an additional external conversion device is used to implement the one - input - multiple - output function of the GPU display interface, it will lead to low system integration and high costs.
[0039] (2) The multi - screen display method proposed by the present invention realizes the orderly display of multi - screen extension and multi - screen replication by optimizing the display process of each display interface of the GPU driver and designing the communication between the application program and the GPU driver without an external conversion device. It not only meets the actual application requirements of multi - screen display, but also does not require an additional external conversion device, with high system integration, which is beneficial to the miniaturization and lightweight design of products and can reduce costs.
[0040] It should be noted that in the above embodiments, the descriptions of the respective embodiments have their own emphases. For parts not described in detail in a certain embodiment, reference may be made to the relevant descriptions of other embodiments.
[0041] Those skilled in the art should understand that the embodiments of the present invention can be provided as a method, a system, or a computer program product. Therefore, the present invention can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present invention can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0042] The present invention is described with reference to the flowcharts and / or block diagrams of methods, apparatuses (systems), and computer program products according to the embodiments of the present invention. It should be understood that each flow and / or block in the flowchart and / or block diagram can be implemented by computer program instructions, and the combination of the flows and / or blocks in the flowchart and / or block diagram can also be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded computer, or other programmable data processing devices to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing devices generate means for implementing the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.
[0043] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable memory generate a manufactured article including instruction means, and the instruction means implements the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.
[0044] These computer program instructions can also be loaded onto a computer or other programmable data processing device, so that a series of operation steps are executed on the computer or other programmable device to generate a computer-implemented process, and thus the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.
[0045] Although the preferred embodiments of the present invention have been described, additional changes and modifications can be made to these embodiments by those skilled in the art once they learn the basic inventive concept. Therefore, the appended claims are intended to be construed to include the preferred embodiments as well as all changes and modifications that fall within the scope of the present invention.
[0046] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalent technologies, the present invention is also intended to include these modifications and variations.
Claims
1. A multi-screen display method, characterized in that: include: Connect multiple GPU display interfaces to multiple monitors accordingly; Determine the type and channel of the GPU display interface to be copied, and automatically obtain the type and channel of the copied GPU display interface in the initial state by detecting the connection status of the GPU display interface when the computer is turned on; By configuring the register of the to-be-copied GPU display interface, the to-be-copied GPU display interface and the copied GPU display interface point to the same CRTC, and the display timing and DPMS state of the to-be-copied GPU display interface and the copied GPU display interface are the same, so that the extended screen and the copied screen are displayed normally in the initial state; Modify the type and channel of the copied GPU display interface in the application program to achieve orderly display of the extended screen and the copied screen.
2. The multi-screen display method according to claim 1, characterized in that: The determining the type and channel of the GPU display interface to be copied, and automatically acquiring the type and channel of the copied GPU display interface in the initial state by detecting the connection state of the GPU display interface at startup, includes: In the initial case, determine the type and channel of the GPU display interface to be copied; Add a member bool mirror_status to the GPU device structure, and set the initial value of mirror_status to true when the GPU device is initialized; add a member int mirror_num to each display interface structure, and set the initial value of mirror_num to 0 when the display interface is initialized; Initially, the connection status of other non-copied GPU display interfaces is detected in a certain order. If the display interface is connected and mirror_status is true or mirror_num is 1, it means that the display interface is the copied display interface; at this time, the mirror_status value is set to 0 and the mirror_num value is set to 1.
3. The multi-screen display method according to claim 1, characterized in that: By configuring the register of the to-be-copied GPU display interface, the to-be-copied GPU display interface and the copied GPU display interface point to the same CRTC, and the display timing and DPMS state of the to-be-copied GPU display interface and the copied GPU display interface are the same, and the extended screen and the copied screen are displayed normally in the initial state, including: Add struct drm_display_mode *mode and intdpms_status members to the type structure of each GPU display interface. mode and dpms_status respectively record the display timing and DPMS status of the GPU display interface. By configuring the CRTC related registers of the GPU display interface to be copied, the GPU display interface to be copied and the GPU display interface to be copied point to the same CRTC; According to the display timing of the copied GPU display interface, the display timing related registers of the to-be-copied GPU display interface are configured so that the display timing of the to-be-copied GPU display interface and the to-be-copied GPU display interface are the same; According to the DPMS state of the copied GPU display interface, the DPMS state-related register of the to-be-copied GPU display interface is configured so that the DPMS states of the to-be-copied GPU display interface and the to-be-copied GPU display interface are the same.
4. The multi-screen display method according to claim 2, characterized in that: Also includes: When the copied GPU display interface needs to be changed, the type and channel of the copied GPU display interface are configured in the application; The application sends a display interface copy request and data to the GPU kernel driver by calling IOCTL, wherein the data includes the type and channel of the GPU display interface to be copied and the GPU display interface to be copied; The GPU kernel driver obtains the display interface copy request and data sent by the application, and configures the CRTC, display timing and DPMS status related registers of the GPU display interface to be copied according to the CRTC, display timing and DPMS status of the copied GPU display interface, so that the GPU display interface to be copied and the copied GPU display interface point to the same CRTC, and the display timing and DPMS status of the GPU display interface to be copied and the copied GPU display interface are the same.
5. The multi-screen display method according to claim 4, characterized in that: The configuration of the types and channels of the to-be-copied GPU display interface and the copied GPU display interface in the application program includes: Obtaining instructions input into the application, parsing the instructions, obtaining the type and channel of the GPU display interface to be copied, and saving them; Determine whether it is a display interface copy instruction by using a string comparison method; If so, the type and channel of the copied GPU display interface are confirmed and saved by character-by-character comparison.
6. The multi-screen display method according to claim 4, characterized in that: The application sends a display interface copy request and data to the GPU kernel driver by calling IOCTL, including: Based on the GPU device file interface, the application sends display interface copy requests and data to the GPU kernel driver by calling IOCTL; The GPU kernel driver obtains the display interface copy request and data sent by the application, and realizes the orderly display of multi-screen expansion and multi-screen copy by setting the CRTC, display timing and DPMS related registers of the display interface to be copied and copied.
7. A multi-screen display system, characterized in that: include: A determination module, used to determine the types and channels of the GPU display interface to be copied and the GPU display interface to be copied, and automatically obtain the type and channel of the GPU display interface to be copied in the initial state by detecting the connection status of the GPU display interface when the computer is turned on; a configuration module, configured to configure the registers of the to-be-copied GPU display interface so that the to-be-copied GPU display interface and the copied GPU display interface point to the same CRTC, and to make the display timing and DPMS state of the to-be-copied GPU display interface and the copied GPU display interface the same, so that the extended screen and the copied screen are displayed normally in the initial state; The modification module is used to modify the type and channel of the copied GPU display interface in the application program so as to realize the orderly display of the extended screen and the copied screen.
Citation Information
Patent Citations
Intelligent split screen display available mobile terminal
CN103365620A
Method for expanding computer desktop without additional display card
CN112860202A
Multi-screen tiled display system and method
CN113157232A
Multi-screen display method, multi-screen display system and storage medium
CN114138219A
Control method and control system for multi-screen display quality under same resolution
CN114302090A