Game rendering methods, devices, equipment, and storage media
By establishing a point-to-point transmission channel on the cloud server, user operation commands and rendering data are directly transmitted, solving the latency problem in cloud gaming and improving the gaming experience.
Patent Information
- Application Number
- CN202211235659.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-10-10
- Publication Date
- 2026-03-06
- Estimated Expiration
- 2042-10-10
AI Technical Summary
In existing technologies, rendering delays and audio content transmission latency in cloud gaming result in a poor gaming experience for players.
By establishing a point-to-point transmission channel under the target cloud server, user operation commands and rendering data are directly transmitted, avoiding intermediate processing and enabling direct communication between the client and the virtual game instance.
It reduces latency in cloud gaming, improves the efficiency of game rendering and audio transmission, and enhances the player's gaming experience.
Smart Images

Figure CN115445194B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of data processing technology, and more specifically, to a game rendering method, apparatus, device, and storage medium. Background Technology
[0002] The metaverse constructs a brand-new and vast worldview. It can be described as a parallel virtual world where people are closely connected to their virtual avatars and can switch between them at any time. As the game develops, more and more users are joining activities in this virtual world.
[0003] In the metaverse, the rendering of the virtual world of cloud gaming relies on the resources of the cloud server. In the existing technology, the user sends operation instructions to the cloud server, and the cloud server starts an additional service in the system environment. This service converts the user operation instructions into system events, and then generates rendering results based on the system events and sends them to the user.
[0004] However, players are very sensitive to operation delays during gameplay. This method of converting user commands into system events introduces additional delays, affecting the player's gaming experience. Summary of the Invention
[0005] The purpose of this application is to address the shortcomings of the prior art by providing a game rendering method, apparatus, device, and storage medium to solve the problem of latency caused by forwarding rendering results or audio content in cloud games, which affects the player's gaming experience.
[0006] To achieve the above objectives, the technical solutions adopted in the embodiments of this application are as follows:
[0007] In a first aspect, one embodiment of this application provides a game rendering method applied to a target cloud server, the target cloud server including multiple preset virtual game instances, the method comprising:
[0008] The receiving client sends user operation instructions for a target virtual game scene space in a preset cloud game via a pre-established point-to-point transmission channel; the point-to-point transmission channel is the transmission channel between the client and the target virtual game instance, wherein the target virtual game instance is the virtual game instance corresponding to the target virtual game scene space;
[0009] Using the target virtual game instance, and based on the user operation instructions, obtain the rendering data generated by the target virtual game scene space;
[0010] The rendering data is sent to the client using the point-to-point transmission channel, so that the client can draw the interface of the target virtual game scene space based on the rendering data.
[0011] Secondly, another embodiment of this application provides a game rendering apparatus, the apparatus comprising: a receiving module, an acquiring module, and a sending module, wherein:
[0012] The receiving module is used to receive user operation instructions sent by the client through a pre-established point-to-point transmission channel for a target virtual game scene space in a preset cloud game; the point-to-point transmission channel is a transmission channel between the client and the target virtual game instance, wherein the target virtual game instance is the virtual game instance corresponding to the target virtual game scene space;
[0013] The acquisition module is used to acquire rendering data generated by the target virtual game scene space based on the user operation instructions using the target virtual game instance.
[0014] The sending module is used to send the rendering data to the client using the point-to-point transmission channel, so that the client can draw the interface of the target virtual game scene space based on the rendering data.
[0015] Thirdly, another embodiment of this application provides a game rendering device, including: a processor, a storage medium and a bus, wherein the storage medium stores machine-readable instructions executable by the processor, and when the game rendering device is running, the processor communicates with the storage medium via the bus, and the processor executes the machine-readable instructions to perform the steps of any of the methods described in the first aspect above.
[0016] Fourthly, another embodiment of this application provides a storage medium storing a computer program, which, when executed by a processor, performs the steps of any of the methods described in the first aspect above.
[0017] The beneficial effects of this application are as follows: Using the game rendering method provided in this application, the target virtual game instance under the target cloud server in the cloud game can directly receive user operation instructions sent by the client for the target virtual game scene space in the preset cloud game through a pre-established point-to-point transmission channel. Furthermore, the target virtual game instance can directly obtain the rendering data generated by the target virtual game scene space according to the user operation instructions, and then directly send the rendering data to the client through the point-to-point transmission channel. This enables the client to communicate directly with the target virtual game instance through the point-to-point transmission channel, thereby reducing the additional latency caused by forwarding rendering results and user instructions for the use of cloud games. Attached Figure Description
[0018] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0019] Figure 1 A flowchart illustrating a game rendering method provided in an embodiment of this application;
[0020] Figure 2 A flowchart illustrating a game rendering method provided in another embodiment of this application;
[0021] Figure 3 A flowchart illustrating a game rendering method provided in another embodiment of this application;
[0022] Figure 4 A schematic diagram of the structure of a game rendering device provided in an embodiment of this application;
[0023] Figure 5 A schematic diagram of the structure of a game rendering apparatus provided in another embodiment of this application;
[0024] Figure 6 This is a schematic diagram of the structure of a game rendering device provided in an embodiment of this application. Detailed Implementation
[0025] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are some embodiments of this application, but not all embodiments.
[0026] The components of the embodiments of this application described and illustrated in the accompanying drawings can be arranged and designed in a variety of different configurations. Therefore, the following detailed description of the embodiments of this application provided in the drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0027] Furthermore, the flowcharts used in this application illustrate operations implemented according to some embodiments of this application. It should be understood that the operations in the flowcharts may not be implemented in sequence, and steps without logical contextual relationships may be reversed in order or performed simultaneously. Moreover, those skilled in the art, guided by the content of this application, may add one or more other operations to the flowcharts, or remove one or more operations from the flowcharts.
[0028] In one embodiment of this application, the game rendering method can run on a local terminal device or a server. When the game rendering method runs on a server, the method can be implemented and executed based on a cloud interaction system, wherein the cloud interaction system includes a server and client devices.
[0029] In an optional implementation, various cloud applications, such as cloud gaming, can run under the cloud interaction system. Taking cloud gaming as an example, cloud gaming refers to a gaming method based on cloud computing. In the cloud gaming operating mode, the game program and the game screen presentation are separated. The storage and execution of the game rendering method are completed on the cloud gaming server. The client device is used for receiving and sending data and presenting the game screen. For example, the client device can be a display device with data transmission capabilities located close to the player, such as a mobile terminal, television, computer, PDA, or game console; however, the information processing is performed by the cloud gaming server in the cloud. When playing the game, the player operates the client device to send operation commands to the cloud gaming server. The cloud gaming server runs the game according to the operation commands, encodes and compresses the game screen and other data, returns it to the client device via the network, and finally, the client device decodes and outputs the game screen.
[0030] In an optional implementation, taking a game as an example, the local terminal device stores the game program and is used to display the game screen. The local terminal device is used to interact with the player through a graphical user interface (GUI), i.e., conventionally by downloading, installing, and running the game program via an electronic device. The local terminal device can provide the GUI to the player in various ways, such as rendering it on the terminal's display screen or providing it to the player via holographic projection. For example, the local terminal device can include a display screen for displaying the GUI, which includes game screens, and a processor for running the game, generating the GUI, and controlling the display of the GUI on the display screen.
[0031] In related technologies, a service is typically started in a virtual machine system environment. This service is responsible for sending the rendering results of the virtual game world drawn to the window to the user side by capturing frames. It also receives user commands and converts them into system events so that the window can receive the relevant commands. However, since players are very sensitive to operation delays during gameplay, this method of obtaining rendering results by capturing frames and converting user commands into system events causes players to experience additional delays in the virtual game scene space.
[0032] To address the aforementioned technical problems in related technologies, this application provides a game rendering method that, through a pre-established point-to-point transmission channel, enables a preset virtual game instance on the target cloud server to directly transmit data bidirectionally with the client, thereby avoiding additional latency to the virtual game world.
[0033] The following explanation uses the target cloud server as the execution subject to illustrate a game rendering method provided in this application embodiment.
[0034] The following explanation, using several specific application examples, illustrates a game rendering method provided in this application. Figure 1 This is a flowchart illustrating a game rendering method according to an embodiment of this application. The target cloud server includes multiple preset virtual game instances, such as... Figure 1 As shown, the method includes:
[0035] S101: Receive user operation commands sent by the client via a pre-established point-to-point transmission channel, targeting the virtual game scene space in the preset cloud game.
[0036] The point-to-point transmission channel is the transmission channel between the client and the target virtual game instance. The target virtual game is the virtual game currently logged into by the user, the target virtual game scene space is the game scene space corresponding to the currently logged-in virtual game, and the target virtual game instance is the virtual game instance corresponding to the target virtual game scene space. In the embodiments of this application, the aforementioned point-to-point transmission channel can be, for example, a peer-to-peer (P2P) transmission channel. Specifically, the protocol used by the P2P transmission channel can be a user-preset custom control protocol. That is, the client directly sends user operation commands to the target virtual game instance through the custom control protocol. The selection of the custom control protocol can be flexibly adjusted according to user needs. For example, it can be the Transmission Control Protocol / Internet Protocol (TCP / IP), the NetBIOS Enhanced User Interface (NetBEUI), or the Internetwork Packet Exchange / Sequences Packet Exchange (IPX / SPX) protocol. The specific communication protocol selection can be flexibly adjusted according to user needs, and this application does not impose any restrictions.
[0037] S102: Using the target virtual game instance, obtain the rendering data generated by the target virtual game scene space according to the user's operation instructions.
[0038] After receiving user operation instructions sent through a point-to-point transmission channel, the target virtual game instance directly determines the corresponding rendering data based on the received user operation instructions. These user operation instructions can be, for example, user-input control commands for the target virtual game, such as commands to control a virtual character to perform a corresponding task, commands to control a virtual character to wear corresponding virtual clothing, commands to control a virtual character to move within the target virtual game scene space, or commands to control a specific control within the target virtual game scene space. It should be understood that the above operation instructions are merely illustrative examples; the specific types and methods of operation instructions can be flexibly adjusted according to user needs and are not limited to the embodiments described above.
[0039] The rendering data may include, for example, image data, video data, or audio data, and this application makes no restrictions on these data.
[0040] S103: Uses a point-to-point transmission channel to send rendering data to the client.
[0041] This enables the client to draw the interface of the target virtual game scene space based on the rendering data.
[0042] In other words, in the embodiments of this application, after the target virtual game instance determines the rendering data corresponding to the user operation command, it directly copies the rendering data from the video memory to the memory, without drawing in the target virtual game instance, and sends it directly to the client, thereby improving the efficiency of data transmission and solving the problem of additional latency caused by data forwarding.
[0043] Using the game rendering method provided in this application, the target virtual game instance under the target cloud server in the cloud game can directly receive user operation commands sent by the client for the target virtual game scene space in the preset cloud game through a pre-established peer-to-peer transmission channel. The target virtual game instance can directly obtain the rendering data generated by the target virtual game scene space according to the user operation commands, and then directly send the rendering data to the client through the peer-to-peer transmission channel. This enables the client to communicate directly with the target virtual game instance through the peer-to-peer transmission channel, thereby reducing the additional latency caused by forwarding rendering results and user commands for the use of cloud games.
[0044] Optionally, based on the above embodiments, this application embodiment may also provide a game rendering method, the implementation process of which will be illustrated below with reference to the accompanying drawings. Figure 2 A flowchart illustrating a game rendering method provided in another embodiment of this application is shown below. Figure 2 As shown, before S101, the method may further include:
[0045] S111: Receive the instance allocation result sent by the scheduling server.
[0046] The instance allocation result includes: the instance identifier of the target virtual game instance and the user identifier corresponding to the client; wherein, within the same time period, the instance identifier of a target virtual game instance can only uniquely correspond to the user identifier of one client, that is, within the same time period, there is a one-to-one relationship between the target virtual game instance and the client, and they can communicate bidirectionally with each other.
[0047] In the embodiments of this application, the instance allocation result is obtained by the scheduling server in the following manner: if the client is detected to meet the instance allocation conditions, an instance is allocated to the client to obtain the instance allocation result.
[0048] For example, in some possible embodiments, if a client’s first online request is detected, it is determined that the client meets the instance allocation conditions; or, if a user operation command sent by the client for the first time is detected, it is determined that the client meets the instance allocation conditions.
[0049] S112: Based on the user identifier and the instance identifier of the target virtual game instance, establish a point-to-point transmission channel between the client and the target virtual game instance.
[0050] Once the scheduling server determines that the client meets the instance allocation conditions, it sends the user identifier corresponding to the client to the target virtual game instance and sends the instance identifier of the target virtual game instance to the client. This establishes a point-to-point transmission channel between the client and the target virtual game instance, enabling bidirectional data transmission. During subsequent data transmission between the client and the target virtual game instance, the established point-to-point transmission channel is monitored to ensure that it can transmit data normally.
[0051] In the embodiments of this application, the instance identifier of the target virtual game instance in the instance allocation result is: the identifier of the idle instance determined by the scheduling server from multiple preset virtual game instances of the cloud server.
[0052] For example, in an embodiment of this application, the instance allocation result further includes: the instance identifier of the target cloud server, which is determined as a scheduling server in the following manner: the target cloud server is determined from multiple cloud servers in the preset cloud game based on the rendering complexity of the target virtual game scene space in the preset cloud game.
[0053] Since the image processor resources of cloud servers are very expensive, this application introduces a scheduling server to improve the utilization rate of image processor resources. The scheduling server is used to monitor each cloud server, determine the number of virtual game instances existing under each cloud server, and the number of virtual game instances under each cloud server, and record the status of each virtual game instance, which may include: idle, faulty, and in use. After determining that the client meets the instance allocation conditions, the scheduling server will determine the target cloud server from among the multiple cloud servers that can support the above rendering complexity according to the rendering complexity of the target virtual game scene space corresponding to the current client's user operation command.
[0054] The target cloud server is a cloud server that includes at least one idle instance. If a cloud server meets the above rendering complexity but has no idle instances, it will not be identified as a target cloud server. Subsequently, the scheduling service determines one instance as the target virtual game instance from at least one idle instance of the target cloud server. Since the target virtual game instance is determined based on the rendering complexity of the target virtual game scene space, the corresponding matching target virtual game instance can be flexibly determined according to the rendering complexity of the target virtual game scene space, thereby effectively improving resource utilization and avoiding the problem that the determined target virtual game instance cannot render the target virtual game scene space.
[0055] Optionally, based on the above embodiments, this application embodiment may also provide a game rendering method, the implementation process of which will be illustrated below with reference to the accompanying drawings. Figure 3 A flowchart illustrating a game rendering method provided in another embodiment of this application is shown below. Figure 3 As shown, before S111, the method may further include:
[0056] S121: Receive the number of concurrent rendering paths sent by the scheduling server.
[0057] The concurrent rendering path is determined by the scheduling server based on the rendering complexity of each virtual game world in the preset cloud game and the virtual machine configuration information of the cloud server. The scheduling server sets different concurrent rendering paths in different cloud servers according to the configuration information of the virtual machines and the resources required for rendering. Since different cloud servers have different configurations, their corresponding concurrent rendering paths may not be the same, thereby effectively improving resource utilization and flexibility. There can be multiple instances of virtual game worlds under one virtual machine, and each instance of virtual game world is connected to a corresponding client. This enables one cloud server to serve multiple clients at the same time, solving the problem of low resource utilization and lack of flexibility caused by the existing technology where one cloud server can only provide services to one client user.
[0058] S122: Based on concurrent rendering paths, multiple preset virtual game instances are created in the cloud server.
[0059] In this application, the number of multiple preset virtual game instances is less than or equal to the number of concurrent rendering paths. In the embodiments of this application, the number of concurrent rendering paths corresponding to each cloud server is the maximum number of client users that the cloud server can provide services to at the same time. The higher the rendering complexity of the virtual game world, the more resources it requires. Therefore, for cloud servers with higher rendering complexity, the number of concurrent rendering paths is less.
[0060] In some possible embodiments, rendering complexity may be related to the level of detail of the virtual game world scene, as well as the number and complexity of the virtual characters in the scene. The more detailed the scene, the higher the rendering complexity; the more virtual characters in the scene, the higher the rendering complexity; and the more complex the virtual characters in the scene, the higher the rendering complexity. It should be understood that the above factors affecting rendering complexity are only illustrative examples and can be flexibly adjusted and determined according to the user's needs.
[0061] In one embodiment of this application, the number of instances of the virtual game world is generally equal to the number of concurrent rendering paths. The specific number of instances of the virtual game world can be set and adjusted flexibly according to the user's needs, and this application does not impose any restrictions here.
[0062] For example, in an embodiment of this application, the rendering data includes: display rendering data; then the way to send the rendering data to the client can be, for example, by: converting the display rendering data into image data, performing image encoding to obtain image encoded data; and using a point-to-point transmission channel to send the image encoded data to the client.
[0063] In other words, the target virtual game instance only sends some display rendering data to the client. It does not draw the display rendering data on the target virtual game instance side. Instead, the client side draws the data based on the received display rendering data after receiving it from the target virtual game instance.
[0064] In another embodiment of this application, the rendering data further includes: audio rendering data; then the way to send the rendering data to the client can be, for example, by converting the audio rendering data into an audio encoding format, performing audio encoding, and obtaining audio encoded data; and by using a point-to-point transmission channel to send the image encoded data and audio encoded data to the client.
[0065] This method of encoding both display rendering data and audio rendering data before transmission can compress the transmitted display rendering data and audio rendering data, thereby improving transmission efficiency and reducing transmission bandwidth.
[0066] When the scheduling server establishes a point-to-point transmission channel between the target virtual game instance and the client, it will simultaneously establish an audio transmission channel and a data transmission channel, so that the target virtual game instance and the client can transmit audio, image data, video data or other data point-to-point.
[0067] The game rendering method provided in this application includes multiple virtual game instances under the target cloud server, enabling multi-path concurrent rendering of cloud resources on the target cloud server. Each virtual game instance can provide rendering of the virtual game world for its corresponding client user, thus solving the problem of low resource utilization and inflexibility caused by a cloud server only being able to serve one user. In addition, using the method provided in this application, data transmission between the virtual game instance and the client is carried out directly through a pre-established point-to-point transmission channel, avoiding the latency problem caused by data transmission.
[0068] The rendering apparatus for a game provided in this application will be explained below with reference to the accompanying drawings. This rendering apparatus can perform the above-described functions. Figures 1-3 The specific implementation and beneficial effects of any game's rendering method are described above and will not be repeated below.
[0069] Figure 4 This is a schematic diagram of the structure of a game rendering device provided in one embodiment of this application, as shown below. Figure 4 As shown, the device includes: a receiving module 201, an acquiring module 202, and a transmitting module 203, wherein:
[0070] The receiving module 201 is used to receive user operation instructions sent by the client through a pre-established point-to-point transmission channel for a target virtual game scene space in a preset cloud game; the point-to-point transmission channel is a transmission channel between the client and the target virtual game instance, wherein the target virtual game instance is the virtual game instance corresponding to the target virtual game scene space;
[0071] The acquisition module 202 is used to acquire rendering data generated by the target virtual game scene space based on the user's operation instructions using the target virtual game instance;
[0072] The sending module 203 is used to send rendering data to the client using a point-to-point transmission channel, so that the client can draw the interface of the target virtual game scene space based on the rendering data.
[0073] Optionally, based on the above embodiments, this application embodiment may also provide a game rendering device, as described below with reference to the accompanying drawings. Figure 4 The implementation process of the given device is illustrated with examples. Figure 5 A schematic diagram of the structure of a game rendering device provided in another embodiment of this application, as shown below. Figure 5 As shown, the device also includes: a building module 204, wherein:
[0074] The receiving module 201 is used to receive the instance allocation result sent by the scheduling server; the instance allocation result includes: the instance identifier of the target virtual game instance, and the user identifier corresponding to the client;
[0075] Module 204 is established to establish a point-to-point transmission channel between the client and the target virtual game instance based on the user identifier and the instance identifier of the target virtual game instance.
[0076] The instance allocation result is obtained by the scheduling server in the following manner:
[0077] If a client is detected to meet the instance allocation conditions, an instance is allocated to the client, and the instance allocation result is obtained.
[0078] Optionally, the instance identifier of the target virtual game instance in the instance allocation result is: the identifier of the idle instance determined by the scheduling server from multiple preset virtual game instances on the cloud server.
[0079] like Figure 5 As shown, the device also includes a determining module 205, which is specifically used to determine the target cloud server from multiple cloud servers in the preset cloud game based on the rendering complexity of the target virtual game scene space in the preset cloud game.
[0080] Optionally, the receiving module 201 is specifically used to receive the number of concurrent rendering paths sent by the scheduling server; wherein, the number of concurrent rendering paths is determined by the scheduling server based on the rendering complexity of each virtual game world in the preset cloud game and the virtual machine configuration information of the cloud server.
[0081] Module 204 is specifically used to create multiple preset virtual game instances in a cloud server based on the number of concurrent rendering paths, wherein the number of preset virtual game instances is less than or equal to the number of concurrent rendering paths.
[0082] Optionally, module 205 is specifically used to: determine whether the client meets the instance allocation conditions as determined by the scheduling server in the following manner:
[0083] If a client's first online request is detected, it is determined that the client meets the instance allocation conditions; or, if a user operation command sent by the client for the first time is detected, it is determined that the client meets the instance allocation conditions.
[0084] like Figure 5 As shown, the rendering data includes: display rendering data; the device also includes: an encoding module 206, used to convert the display rendering data into image data, and then perform image encoding to obtain image encoded data;
[0085] The sending module 203 is specifically used to send image encoded data to the client using a point-to-point transmission channel.
[0086] Optionally, the encoding module 206 is specifically used to convert the audio rendering data into an audio encoding format, and then perform audio encoding to obtain audio encoded data;
[0087] The sending module 203 is specifically used to send image encoded data and audio encoded data to the client using a point-to-point transmission channel.
[0088] The above-described device is used to execute the method provided in the foregoing embodiments, and its implementation principle and technical effect are similar, so they will not be described again here.
[0089] These modules can be one or more integrated circuits configured to implement the above methods, such as one or more Application Specific Integrated Circuits (ASICs), one or more microprocessors, or one or more Field Programmable Gate Arrays (FPGAs). Alternatively, when a module is implemented using processing element scheduler code, the processing element can be a general-purpose processor, such as a Central Processing Unit (CPU) or other processor capable of calling program code. Furthermore, these modules can be integrated together as a system-on-a-chip (SOC).
[0090] Figure 6 This is a schematic diagram of the structure of a game rendering device provided in an embodiment of this application. The game rendering device can be integrated into a terminal device or a chip of a terminal device.
[0091] like Figure 6 As shown, the game's rendering devices include: processor 501, bus 502, and storage medium 503.
[0092] Processor 501 is used to store programs, and processor 501 calls the programs stored in storage medium 503 to execute the above-mentioned programs. Figures 1-4 The corresponding method implementation is similar in specific implementation and technical effect, and will not be repeated here. The executed method may include:
[0093] The receiving client sends user operation instructions for a target virtual game scene space in a preset cloud game via a pre-established point-to-point transmission channel; the point-to-point transmission channel is the transmission channel between the client and the target virtual game instance, wherein the target virtual game instance is the virtual game instance corresponding to the target virtual game scene space;
[0094] Using the target virtual game instance, and based on the user operation instructions, obtain the rendering data generated by the target virtual game scene space;
[0095] The rendering data is sent to the client using the point-to-point transmission channel, so that the client can draw the interface of the target virtual game scene space based on the rendering data.
[0096] In one feasible implementation, before executing the user operation instructions sent by the receiving client via a pre-established point-to-point transmission channel to a target virtual game scene space in a preset cloud game, the processor 501 is further configured to:
[0097] Receive the instance allocation result sent by the scheduling server; the instance allocation result includes: the instance identifier of the target virtual game instance, and the user identifier corresponding to the client;
[0098] Based on the user identifier and the instance identifier of the target virtual game instance, a point-to-point transmission channel is established between the client and the target virtual game instance;
[0099] The instance allocation result is obtained by the scheduling server in the following manner:
[0100] If the client is detected to meet the instance allocation conditions, then an instance is allocated to the client, and the instance allocation result is obtained.
[0101] In one feasible implementation, the instance identifier of the target virtual game instance in the instance allocation result is: the identifier of the idle instance determined by the scheduling server from the plurality of preset virtual game instances of the cloud server.
[0102] In a feasible implementation, the instance allocation result further includes: the identifier of the target cloud server, which is determined to be the scheduling server in the following manner:
[0103] Based on the rendering complexity of the target virtual game scene space in the preset cloud game, the target cloud server is determined from multiple cloud servers in the preset cloud game.
[0104] In one feasible implementation, before executing the instance allocation result sent by the receiving scheduling server, the processor 501 is further configured to:
[0105] The system receives the number of concurrent rendering paths sent by the scheduling server; wherein the number of concurrent rendering paths is determined by the scheduling server based on the rendering complexity of each virtual game world in the preset cloud game and the virtual machine configuration information of the cloud server.
[0106] Based on the number of concurrent rendering paths, the plurality of preset virtual game instances are established in the cloud server, wherein the number of the plurality of preset virtual game instances is less than or equal to the number of concurrent rendering paths.
[0107] In a feasible implementation, the processor 501 determines the client as meeting the instance allocation conditions for the scheduling server in the following manner:
[0108] If the client's initial online request is detected, then the client is determined to meet the instance allocation conditions; or,
[0109] If a user operation command sent by the client for the first time is detected, it is determined that the client meets the instance allocation conditions.
[0110] In one feasible implementation, the rendering data includes: display rendering data; before executing the step of sending the rendering data to the client using the point-to-point transmission channel, the processor 501 is further configured to:
[0111] After converting the display rendering data into image data, image encoding is performed to obtain image encoded data;
[0112] Sending the rendering data to the client using the point-to-point transmission channel includes:
[0113] The image encoded data is sent to the client using the point-to-point transmission channel.
[0114] In one feasible implementation, the rendering data further includes: audio rendering data; before the processor 501 executes the step of sending the image encoded data to the client using the point-to-point transmission channel, the method further includes:
[0115] After converting the audio rendering data into an audio encoding format, audio encoding is performed to obtain audio encoded data;
[0116] When the processor 501 executes the step of sending the image encoded data to the client using the point-to-point transmission channel, it is specifically used for:
[0117] The image encoded data and the audio encoded data are sent to the client using the point-to-point transmission channel.
[0118] Optionally, this application also provides a program product, such as a storage medium storing a computer program, including a program that, when run by a processor, causes the processor to perform the following steps:
[0119] The receiving client sends user operation instructions for a target virtual game scene space in a preset cloud game via a pre-established point-to-point transmission channel; the point-to-point transmission channel is the transmission channel between the client and the target virtual game instance, wherein the target virtual game instance is the virtual game instance corresponding to the target virtual game scene space;
[0120] Using the target virtual game instance, and based on the user operation instructions, obtain the rendering data generated by the target virtual game scene space;
[0121] The rendering data is sent to the client using the point-to-point transmission channel, so that the client can draw the interface of the target virtual game scene space based on the rendering data.
[0122] In one feasible implementation, before executing the user operation instructions sent by the receiving client via a pre-established point-to-point transmission channel for a target virtual game scene space in a preset cloud game, the processor is further configured to:
[0123] Receive the instance allocation result sent by the scheduling server; the instance allocation result includes: the instance identifier of the target virtual game instance, and the user identifier corresponding to the client;
[0124] Based on the user identifier and the instance identifier of the target virtual game instance, a point-to-point transmission channel is established between the client and the target virtual game instance;
[0125] The instance allocation result is obtained by the scheduling server in the following manner:
[0126] If the client is detected to meet the instance allocation conditions, then an instance is allocated to the client, and the instance allocation result is obtained.
[0127] In one feasible implementation, the instance identifier of the target virtual game instance in the instance allocation result is: the identifier of the idle instance determined by the scheduling server from the plurality of preset virtual game instances of the cloud server.
[0128] In a feasible implementation, the instance allocation result further includes: the identifier of the target cloud server, which is determined to be the scheduling server in the following manner:
[0129] Based on the rendering complexity of the target virtual game scene space in the preset cloud game, the target cloud server is determined from multiple cloud servers in the preset cloud game.
[0130] In one feasible implementation, the processor is further configured to: Before executing the instance allocation result sent by the receiving scheduling server, the processor is configured to:
[0131] The system receives the number of concurrent rendering paths sent by the scheduling server; wherein the number of concurrent rendering paths is determined by the scheduling server based on the rendering complexity of each virtual game world in the preset cloud game and the virtual machine configuration information of the cloud server.
[0132] Based on the number of concurrent rendering paths, the plurality of preset virtual game instances are established in the cloud server, wherein the number of the plurality of preset virtual game instances is less than or equal to the number of concurrent rendering paths.
[0133] In one feasible implementation, the processor determines that the client meets the instance allocation conditions for the scheduling server in the following manner:
[0134] If the client's initial online request is detected, then the client is determined to meet the instance allocation conditions; or,
[0135] If a user operation command sent by the client for the first time is detected, it is determined that the client meets the instance allocation conditions.
[0136] In one feasible implementation, the rendering data includes: display rendering data; before the processor executes the step of sending the rendering data to the client using the point-to-point transmission channel, it is further configured to:
[0137] After converting the display rendering data into image data, image encoding is performed to obtain image encoded data;
[0138] Sending the rendering data to the client using the point-to-point transmission channel includes:
[0139] The image encoded data is sent to the client using the point-to-point transmission channel.
[0140] In one feasible implementation, the rendering data further includes: audio rendering data; before the processor executes the step of sending the image encoded data to the client using the point-to-point transmission channel, the method further includes:
[0141] After converting the audio rendering data into an audio encoding format, audio encoding is performed to obtain audio encoded data;
[0142] When the processor executes the step of sending the image encoded data to the client using the point-to-point transmission channel, it is specifically used for:
[0143] The image encoded data and the audio encoded data are sent to the client using the point-to-point transmission channel.
[0144] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.
[0145] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0146] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or in a combination of hardware and software functional units.
[0147] The integrated units implemented as software functional units described above can be stored in a computer-readable storage medium. These software functional units, stored in a storage medium, include several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor to execute some steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
Claims
1. A method of rendering a game, the method comprising: The method is applied to a target cloud server, and the target cloud server includes a plurality of preset virtual game instances. Receiving a user operation instruction for a target virtual game scene space in a preset cloud game sent by a client through a pre-established point-to-point transmission channel; the point-to-point transmission channel is a transmission channel between the client and a target virtual game instance, wherein the target virtual game instance is a virtual game instance corresponding to the target virtual game scene space; Using the target virtual game instance, rendering data generated by the target virtual game scene space is obtained according to the user operation instruction; The rendering data is sent to the client through the point-to-point transmission channel, so that the client performs interface rendering of the target virtual game scene space according to the rendering data; Before the receiving a user operation instruction for a target virtual game scene space in a preset cloud game sent by a client through a pre-established point-to-point transmission channel, the method further comprises: Receiving an instance allocation result sent by a scheduling server; the instance allocation result includes an instance identifier of the target virtual game instance and a user identifier corresponding to the client; the instance identifier of the target virtual game instance is an instance identifier of an idle instance determined by the scheduling server from the plurality of preset virtual game instances of the target cloud server; the instance identifier of the target virtual game instance and the user identifier corresponding to the client uniquely correspond; Based on the user identifier and the instance identifier of the target virtual game instance, the point-to-point transmission channel between the client and the target virtual game instance is established; Wherein, the instance allocation result is obtained by the scheduling server in the following way: If it is detected that the client satisfies the instance allocation condition, the client is allocated an instance to obtain an instance allocation result; Determining that the client satisfies the instance allocation condition is determined by the scheduling server in the following way: If a first online request of the client is detected, it is determined that the client satisfies the instance allocation condition; or, If the user operation instruction sent by the client for the first time is detected, it is determined that the client satisfies the instance allocation condition; The instance allocation result also includes an identifier of the target cloud server, which is determined by the scheduling server in the following way: According to the rendering complexity of the target virtual game scene space in the preset cloud game, the target cloud server is determined from a plurality of cloud servers in the preset cloud game.
2. The method of claim 1, wherein, Before the receiving the instance allocation result sent by the scheduling server, the method further comprises: Receiving a concurrent rendering path number sent by the scheduling server; wherein the concurrent rendering path number is determined by the scheduling server according to the rendering complexity of each virtual game world in the preset cloud game and the virtual machine configuration information of the cloud server; Based on the concurrent rendering path, a plurality of preset virtual game instances are established in the cloud server, wherein the number of the plurality of preset virtual game instances is less than or equal to the concurrent rendering path.
3. The method of claim 1, wherein, The rendering data includes display rendering data; before the rendering data is sent to the client by using the point-to-point transmission channel, the method further includes: After the display rendering data is converted into image data, image encoding is performed to obtain image encoding data; The rendering data is sent to the client by using the point-to-point transmission channel, including: The image encoding data is sent to the client by using the point-to-point transmission channel.
4. The method of claim 3, wherein, The rendering data further includes audio rendering data; before the image encoding data is sent to the client by using the point-to-point transmission channel, the method further includes: After the audio rendering data is converted into an audio encoding format, audio encoding is performed to obtain audio encoding data; The rendering data is sent to the client by using the point-to-point transmission channel, including: The image encoding data and the audio encoding data are sent to the client by using the point-to-point transmission channel.
5. A rendering apparatus of a game, characterized by, The device includes a receiving module, an obtaining module, and a sending module, wherein: The receiving module is configured to receive user operation instructions for a target virtual game scene space in a preset cloud game sent by a client by using a pre-established point-to-point transmission channel; the point-to-point transmission channel is a transmission channel between the client and a target virtual game instance, wherein the target virtual game instance is a virtual game instance corresponding to the target virtual game scene space; The obtaining module is configured to obtain rendering data generated by the target virtual game scene space by using the target virtual game instance according to the user operation instructions; The sending module is configured to send the rendering data to the client by using the point-to-point transmission channel, so that the client performs interface rendering of the target virtual game scene space according to the rendering data; The device further includes an establishing module and a determining module; The receiving module is further configured to receive an instance allocation result sent by a scheduling server; the instance allocation result includes an instance identifier of the target virtual game instance and a user identifier corresponding to the client; the instance identifier of the target virtual game instance is an instance identifier of an idle instance determined by the scheduling server from the plurality of preset virtual game instances of the target cloud server; the instance identifier of the target virtual game instance and the user identifier corresponding to the client uniquely correspond to each other; The establishing module is further configured to establish the point-to-point transmission channel between the client and the target virtual game instance based on the user identifier and the instance identifier of the target virtual game instance; The instance allocation result is obtained by the scheduling server in the following manner: If it is detected that the client satisfies an instance allocation condition, the client is allocated an instance to obtain an instance allocation result; The determining module is specifically configured to determine that the client satisfies the instance allocation condition in the following manner: If it is detected that the client has a first online request, it is determined that the client satisfies the instance allocation condition; or, If it is detected that the client has a first user operation instruction, it is determined that the client satisfies the instance allocation condition. The determining module is specifically configured to determine the target cloud server from a plurality of cloud servers in the preset cloud game according to a rendering complexity of a target virtual game scene space in the preset cloud game.
6. A rendering device of a game, characterized by, The device comprises a processor, a storage medium and a bus, the storage medium stores machine readable instructions executable by the processor, when the rendering device of the game is running, the processor and the storage medium communicate through the bus, the processor executes the machine readable instructions to execute the method of any one of claims 1-4.
7. A storage medium, characterized by The storage medium stores a computer program, when the computer program is executed by the processor, the method of any one of claims 1-4 is executed.