Cloud desktop scene recognition method and device, storage medium and electronic device
By automatically identifying the processor load information and load thresholds at the target source end of the cloud desktop system, determining the application scenarios, and adapting to adjust the encoding method, the problem that cloud desktop systems in the prior art cannot adaptively identify and switch application scenarios, and improve the recognition efficiency and image display clarity.
Patent Information
- Application Number
- CN202110512073.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-05-11
- Publication Date
- 2025-03-28
- Estimated Expiration
- 2041-05-11
AI Technical Summary
The existing cloud desktop system cannot adaptively recognize and switch application scenarios, resulting in unsmooth image display and rely on user manual recognition and operation.
By obtaining the processor load information at the target source and the load threshold matching the host configuration, comparing it, and automatically identifying the scene identification, thereby determining the application scenario to which the current cloud desktop image belongs, and adapting the encoding method.
Automatic recognition and adaptive adjustment of cloud desktop scenes are realized, scene recognition efficiency and image display clarity are improved, and scene recognition efficiency in the prior art is solved.
Smart Images

Figure CN113254123B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computers, and in particular to a method and device for identifying a cloud desktop scene, a storage medium, and an electronic device. Background Art
[0002] The cloud desktop system usually includes a cloud server and a receiving end. A source end corresponding to the receiving end is set in the cloud server, wherein the source end usually exists in the form of a virtual machine (VM). The user operates the virtual machine VM running in the cloud server through the receiving end, and the virtual machine VM will send the display image of the cloud desktop to the receiving end to present it to the user.
[0003] As the application of cloud desktop systems becomes more and more widespread, the application scenarios that can be implemented based on cloud desktop systems are also increasing. For example, taking cloud office systems and cloud gaming systems as examples, the display performance required by the two is different, and correspondingly, the display methods of the cloud desktop images of the two are also different at the receiving end. If you run a cloud game in a cloud office system scenario, there will be freezes and other unsmooth operation due to the incompatible display methods.
[0004] In the prior art, users need to select and switch different application scenarios through the receiving end, that is, the performance switching of the cloud desktop system depends on the scene switching instructions of the receiving end. In other words, the current cloud desktop system cannot realize adaptive recognition and switching of application scenarios, that is, it still needs to rely on the results of manual recognition by users and then manually switch. Such manual recognition of the application scenarios of the cloud desktop will greatly affect the recognition efficiency of the cloud desktop scenarios.
[0005] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention
[0006] The embodiments of the present invention provide a method and device for identifying a cloud desktop scene, a storage medium, and an electronic device, so as to at least solve the technical problem of unsmooth image display caused by failure to identify the system scene.
[0007] According to one aspect of an embodiment of the present invention, a method for identifying a cloud desktop scene is provided, comprising: obtaining load information of a processor in a target source end, wherein the load information is used to indicate resource usage of a graphics card in the target source end; obtaining a load threshold that matches host configuration information of the target source end; comparing the load information with the load threshold to obtain a comparison result; obtaining a scene identifier that matches the comparison result, and determining an application scene indicated by the scene identifier as a target application scene to which a current cloud desktop image displayed by the target source end belongs.
[0008] According to another aspect of an embodiment of the present invention, a cloud desktop scene identification device is also provided, including: a first acquisition unit, used to obtain load information of a processor in a target source end, wherein the load information is used to indicate the resource usage rate of a graphics card in the target source end; a second acquisition unit, used to obtain a load threshold that matches the host configuration information of the target source end; a comparison unit, used to compare the load information with the load threshold to obtain a comparison result; and a third acquisition unit, used to obtain a scene identifier that matches the comparison result, and determine the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image displayed by the target source end belongs.
[0009] According to another aspect of an embodiment of the present invention, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the above-mentioned cloud desktop scene recognition method when running.
[0010] According to another aspect of an embodiment of the present invention, there is further provided an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to execute the cloud desktop scene recognition method through the computer program.
[0011] In an embodiment of the present invention, after obtaining the load information of the processor in the target source end and the load threshold that matches the host configuration information of the target source end, the load information and the load threshold are compared to determine the target application scenario to which the current cloud desktop image displayed by the target source end belongs. This can automatically identify the target application scenario to which the current cloud desktop image displayed by the target source end belongs based on the real-time load situation of the target source end, so as to adaptively adjust the encoding method (such as frame rate) that matches different target application scenarios based on the automatically identified scene, thereby improving the scene recognition efficiency and the image display clarity, thereby overcoming the problem of low scene recognition efficiency in related technologies. BRIEF DESCRIPTION OF THE DRAWINGS
[0012] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:
[0013] Figure 1 is a flow chart of an optional cloud desktop scene recognition method according to an embodiment of the present invention;
[0014] Figure 2 is a schematic diagram of an application environment of an optional cloud desktop scene recognition method according to an embodiment of the present invention;
[0015] Figure 3is a schematic diagram of an application environment of another optional cloud desktop scene recognition method according to an embodiment of the present invention;
[0016] Figure 4 is a schematic diagram of an optional cloud desktop scene recognition method according to an embodiment of the present invention;
[0017] Figure 5 is a schematic diagram of another optional cloud desktop scene recognition method according to an embodiment of the present invention;
[0018] Figure 6 is a flowchart of another optional cloud desktop scene recognition method according to an embodiment of the present invention;
[0019] Figure 7 The present invention is a schematic diagram of the structure of an optional cloud desktop scene recognition device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0020] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0021] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0022] According to one aspect of an embodiment of the present invention, a method for identifying a cloud desktop scene is provided. Optionally, as an optional implementation, Figure 1 As shown, the above-mentioned cloud desktop scene recognition method includes:
[0023] S102, obtaining load information of a processor in the target source end, wherein the load information is used to indicate a resource usage rate of a graphics card in the target source end;
[0024] S104, obtaining a load threshold that matches the host configuration information of the target source end;
[0025] S106, comparing the load information with the load threshold to obtain a comparison result;
[0026] S108, obtaining a scene identifier that matches the comparison result, and determining the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image displayed by the target source terminal belongs.
[0027] Optionally, in this embodiment, the above-mentioned cloud desktop scene recognition method can be, but is not limited to, applied to the recognition process of the desktop scene presented by the cloud application system. The above-mentioned cloud application system may include: a cloud gaming system, a cloud office system, a cloud conference system, etc. This is an optional example and is not limited here.
[0028] It should be noted that the above-mentioned target source end can be but is not limited to a virtual machine VM or an operating system. Each VM includes a capture end and an encoder, and the capture end is used to capture the source image. Assuming that the cloud server is connected to the game server, the capture end captures the game interface logged in by the account corresponding to each VM. In the game scenario, the capture end sends all data directly to the hardcore encoder for encoding, where the hardcore encoder is the H265 encoder. Assume that the cloud server can also be connected to the office server, and the virtual machine of the server runs an operating system, and different applications run in the operating system. In the office scenario, it is necessary to identify the text area in the image data, encode the text area in vGTP mode, and use hardcore encoding for other parts to make the real picture clearer.
[0029] Optionally, in this embodiment, the above load information may include but is not limited to: GPU load information of the target source end, such as resource usage of a graphics card.
[0030] For ease of understanding, the cloud gaming system is briefly described below.
[0031] like Figure 2 The figure shows an optional structural diagram of a cloud gaming system. Figure 2 As shown, the cloud gaming system 202 includes a cloud server 204 and a zero terminal 206. The cloud server 204 runs multiple virtual machines VM, each VM is configured with a processing module, and each VM corresponds to a zero terminal. Figure 2 As shown, there are three VMs running in the cloud gaming system 202, namely VM2042-1 to VM 2042-3, VM 2042-1 corresponds to zero terminal 206-1, VM 2042-2 corresponds to zero terminal 206-2, and VM 2042-3 corresponds to zero terminal 206-3.
[0032] Based on the above hypothetical scenario, users can use the zero terminal to operate the game running on the VM. The VM captures the desktop image and sends it to the zero terminal, and the zero terminal displays the received image on the connected monitor. It should be noted that for any VM, a corresponding zero terminal push interface is given, and each VM runs independently. Specifically, the VM can run the PC operating system, and the zero terminal can be connected to a monitor.
[0033] like Figure 3 The figure shows an optional structural diagram of a cloud gaming system. Figure 3 As shown, in this embodiment, an operating system 304 is running in the cloud server 302, and the operating system can correspond to multiple zero terminals, such as zero terminals 306-1 to 306-3. Optionally, in this embodiment, the above operating system can be but not limited to a Windows operating system. Although it is an operating system, the image and other information received by each zero terminal are independent of each other.
[0034] Through the embodiments provided by the present application, after obtaining the load information of the processor in the target source end and the load threshold that matches the host configuration information of the target source end, the above load information and the load threshold are compared to determine the target application scenario to which the current cloud desktop image displayed by the target source end belongs. Thereby, based on the real-time load situation of the target source end, the target application scenario to which the current cloud desktop image displayed by the target source end belongs is automatically identified, so that based on the automatically identified scene, the encoding method (such as frame rate) that matches different target application scenarios is adaptively adjusted, thereby achieving the effect of improving scene recognition efficiency, and at the same time, the effect of improving the clarity of image display will be achieved, thereby overcoming the problem of low scene recognition efficiency in related technologies.
[0035] As an optional solution, obtaining a scene identifier that matches the comparison result, and determining the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image displayed by the target source belongs includes: when the comparison result indicates that the resource usage rate in the load information is greater than the load threshold, determining that the scene identifier is a game scene identifier, and determining that the target application scene to which the current cloud desktop image belongs is the game scene.
[0036] As an optional solution, obtaining a load threshold that matches the host configuration information of the target source end includes:
[0037] S1, obtaining host configuration information of the target source end, wherein the configuration information is used to indicate device model information of the target source end;
[0038] S2, searching for a load threshold matching the device model information from a threshold mapping table pre-stored in a database.
[0039] Optionally, in this embodiment, the above device model information may include but is not limited to: a CPU model and a graphics card model in the target source end.
[0040] It should be noted that the CPU series model refers to the CPU manufacturer's determination of a series model for CPU products belonging to the same series based on the market positioning of the CPU products for easy classification and management. Generally speaking, the series model can be said to be an important identifier for distinguishing CPU performance. For example, its major manufacturers may include but are not limited to: Intel and AMD.
[0041] Among them, the performance of the CPU mainly includes the number of cores, main frequency, frequency multiplier, HT, L1 cache, L2 cache, L3 cache, TDP, etc. Each model has its own performance. The performance diagram corresponding to the model can be shown as follows Figure 4 shown.
[0042] The graphics card model principle is the same as the CPU model. The performance parameters corresponding to the graphics card model include: core frequency, acceleration frequency, etc. The performance diagram corresponding to the model can be shown as follows Figure 5 shown.
[0043] As an optional solution, obtaining a scene identifier that matches the comparison result, and determining the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image displayed by the target source belongs includes:
[0044] S1, when the comparison result indicates that the resource usage rate in the load information is less than or equal to the load threshold, obtaining the current cloud desktop image and the reference image currently displayed by the target source end, wherein the reference image frame is an image captured before the current cloud desktop image;
[0045] S2, when the current cloud desktop image changes relative to the reference image, obtaining window attribute information of the front-end window in the current cloud desktop image, wherein the front-end window is used to represent the window that is currently displayed on top in the display interface of the target source end;
[0046] S3, determining the target application scenario to which the current cloud desktop image belongs according to the window attribute information of the front-end window.
[0047] Optionally, in this embodiment, the above window attribute information may be, but is not limited to, the size of the front window, and the window size may be calculated as the percentage of the front window to the entire screen. It should be noted that, generally speaking, the game interface needs to focus on relatively large windows, and if it is a very small window, it may be a game window or an office mode.
[0048] Optionally, in this embodiment, the size of the front-end window can be obtained through, but not limited to, Windows API. For example, the front-end window handle HWND is obtained through HWND GetForegroundWindow (void), and the window size is obtained through BOOLGetWindowRect (HWND hWnd, LPRECT lpRect) through the window handle HWND, and the area of the window is calculated through the width and height of the front-end window, thereby calculating the percentage of the front-end window occupying the screen.
[0049] As an optional scheme, determining the target application scenario to which the current cloud desktop image belongs based on the window attribute information of the front-end window includes: when the display ratio of the display size of the front-end window carried in the window attribute information relative to the display size of the current cloud desktop image is less than a display threshold, determining that the scene identifier is an office scene identifier, and determining that the target application scenario to which the current cloud desktop image belongs is an office scene.
[0050] As an optional solution, determining the target application scenario to which the current cloud desktop image belongs according to the window attribute information of the front-end window includes:
[0051] S1, when the display size of the front-end window carried in the window attribute information relative to the display size of the current cloud desktop image has a display ratio greater than or equal to a display threshold, obtaining a rendering instruction of the front-end window, wherein the rendering instruction is used to indicate a display effect of the content displayed in the front-end window;
[0052] S2, when the rendering instruction indicates that the display effect of the content displayed in the front-end window is a two-dimensional display effect or a three-dimensional display effect, determining that the scene identifier is a game scene identifier, and determining that the target application scene to which the current cloud desktop image belongs is a game scene;
[0053] S3, when the rendering instruction indicates that the display effect of the content displayed in the front-end window is not a two-dimensional display effect or a three-dimensional display effect, determine that the scene identifier is an office scene identifier, and determine that the target application scene to which the current cloud desktop image belongs is an office scene.
[0054] As an optional solution, obtaining the rendering instructions of the front-end window includes:
[0055] S1, determine the application name corresponding to the front-end window;
[0056] S2, locating the application process opened by the corresponding target application according to the application name;
[0057] S3, querying rendering instructions in the application process of the target application.
[0058] As an optional solution, after determining the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image belongs, the method further includes:
[0059] S1, determine the target encoding method that matches the target application scenario;
[0060] S2, encoding the current cloud desktop image according to the target encoding method to obtain an encoding result;
[0061] S3, transmitting the encoding result to the receiving end corresponding to the target source end for display.
[0062] Specific combination Figure 6 The example shown is for illustration:
[0063] Step S602: The VM obtains GPU load information and a load threshold of the host on which it resides.
[0064] It should be noted that the above GPU load information includes the resource usage of the graphics card. In addition, the load thresholds corresponding to the above hosts with different configurations are different. For example, if the same large-scale game is run in a high-configuration host, the load rate is only 40%, while if it is run in a low-configuration host, the load rate may reach 80%.
[0065] The configuration information of the host may include but is not limited to device attribute information, such as CPU model and graphics card model. Further, based on the above configuration information, the load threshold corresponding to the CPU model and graphics card model is queried in a preset database.
[0066] It should be noted that different hosts may be configured with different CPU models and different graphics cards, so the database for querying the load threshold value can be designed in the form shown in the following Table 1:
[0067] Table 1
[0068]
[0069] The above table is only an example, and the specific database data is more comprehensive.
[0070] For example, the configuration of graphics card model D is better than that of C, which is better than that of B, which is better than that of A; the configuration of CPU model 4 is better than that of 3, which is better than that of 2, which is better than that of 1. Then in the above table, threshold D4 is the smallest and threshold A1 is the largest. The thresholds in each row and column are arranged from large to small. In other words, the higher the configuration, the smaller the corresponding threshold. The specific thresholds are obtained through combined tests of different models.
[0071] If there is no corresponding record in the database, you can choose to match a model with the same configuration in the CPU model database as a reference, and configure a model with the same configuration in the graphics card model database as a reference. For specific CPU model databases and graphics card model databases, please refer to the screenshots given above. If there is no model with the same configuration, set a default value, such as 70%.
[0072] Step S604, determining whether the GPU load is greater than a load threshold.
[0073] If the load rate is greater than the load threshold, then as in step S606-1, it is identified as a game scene.
[0074] If the load rate is not greater than the load threshold, determine whether the display interface has changed. If it is determined that there has been a change, execute step S606-2 to obtain the size of the front window. The window size can be calculated as the percentage of the front window occupying the entire screen;
[0075] It should be noted that the window size is obtained through the window handle HWND, and the area of the window is calculated through the width and height of the front window, thereby calculating the percentage of the front window occupying the screen.
[0076] Step S608, determine whether the window interface is greater than the threshold. If it is less than or equal to the threshold, then as in step S610-1, determine to identify it as an office scene. If it is greater than the threshold, execute step S610-2 to obtain the drawing instructions corresponding to the application corresponding to the front window, such as whether the rendering instructions corresponding to the front window application belong to 2D / 3D rendering instructions. If it belongs to 2D / 3D rendering instructions, then as in step S612-1, identify it as a game scene; if it does not belong to 2D / 3D rendering instructions, then as in S612-2, identify it as an office scene.
[0077] In some embodiments, the desktop application of the operating system (windows / linux / Android) responds to the event and draws its own window screen, sends the desktop drawing instructions to the graphics card (or virtual graphics card) driver (WDDM2D / 3D video driver / Other driver), and the graphics card (virtual graphics card) device (Virtual 2D / 3D video device) intercepts the drawing instructions; finally, it is rendered by the graphics card.
[0078] Optionally, the rendering process can be performed on the server or on the GPU POOL, and this document does not impose any restrictions on this.
[0079] The differences in specific drawing instructions for each operating system are as follows:
[0080] 2D: GDI for Windows, Xlib for Linux and Android;
[0081] 3D: Windows is Direct 3D, Linux is OpenGL, Android is OpenGL ES.
[0082] Specifically, this step first obtains the application name corresponding to the front-end window; locates the process opened by the application based on the application name; queries the rendering instructions loaded by the process; and determines whether to enter an office scene or a game scene based on the loaded rendering instructions. Specifically, if the rendering instruction corresponding to the front-end window is OpenGL, it is determined to be a game mode and enters the game scene.
[0083] It should be noted that, for the above-mentioned method embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should know that the present invention is not limited by the described action sequence, because according to the present invention, certain steps can be performed in other sequences or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.
[0084] According to another aspect of an embodiment of the present invention, a cloud desktop scene recognition device for implementing the above-mentioned cloud desktop scene recognition method is also provided. Figure 7 As shown, the device comprises:
[0085] A first acquisition unit 702 is used to acquire load information of a processor in a target source end, wherein the load information is used to indicate a resource usage rate of a graphics card in the target source end;
[0086] The second acquisition unit 704 is used to acquire a load threshold that matches the host configuration information of the target source end;
[0087] A comparison unit 706 is used to compare the load information with the load threshold to obtain a comparison result;
[0088] The third acquisition unit 708 is used to acquire a scene identifier that matches the comparison result, and determine the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image displayed by the target source terminal belongs.
[0089] Optionally, in this embodiment, the embodiment of the above-mentioned cloud desktop scene recognition device may be but not limited to the embodiment of the above-mentioned cloud desktop scene recognition method, which will not be repeated here.
[0090] According to another aspect of an embodiment of the present invention, an electronic device for implementing the above-mentioned cloud desktop scene recognition method is also provided, the electronic device includes a memory and a processor, the memory stores a computer program, and the processor is configured to execute the steps in any of the above-mentioned method embodiments through the computer program.
[0091] Optionally, in this embodiment, the electronic device may be located in at least one network device among a plurality of network devices of a computer network.
[0092] Optionally, in this embodiment, the processor may be configured to perform the following steps through a computer program:
[0093] S1, obtaining load information of a processor in a target source end, wherein the load information is used to indicate resource usage of a graphics card in the target source end;
[0094] S2, obtaining a load threshold that matches the host configuration information of the target source end;
[0095] S3, comparing the load information with the load threshold to obtain a comparison result;
[0096] S4, obtaining a scene identifier that matches the comparison result, and determining the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image displayed by the target source terminal belongs.
[0097] Optionally, those skilled in the art will appreciate that the electronic device may also be a smart phone (such as an Android phone, an iOS phone, etc.), a tablet computer, a PDA, a mobile Internet device (MID), a PAD, or other terminal device.
[0098] Among them, the memory can be used to store software programs and modules, such as the program instructions / modules corresponding to the cloud desktop scene recognition method and device in the embodiment of the present invention. The processor executes various functional applications and data processing by running the software programs and modules stored in the memory, that is, the above-mentioned cloud desktop scene recognition method is realized. The memory may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory may further include a memory remotely arranged relative to the processor, and these remote memories may be connected to the terminal via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and a combination thereof. Among them, the memory can be specifically, but not limited to, used to store information such as sample features of items and target virtual resource accounts. In addition, it may also include, but is not limited to, other module units in the above-mentioned cloud desktop scene recognition device, which will not be repeated in this example.
[0099] Optionally, the transmission device is used to receive or send data via a network. Specific examples of the network may include wired networks and wireless networks. In one example, the transmission device includes a network adapter (Network Interface Controller, NIC), which can be connected to other network devices and routers via a network cable so as to communicate with the Internet or a local area network. In one example, the transmission device is a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.
[0100] In addition, the electronic device further comprises: a display for displaying the order information to be processed; and a connection bus for connecting the various module components in the electronic device.
[0101] In other embodiments, the terminal device or server may be a node in a distributed system, wherein the distributed system may be a blockchain system, and the blockchain system may be a distributed system formed by connecting the multiple nodes through network communication. Among them, the nodes may form a peer-to-peer (P2P, Peer To Peer) network, and any form of computing device, such as a server, terminal and other electronic devices, may become a node in the blockchain system by joining the peer-to-peer network.
[0102] According to one aspect of the present application, a computer program product or computer program is provided, the computer program product or computer program including computer instructions, the computer instructions being stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the above-mentioned cloud desktop scene recognition method. The computer program is configured to execute the steps of any of the above-mentioned method embodiments when it is run.
[0103] Optionally, in this embodiment, the computer-readable storage medium may be configured to store a computer program for performing the following steps:
[0104] S1, obtaining load information of a processor in a target source end, wherein the load information is used to indicate resource usage of a graphics card in the target source end;
[0105] S2, obtaining a load threshold that matches the host configuration information of the target source end;
[0106] S3, comparing the load information with the load threshold to obtain a comparison result;
[0107] S4, obtaining a scene identifier that matches the comparison result, and determining the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image displayed by the target source terminal belongs.
[0108] Optionally, in this embodiment, a person of ordinary skill in the art may understand that all or part of the steps in the various methods of the above embodiments may be completed by instructing hardware related to the terminal device through a program, and the program may be stored in a computer-readable storage medium, and the storage medium may include: a flash drive, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, etc.
[0109] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.
[0110] If the integrated units in the above embodiments are implemented in the form of software functional units and sold or used as independent products, they can be stored in the above computer-readable storage medium. Based on such an understanding, the technical solution of the present invention, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for enabling one or more computer devices (which can be personal computers, servers or network devices, etc.) to perform all or part of the steps of the methods described in various embodiments of the present invention.
[0111] In the above embodiments of the present invention, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0112] In the several embodiments provided in the present application, it should be understood that the disclosed client can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.
[0113] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0114] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0115] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A method for identifying a cloud desktop scene, characterized in that: include: Acquire load information of a processor in a target source end, wherein the load information is used to indicate resource usage of a graphics card in the target source end; Obtaining a load threshold that matches the host configuration information of the target source end; Comparing the load information with the load threshold to obtain a comparison result; Acquire a scene identifier that matches the comparison result, and determine the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image displayed by the target source terminal belongs; When the comparison result indicates that the resource usage rate in the load information is greater than the load threshold, determining that the scene identifier is a game scene identifier, and determining that the target application scene to which the current cloud desktop image belongs is a game scene; In the case where the comparison result indicates that the resource usage rate in the load information is less than or equal to the load threshold, the current cloud desktop image and the reference image currently displayed by the target source end are obtained, wherein the reference image is an image captured before the current cloud desktop image; in the case where the current cloud desktop image changes relative to the reference image, the window attribute information of the front-end window in the current cloud desktop image is obtained, wherein the front-end window is used to represent the window that is currently displayed on top in the display interface of the target source end; In the case where the display size of the front-end window carried in the window attribute information relative to the display size of the current cloud desktop image has a display ratio greater than or equal to a display threshold, obtaining a rendering instruction of the front-end window, wherein the rendering instruction is used to indicate a display effect of the content displayed in the front-end window; When the rendering instruction indicates that the display effect of the content displayed in the front-end window is a two-dimensional display effect or a three-dimensional display effect, determining that the scene identifier is a game scene identifier, and determining that the target application scene to which the current cloud desktop image belongs is a game scene; When the rendering instruction indicates that the display effect of the content displayed in the front-end window is not a two-dimensional display effect or a three-dimensional display effect, the scene identifier is determined to be an office scene identifier, and the target application scene to which the current cloud desktop image belongs is determined to be an office scene.
2. The method according to claim 1, characterized in that Obtaining a load threshold that matches the host configuration information of the target source end includes: Acquire the host configuration information of the target source end, wherein the host configuration information is used to indicate the device model information of the target source end; The load threshold matching the device model information is found from a threshold mapping table pre-stored in a database.
3. The method according to claim 1, characterized in that The obtaining of the rendering instruction of the front-end window comprises: Determine the application name corresponding to the front-end window; Locate the application process opened by the corresponding target application according to the application name; The rendering instruction is searched in an application process of the target application.
4. The method according to any one of claims 1 to 3, characterized in that After determining the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image belongs, the method further includes: Determine a target encoding method that matches the target application scenario; Encode the current cloud desktop image according to the target encoding method to obtain an encoding result; The encoding result is transmitted to the receiving end corresponding to the target source end for display.
5. A cloud desktop scene recognition device, characterized in that: include: A first acquisition unit, configured to acquire load information of a processor in a target source end, wherein the load information is used to indicate a resource usage rate of a graphics card in the target source end; A second acquisition unit, configured to acquire a load threshold matching the host configuration information of the target source end; A comparison unit, used for comparing the load information with the load threshold to obtain a comparison result; A third acquisition unit is used to acquire a scene identifier that matches the comparison result, and determine the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image displayed by the target source terminal belongs; The device is also used to, after obtaining a scene identifier that matches the comparison result and determining the application scene indicated by the scene identifier as the target application scene to which the current cloud desktop image displayed by the target source terminal belongs, determine that the scene identifier is a game scene identifier when the comparison result indicates that the resource usage rate in the load information is greater than the load threshold, and determine that the target application scene to which the current cloud desktop image belongs is a game scene; when the comparison result indicates that the resource usage rate in the load information is less than or equal to the load threshold, obtain the current cloud desktop image and a reference image currently displayed by the target source terminal, wherein the reference image is an image captured before the current cloud desktop image; and when the current cloud desktop image changes relative to the reference image, obtain window attribute information of the front-end window in the current cloud desktop image, wherein the front-end window is used to represent the current a window that is always displayed on top in the display interface of the target source end; when the display ratio of the display size of the front-end window carried in the window attribute information to the display size of the current cloud desktop image is greater than or equal to a display threshold, obtaining a rendering instruction of the front-end window, wherein the rendering instruction is used to indicate the display effect of the content displayed in the front-end window; when the rendering instruction indicates that the display effect of the content displayed in the front-end window is a two-dimensional display effect or a three-dimensional display effect, determining that the scene identifier is a game scene identifier, and determining that the target application scene to which the current cloud desktop image belongs is a game scene; when the rendering instruction indicates that the display effect of the content displayed in the front-end window is not a two-dimensional display effect or a three-dimensional display effect, determining that the scene identifier is an office scene identifier, and determining that the target application scene to which the current cloud desktop image belongs is an office scene.
6. A storage medium, characterized in that: The storage medium stores a computer program, wherein the computer program is configured to execute the method described in any one of claims 1 to 4 when running.
7. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to execute the method according to any one of claims 1 to 4 through the computer program.
Citation Information
Patent Citations
Game scene processing method and device, electronic equipment and storage medium
CN109685726A
Desktop display protocol switching method, computing device and readable storage medium
CN112732399A