WO2022127890A1 - Rendering method based on cloud service, and related device therefor - Google Patents

Rendering method based on cloud service, and related device therefor Download PDF

Info

Publication number
WO2022127890A1
WO2022127890A1 PCT/CN2021/139019 CN2021139019W WO2022127890A1 WO 2022127890 A1 WO2022127890 A1 WO 2022127890A1 CN 2021139019 W CN2021139019 W CN 2021139019W WO 2022127890 A1 WO2022127890 A1 WO 2022127890A1
Authority
WO
WIPO (PCT)
Prior art keywords
rendering
node
client
video stream
service node
Prior art date
Application number
PCT/CN2021/139019
Other languages
French (fr)
Chinese (zh)
Inventor
陈普
Original Assignee
华为云计算技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为云计算技术有限公司 filed Critical 华为云计算技术有限公司
Publication of WO2022127890A1 publication Critical patent/WO2022127890A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • H04N21/44012Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving rendering scenes according to scene graphs, e.g. MPEG-4 scene graphs
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N13/00Stereoscopic video systems; Multi-view video systems; Details thereof
    • H04N13/10Processing, recording or transmission of stereoscopic or multi-view image signals
    • H04N13/194Transmission of image signals
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/234Processing of video elementary streams, e.g. splicing of video streams, manipulating MPEG-4 scene graphs
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/234Processing of video elementary streams, e.g. splicing of video streams, manipulating MPEG-4 scene graphs
    • H04N21/23412Processing of video elementary streams, e.g. splicing of video streams, manipulating MPEG-4 scene graphs for generating or manipulating the scene composition of objects, e.g. MPEG-4 objects
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/60Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client 
    • H04N21/63Control signaling related to video distribution between client, server and network components; Network processes for video distribution between server and clients or between remote clients, e.g. transmitting basic layer and enhancement layers over different transmission paths, setting up a peer-to-peer communication via Internet between remote STB's; Communication protocols; Addressing
    • H04N21/647Control signaling between network components and server or clients; Network processes for video distribution between server and clients, e.g. controlling the quality of the video stream, by dropping packets, protecting content from unauthorised alteration within the network, monitoring of network load, bridging between two different networks, e.g. between IP and wireless
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/60Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client 
    • H04N21/63Control signaling related to video distribution between client, server and network components; Network processes for video distribution between server and clients or between remote clients, e.g. transmitting basic layer and enhancement layers over different transmission paths, setting up a peer-to-peer communication via Internet between remote STB's; Communication protocols; Addressing
    • H04N21/647Control signaling between network components and server or clients; Network processes for video distribution between server and clients, e.g. controlling the quality of the video stream, by dropping packets, protecting content from unauthorised alteration within the network, monitoring of network load, bridging between two different networks, e.g. between IP and wireless
    • H04N21/64784Data processing by the network

Definitions

  • the present application relates to the technical field of computer graphics, and in particular, to a cloud service-based rendering method and related devices.
  • a browser on a certain terminal device can play dynamic content such as large-scale three-dimensional (3-dimension, 3D) games and high-definition multimedia videos, thereby providing users with a better viewing experience.
  • dynamic content such as large-scale three-dimensional (3-dimension, 3D) games and high-definition multimedia videos, thereby providing users with a better viewing experience.
  • an image processing unit graphics processing unit, GPU
  • GPU graphics processing unit
  • the computing power of the GPU of such devices is generally poor, so such devices with limited computing power perform video rendering through their own GPUs During processing, it is often impossible to render videos with better quality, resulting in poor user experience.
  • Embodiments of the present application provide a cloud service-based rendering method and related devices, which can render a video with better quality and play it on a terminal device with limited computing power, thereby improving user experience.
  • a first aspect of the embodiments of the present application provides a rendering method based on a cloud service, the method comprising:
  • a client such as a browser
  • the client can display certain content in the entire screen area (for example, display a three-dimensional web page, including static content and dynamic content) for the user to watch and use.
  • the client determines that the GPU of its terminal device cannot render the video stream that needs to be played in the target display area, it sends a rendering instruction for the target display area to the service node, and the rendering instruction is used to instruct the server node to complete the video stream. remote rendering to play the video stream in the target display area.
  • the service node After receiving the client's rendering instruction for the target display area, the service node can determine, based on the rendering instruction, that the client requests remote rendering of the target display area, and then generates a rendering request, which is used to instruct the rendering node to call its own GPU to display the target. Regions are rendered to generate a video stream that includes multiple playback frames. The service node then sends the render request to the render node.
  • the rendering node After the rendering node receives the rendering request, it completes the rendering of the video stream through the GPU, thereby obtaining the video stream.
  • the service node sends notification information carrying the streaming address of the video stream to the client, where the notification information is used to instruct the client to obtain the video stream from the streaming address and play the video stream in the target display area.
  • the client can obtain the pull stream address from the notification information, and obtain the video stream from the rendering node based on the pull stream address, so as to play the video stream in the target display area.
  • the service node can send a rendering request to the rendering node, so that the rendering node invokes its own GPU to render the target display area to obtain a video stream. Then, the service node sends notification information carrying the streaming address of the video stream to the client, so that the client obtains the video stream from the rendering node based on the streaming address, so as to play the video stream in the target display area.
  • the GPU of the rendering node since the rendering processing of the video stream is completed by a remote rendering node, the GPU of the rendering node generally has relatively strong computing power, and can render a video stream with better quality. Therefore, even if the computing power of the terminal device where the client is located is limited, it can obtain the rendered video stream with better quality from the rendering unit, and play the video stream in the target display area, thereby improving user experience.
  • the rendering instruction carries rendering demand information
  • the method further includes: the service node selects a rendering node matching the rendering demand information from the rendering resource pool.
  • the rendering resource pool includes multiple rendering nodes, and GPUs of different rendering nodes have different computing capabilities.
  • the service node may determine the rendering requirement information from the rendering instruction, where the rendering requirement information is used to indicate the computing power required for rendering the target display area. Therefore, the service node can select the rendering node matching the rendering requirement information from the rendering resource pool. In this way, since the GPU of the selected rendering node has sufficient computing power, a video stream with better quality can be rendered.
  • the rendering instruction carries rendering demand information
  • the method further includes: the service node invokes the cloud service to create a rendering node matching the rendering demand information.
  • the service node may determine the rendering requirement information from the rendering instruction, where the rendering requirement information is used to indicate the computing power required for rendering the target display area. Therefore, the service node can directly call the cloud service to create a rendering node that matches the rendering demand information. In this way, since the GPU of the created rendering node has sufficient computing power, a video stream with better quality can be rendered.
  • the method before the service node receives the rendering request from the client for the target display area, the method further includes: the service node provides an access entry for the 3D web page; the service node receives the access request from the client for the 3D web page; serving The node sends a rendering instruction of the 3D webpage to the client according to the access request.
  • the service node may provide the client with an access entry for the three-dimensional web page, so that the client sends an access request for the three-dimensional web page to the service node through the access entry. Then, after determining that the client needs to access the three-dimensional webpage based on the access request, the service node sends a rendering instruction of the three-dimensional webpage to the client, so that the client renders the entire screen area to generate the three-dimensional webpage.
  • the method before the service node sends the notification information carrying the streaming address of the video stream to the client, the method further includes: the service node receives the streaming address sent by the rendering node.
  • the rendering node after the rendering node completes rendering and obtains the video stream, it can set a dedicated streaming address for the video stream, and send the streaming address to the service node, so that the service node forwards the streaming address to the client. Further, the client can obtain the rendered video stream from the rendering node based on the pull stream address.
  • the method before the service node sends the notification information carrying the streaming address of the video stream to the client, the method further includes: the service node pre-records the streaming address.
  • the service node and the rendering node record the streaming address set for the video stream in advance. Therefore, after the rendering node completes rendering and obtains the video stream, the service node can directly send the streaming address of the video stream to the client, so that the client can obtain the rendered video stream from the rendering node based on the streaming address.
  • the rendering node includes a virtual machine provided with a GPU, a container, and a bare metal server provided in a data center.
  • the rendering node is a physical server provided with a GPU.
  • the embodiments of the present application have the following advantages:
  • a second aspect of the embodiments of the present application provides a rendering device based on cloud services, the device is the aforementioned service node, and the device includes: a receiving module for receiving a rendering instruction from a client for a target display area; a sending module is used to send a rendering request to the rendering node according to the rendering instruction, and the rendering request is used to instruct the rendering node to call the image processing unit GPU arranged on the rendering node to render the target display area to generate a video stream including a plurality of playback pictures; the sending module, It is also used to send notification information carrying the streaming address of the video stream to the client, where the notification information is used to instruct the client to obtain the video stream from the streaming address and play the video stream in the target display area.
  • the service node can send a rendering request to the rendering node, so that the rendering node invokes its own GPU to render the target display area to obtain a video stream. Then, the service node sends notification information carrying the streaming address of the video stream to the client, so that the client obtains the video stream from the rendering node based on the streaming address, so as to play the video stream in the target display area.
  • the GPU of the rendering node since the rendering processing of the video stream is completed by a remote rendering node, the GPU of the rendering node generally has relatively strong computing power, and can render a video stream with better quality. Therefore, even if the computing power of the terminal device where the client is located is limited, it can obtain the rendered video stream with better quality from the rendering unit, and play the video stream in the target display area, thereby improving user experience.
  • the rendering instruction carries rendering requirement information
  • the apparatus further includes: a processing module configured to select a rendering node matching the rendering requirement information from the rendering resource pool.
  • the rendering instruction carries rendering requirement information
  • the apparatus further includes: a processing module configured to call a cloud service to create a rendering node matching the rendering requirement information.
  • the rendering node includes a virtual machine provided with a GPU, a container, and a bare metal server provided in a data center.
  • the rendering node is a physical server provided with a GPU.
  • the sending module is further configured to provide an access entry for the three-dimensional web page; the receiving module is further configured to receive an access request from the client for the three-dimensional web page; the sending module is further configured to send the client to the client according to the access request Sends rendering instructions for 3D web pages.
  • the receiving module is further configured to receive the pull stream address sent by the rendering node.
  • the processing module is further configured to record the pull stream address in advance.
  • a third aspect of the embodiments of the present application provides a network device, where the network device includes: a processor and a memory;
  • the processor is configured to execute computer-executable instructions stored in the memory, so that the network device implements the method described in the first aspect or any possible implementation manner of the first aspect.
  • a fourth aspect of the embodiments of the present application is a computer storage medium, comprising computer-readable instructions, when the computer-readable instructions are executed, the method described in the first aspect or any possible implementation manner of the first aspect is implemented .
  • a fifth aspect of the embodiments of the present application is a computer program product containing instructions, which, when executed on a computer, cause the computer to execute the method described in the first aspect or any possible implementation manner of the first aspect.
  • the service node may send a rendering request to the rendering node, so that the rendering node invokes its own GPU to perform rendering processing on the target display area to obtain a video stream. Then, the service node sends notification information carrying the streaming address of the video stream to the client, so that the client obtains the video stream from the rendering node based on the streaming address, so as to play the video stream in the target display area.
  • the GPU of the rendering node since the rendering processing of the video stream is completed by a remote rendering node, the GPU of the rendering node generally has relatively strong computing power, and can render a video stream with better quality. Therefore, even if the computing power of the terminal device where the client is located is limited, it can obtain the rendered video stream with better quality from the rendering unit, and play the video stream in the target display area, thereby improving user experience.
  • FIG. 1 is a schematic diagram of a cloud service system provided by an embodiment of the present application.
  • FIG. 2 is a schematic flowchart of a rendering method based on a cloud service provided by an embodiment of the present application
  • FIG. 3 is another schematic flowchart of a rendering method based on a cloud service provided by an embodiment of the present application
  • FIG. 4 is another schematic flowchart of a rendering method based on a cloud service provided by an embodiment of the present application
  • FIG. 5 is a schematic structural diagram of a rendering apparatus based on a cloud service provided by an embodiment of the present application
  • FIG. 6 is a schematic structural diagram of a network device provided by an embodiment of the present application.
  • the naming or numbering of the steps in this application does not mean that the steps in the method flow must be executed in the time/logical sequence indicated by the naming or numbering, and the named or numbered process steps can be implemented according to the The technical purpose is to change the execution order, as long as the same or similar technical effects can be achieved.
  • the division of modules in this application is a logical division. In practical applications, there may be other divisions. For example, multiple modules may be combined or integrated into another system, or some features may be ignored. , or not implemented, in addition, the shown or discussed mutual coupling or direct coupling or communication connection may be through some ports, and the indirect coupling or communication connection between modules may be electrical or other similar forms. There are no restrictions in the application.
  • modules or sub-modules described as separate components may or may not be physically separated, may or may not be physical modules, or may be distributed into multiple circuit modules, and some or all of them may be selected according to actual needs. module to achieve the purpose of the solution of this application.
  • the web pages displayed by browsers include both static content such as text information, and dynamic content such as high-definition videos, so as to satisfy users' needs various needs.
  • an image processing unit graphics processing unit, GPU
  • GPU graphics processing unit
  • the computing power of the GPU of such devices is generally poor, so such devices with limited computing power perform video rendering through their own GPUs During processing, it is often impossible to render videos with better quality, resulting in poor user experience.
  • FIG. 1 is a schematic diagram of a cloud service system provided by an embodiment of the present application.
  • the cloud service system includes: a client, a service node, and a rendering node. Communication can be achieved between the client, the service node, and the rendering node, that is, information transmission can be achieved between them. It can be seen that the client can communicate with the rendering node directly, or communicate with the rendering node through the service node. The following will introduce the client, service node and rendering node respectively:
  • the client is usually deployed on a certain terminal device, that is, the client is an application running on the terminal device, such as a browser, so the user can start the browser on the terminal device to browse three-dimensional web pages through the browser.
  • HTTP hypertext transfer protocol
  • the client and the rendering node can be through Websocket, hypertext live streaming (http live streaming, HLS), webrtc, etc. to complete information transmission
  • the web page displayed by the client can be described by hyper text markup language (HTML), and the programming language supported by the client can be javascript or other types of Programming language.
  • the client can detect the rendering capability of the terminal device where it is located based on javascript, that is, the computing capability of the GPU of the terminal device where it is located, so as to determine whether the GPU can render dynamic content with better quality, for example, Video streaming and more.
  • javascript that is, the computing capability of the GPU of the terminal device where it is located
  • a service node is a network (Web) service node, which can be deployed in various ways.
  • a service node can be a separate physical server (also called a network device), or a service node can also be a certain server.
  • a virtual machine loaded on a physical server for example, a service node can also be a container loaded on a physical server, and so on.
  • Serving nodes can serve pages to clients and rendering nodes, such as serving pages with static content, serving pages with dynamic content, and serving pages with static content and dynamic content, and so on.
  • the service node can send a rendering program for rendering a certain webpage to the client, and the client can execute the rendering program to render the webpage for display.
  • Rendering nodes can also be deployed in various ways.
  • a rendering node can be a separate physical server, or a rendering node can also be a virtual machine loaded on a physical server.
  • a virtual machine loaded on a physical server could be a container loaded on a physical server, etc.
  • both the rendering node and the service node are virtual machines (or containers), they can be deployed on the same physical server or on different physical servers, which is not limited here.
  • the rendering node contains a GPU, so the rendering node can execute the rendering program on behalf of the client, thereby realizing remote rendering, and after the rendering is completed and the video stream is obtained, the video stream can be sent to the client for display. .
  • the client and the rendering unit support the same three-dimensional rendering programming technology, for example, a network graphics library (web graphics library, WebGL) technology and so on.
  • the rendering program can be presented in a WebGL program or in other forms.
  • the WebGL program can write a WebGL interface through javascript, and the program can include the rendering data to be used during rendering and the rendering operations to be performed, wherein the rendering data can include the rendering data to be rendered.
  • the target's vertex coordinates, triangle index, color, metalness, and roughness data, and rendering operations can include a series of rasterization operations, such as coordinate transformation, geometric discretization, and so on.
  • the client executes the rendering program involved in this application may be understood as “the GPU of the terminal device where the client is located executes the rendering program”.
  • the rendering node executes the rendering program can be understood as “the GPU of the rendering node executes the rendering program”, which will not be repeated in the following.
  • FIG. 2 is a schematic flowchart of a rendering method based on a cloud service provided by an embodiment of the present application. As shown in FIG. 2 , the method includes:
  • the service node provides an access entry for a three-dimensional webpage.
  • the service node can provide the client with an access portal for the 3D web page, so that the client terminal displays the access portal on the screen. If the user needs to access the 3D web page, the user can input a 3D page access request to the access portal.
  • the access portal of a 3D web page is usually a web page containing static content, so the computing power required to render the access portal is not high, so the client can complete the rendering processing of the access portal locally.
  • the service node can send the rendering program of the access entry of the three-dimensional page to the client, and the client directly executes the rendering program, thereby rendering the access entry of the three-dimensional page, and displays the access entry on the screen of the terminal device to for users to use.
  • a three-dimensional web page is a product website containing text (information describing the product, etc.) and video stream (showing the shape of the product, etc.), and users can browse the specific information of the product on the product website.
  • the access entrance of the 3D web page may be a login page, and after the user enters the account password on the login page, he can enter the product website for browsing.
  • a three-dimensional web page is a three-dimensional building constructed based on virtual reality (VR) technology
  • VR virtual reality
  • the access entrance of the 3D webpage may be the initial image of the 3D building, such as the door of the 3D building. After the user clicks on the door, the user can enter the interior of the 3D building for tour.
  • the service node receives an access request from the client for the three-dimensional webpage.
  • the user may input an access request for the three-dimensional web page to the client.
  • the access request may be the aforementioned user's login operation or the user's page click operation, or may be an operation for implementing functions such as webpage jumping, adding a website to favorites, popping up a prompt box, and audio output. Therefore, after receiving the access request for the three-dimensional web page through the access portal, the client sends the access request for the three-dimensional web page to the service node.
  • the service node sends a rendering instruction of the three-dimensional webpage to the client according to the access request.
  • the service node After receiving the access request from the client, the service node can determine that the client needs to access the 3D web page, and then sends a rendering instruction of the 3D web page to the client. Rendering of 3D web pages.
  • the service node can also send the rendering program of the 3D web page to the client.
  • the rendering program of the 3D web page and the rendering instruction of the 3D web page may be sent to the client synchronously, or may be sent to the client asynchronously.
  • the service node first sends the rendering instruction of the 3D webpage to the client, and then sends the rendering program of the 3D webpage to the client.
  • the service node first sends the rendering program of the 3D webpage to the client, and then sends the rendering instruction of the 3D webpage to the client.
  • the service node sends the rendering program of the 3D web page and the rendering instruction of the 3D web page to the client together, which is not limited here.
  • the client detects the local rendering capability according to the rendering instruction of the 3D webpage, and determines whether the local rendering capability meets the requirements.
  • the client After the client receives the rendering instruction of the 3D web page from the service node, it detects the local rendering capability.
  • the client can detect local rendering capabilities in various ways: for example, the client can try to run a rendering program for a small video (the rendering program can be preset in the client, or it can be sent to the client by the service node. There is no restriction), and obtain parameters such as the power consumption and frame rate of the GPU running the rendering program, and determine the local rendering capability based on these parameters, that is, the computing capability of the GPU of the terminal device where the client is located.
  • the client can directly obtain the model of the graphics card (including the GPU) of the terminal device where it is located, so as to determine the local rendering capability.
  • 3D web pages usually include static content such as text information and dynamic content such as video streams.
  • the text information is used to represent the static content
  • the video stream is used to represent the dynamic content. Therefore, in the rendering program of the 3D web page, the client can determine the computing power required for executing the rendering program for text information and the computing power required for executing the rendering program for video streams.
  • the rendering program for executing text information needs to be The computing power is less than the computing power required to execute the rendering program of the video stream. If it is determined that the computing capability of the GPU of the terminal device where the client is located is greater than the computing capability required to execute the rendering program of the video stream, it means that the client determines that the local rendering capability meets the requirements, and the client can render the 3D webpage locally. That is, the rendering program of the 3D web page is directly executed, thereby rendering the 3D web page, and displaying the 3D web page (including text information and video stream) on the screen. The rest of the area outside the area is used to display textual information.
  • step 205 If it is determined that the computing capability of the GPU of the terminal device where the client is located is less than the computing capability required for executing the rendering program of the video stream, it means that the client determines that the local rendering capability does not meet the requirements, and step 205 is performed.
  • the client determines that the local rendering capability does not meet the requirements, send a rendering instruction for the target display area to the service node.
  • the client When the client determines that the local rendering capability does not meet the requirements, it implements the rendering processing of the text information locally, and requests the remote rendering processing of the video stream from the service node. Specifically, the client executes a rendering program for text information, thereby rendering the text information, and displaying the text information in the remaining areas of the screen except the target display area. At the same time, the client can also send a rendering instruction for the target display area to the service node (which can also be understood as a rendering instruction of the video stream), and the rendering instruction is used to instruct the server node to complete the remote rendering of the video stream, so that the target display play the video stream in the zone.
  • the service node which can also be understood as a rendering instruction of the video stream
  • the service node sends a rendering request to the rendering node according to the rendering instruction for the target display area.
  • the service node After the service node receives the rendering instruction from the client for the target display area, it sends a rendering request to the rendering node, and the rendering request is used to instruct the rendering node to call the GPU set on the rendering node to render the target display area to generate a rendering including multiple playback images. video stream.
  • the rendering request includes the above-mentioned rendering instructions.
  • the service node can perform format conversion on the above rendering instruction, and convert the received rendering instruction into a format suitable for rendering the image by the rendering node.
  • the service node may determine a render node for implementing remote rendering processing.
  • the rendering instruction for the target display area carries the rendering requirement information
  • the rendering requirement information is used to indicate the computing power required for rendering the target display area, that is, the computing power required for rendering the video stream. Therefore, the service node can determine the rendering node that implements remote rendering processing in various ways according to the rendering demand information.
  • a rendering resource pool is pre-deployed in the cloud service system.
  • Render nodes can form virtual machine clusters, container clusters, physical server clusters, and more.
  • the GPUs of different rendering nodes have different computing capabilities.
  • the service node can select a rendering node that matches the rendering demand information in the rendering resource pool to implement remote rendering processing of video streams.
  • the service node can directly call the cloud service in the cloud service system to create a new rendering node.
  • the rendering node can be a virtual machine, container, etc., and the rendering node matches the rendering demand information, so it can be used to implement Remote rendering processing of video streams.
  • the rendering node prepares for rendering according to the rendering request.
  • the rendering node After the rendering node receives the rendering request from the service node, it determines that it needs to meet the remote rendering requirements of the client, so it will start a series of rendering preparations related to the client.
  • the rendering node is a virtual machine, container or physical server with GPU, that is, the system of the rendering node itself provides a running environment for the program related to the client (for example, browser kernel, etc.), so the rendering node It is also possible to run a program related to the client, and after the preparation, the rendering node can replace the client to perform the rendering processing of the video stream.
  • the rendering node obtains a rendering program of the video stream from the service node.
  • the service node stores the rendering program of the three-dimensional web page, that is, the rendering program that stores the video stream. Therefore, after the rendering node completes the rendering preparation, the rendering program of the video stream can be obtained from the service node.
  • the rendering node executes a rendering program of the video stream, so as to generate a video stream including a plurality of playback pictures, and set a stream pull address for the video stream.
  • the rendering node After obtaining the rendering program of the video stream, the rendering node invokes the GPU set in the rendering node to execute the rendering program of the video stream, thereby generating a video stream that can be played in the target display area.
  • the rendering node can set a dedicated streaming address for the video stream.
  • the streaming address of the video stream includes the Internet Protocol (IP) address and port of the rendering node, the client's token (token), the current session The identity document (ID), the ID of the video stream and other information.
  • the service node receives the streaming address of the video stream sent by the rendering node.
  • the rendering node After the rendering node obtains the pull stream address of the video stream, it sends the pull stream address of the video stream to the service node.
  • the service node sends notification information carrying the streaming address of the video stream to the client.
  • the service node After receiving the pull stream address of the video stream, the service node wraps the pull stream address into notification information, and the notification information is used to instruct the client to obtain the video stream from the pull stream address and play the video stream in the target display area. Then, the service node sends the notification information to the client.
  • the client obtains the video stream from the streaming address, and plays the video stream in the target display area.
  • the client After receiving the notification information from the service node, the client can obtain the streaming address of the video stream from the notification information. Then, obtain the encoded video stream from the rendering node based on the pull stream address, decode the encoded video stream, and finally play the decoded video stream in the target display area. In this way, the client can play the video stream in the target display area of the screen, display text information in the rest of the screen, and present a complete three-dimensional web page for the user to use.
  • the service node may send a rendering request to the rendering node, so that the rendering node invokes its own GPU to render the target display area to obtain a video stream. Then, the service node sends notification information carrying the streaming address of the video stream to the client, so that the client obtains the video stream from the rendering node based on the streaming address, so as to play the video stream in the target display area.
  • the GPU of the rendering node since the rendering processing of the video stream is completed by a remote rendering node, the GPU of the rendering node generally has relatively strong computing power, and can render a video stream with better quality. Therefore, even if the computing power of the terminal device where the client is located is limited, it can obtain the rendered video stream with better quality from the rendering unit, and play the video stream in the target display area, thereby improving user experience.
  • FIG. 3 is another schematic flowchart of a rendering method based on a cloud service provided by an embodiment of the present application. As shown in FIG. 3 , the method includes:
  • the administrator deploys the rendering program of the video stream in the rendering node in advance.
  • Managers (usually the owners of 3D pages) can package rendering programs for dynamic content such as video streams, and then pre-deploy them in rendering nodes. In this way, rendering nodes are equivalent to rendering programs that store video streams in advance.
  • the rendering node and the service node pre-record the streaming address of the video stream.
  • the rendering node can also make a prior agreement with the service node to jointly set a dedicated streaming address for the video stream in advance, and store the streaming address of the video stream.
  • a dedicated streaming address for the video stream in advance, and store the streaming address of the video stream.
  • the service node provides an access entry for the three-dimensional webpage.
  • the service node receives an access request from the client for the three-dimensional webpage.
  • the service node sends a rendering instruction of the three-dimensional webpage to the client according to the access request.
  • the client detects the local rendering capability according to the rendering instruction of the 3D webpage, and determines whether the local rendering capability meets the requirements.
  • the client determines that the local rendering capability does not meet the requirements, send a rendering instruction for the target display area to the service node.
  • the service node sends a rendering request to the rendering node according to the rendering instruction for the target display area.
  • the rendering node prepares for rendering according to the rendering request.
  • step 303 For the introduction of step 303 to step 309, reference may be made to the relevant description part of step 201 to step 207 in the embodiment shown in FIG. 2, and details are not repeated here.
  • the rendering node executes a rendering program of the video stream to generate a video stream including multiple playback pictures.
  • the rendering node since the rendering node pre-stores the rendering program of the video stream, the rendering node can directly execute the rendering program of the video stream after completing the rendering preparation, so as to generate a video stream that can be played in the target display area.
  • the service node sends notification information carrying the streaming address of the video stream to the client.
  • the service node can locally obtain the pull address of the pre-stored video stream, wrap the pull address of the video stream into notification information, and then send the notification information to the client.
  • the client obtains the video stream from the streaming address, and plays the video stream in the target display area.
  • step 312 For the introduction of step 312, reference may be made to the relevant description part of step 212 in the embodiment shown in FIG. 2, and details are not repeated here.
  • FIG. 4 is another schematic flowchart of a cloud service-based rendering method provided by an embodiment of the present application. As shown in FIG. 4 , the method includes:
  • the service node provides an access entry for a three-dimensional webpage.
  • the service node receives an access request from the client for the three-dimensional webpage.
  • the service node sends a rendering instruction of the three-dimensional webpage to the client according to the access request.
  • the client detects the local rendering capability according to the rendering instruction of the 3D webpage, and determines whether the local rendering capability meets the requirements.
  • steps 401 to 404 For the introduction of steps 401 to 404 , reference may be made to the relevant descriptions of steps 201 to 204 in the embodiment shown in FIG. 2 , and details are not repeated here.
  • the client determines that the local rendering capability does not meet the requirements, send the rendering program of the video stream to the rendering node.
  • the client determines that the local rendering capability does not meet the requirements, since the rendering program of the 3D page has been obtained in the client (obtained from the service node in step 403), the client directly converts the video stream to the rendering program.
  • the renderer is sent to the render node.
  • the rendering node prepares for rendering.
  • the rendering node After the rendering node receives the rendering program of the video stream from the client, it performs a series of rendering preparations related to the client. For the process of rendering preparation by the rendering node, reference may be made to the relevant description part of step 207 in the embodiment shown in FIG. 2 , and details are not repeated here.
  • the rendering node executes a rendering program of the video stream to generate a video stream including multiple playback pictures, and sets a streaming address for the video stream.
  • step 407 For the introduction of step 407, reference may be made to the relevant description part of step 209 in the embodiment shown in FIG. 2, and details are not repeated here.
  • the rendering node sends the streaming address of the video stream to the client.
  • the streaming address is sent directly to the client.
  • the render node can directly send the pull stream address of the video stream to the render node, and for example, the render node can send the pull stream address of the video stream to the service node. , so that the service node wraps the pull stream address of the video stream into notification information, and then sends it to the client and so on.
  • the client obtains the video stream from the streaming address, and plays the video stream in the target display area.
  • step 409 For the introduction of step 409, reference may be made to the relevant description part of step 212 in the embodiment shown in FIG. 2, and details are not repeated here.
  • FIG. 5 is a schematic structural diagram of a cloud service-based rendering device provided by an embodiment of the present application. As shown in FIG. 5 , the device is the aforementioned service node, and the device includes:
  • a receiving module 501 configured to receive a client rendering instruction for the target display area
  • the sending module 503 is used to send a rendering request to the rendering node according to the rendering instruction, and the rendering request is used to instruct the rendering node to call the image processing unit GPU arranged on the rendering node to render the target display area to generate a video stream including a plurality of playback pictures;
  • the sending module 503 is also used to send notification information carrying the pull stream address of the video stream to the client, where the notification information is used to instruct the client to obtain the video stream from the pull stream address and play the video stream in the target display area.
  • the service node can send a rendering request to the rendering node, so that the rendering node invokes its own GPU to render the target display area to obtain a video stream. Then, the service node sends notification information carrying the streaming address of the video stream to the client, so that the client obtains the video stream from the rendering node based on the streaming address, so as to play the video stream in the target display area.
  • the GPU of the rendering node since the rendering processing of the video stream is completed by a remote rendering node, the GPU of the rendering node generally has relatively strong computing power, and can render a video stream with better quality. Therefore, even if the computing power of the terminal device where the client is located is limited, it can obtain the rendered video stream with better quality from the rendering unit, and play the video stream in the target display area, thereby improving user experience.
  • the rendering instruction carries rendering requirement information
  • the apparatus further includes: a processing module 502, configured to select a rendering node matching the rendering requirement information from the rendering resource pool.
  • the rendering instruction carries rendering requirement information
  • the apparatus further includes: a processing module 502, configured to call a cloud service to create a rendering node matching the rendering requirement information.
  • the rendering node includes a virtual machine provided with a GPU, a container, and a bare metal server provided in a data center.
  • the rendering node is a physical server provided with a GPU.
  • the sending module 503 is further configured to provide an access entry for the three-dimensional web page; the receiving module 501 is further configured to receive an access request from the client for the three-dimensional web page; the sending module 503 is further configured to access the three-dimensional web page according to the access request Send a rendering command of the 3D web page to the client.
  • the receiving module 501 is further configured to receive the streaming address sent by the rendering node.
  • the processing module 502 is further configured to record the pull stream address in advance.
  • FIG. 6 is a schematic structural diagram of a network device provided by an embodiment of the present application.
  • an embodiment of the network device in this embodiment of the present application may include one or more central processing units 601 , a memory 602 , an input/output interface 603 , a wired or wireless network interface 604 , and a power supply 605 .
  • the memory 602 may be ephemeral storage or persistent storage. Furthermore, the central processing unit 601 may be configured to communicate with the memory 602 to execute a series of instruction operations in the memory 602 on the network device.
  • the central processing unit 601 may perform the operations performed by the service nodes in the foregoing embodiments shown in FIG. 2 , FIG. 3 , and FIG. 4 , and details are not repeated here.
  • the division of specific functional modules in the central processing unit 601 may be similar to the division of modules such as the receiving module, the processing module, and the sending module described above in FIG. 5 , which will not be repeated here.
  • the embodiments of the present application also relate to a computer storage medium, including computer-readable instructions, when the computer-readable instructions are executed, the methods described in FIG. 2 , FIG. 3 and FIG. 4 are implemented.
  • Embodiments of the present application also relate to a computer program product containing instructions, which, when executed on a computer, cause the computer to execute the methods described in FIG. 2 , FIG. 3 and FIG. 4 .
  • the disclosed system, apparatus and method may be implemented in other manners.
  • the apparatus embodiments described above are only illustrative.
  • the division of the units is only a logical function division. In actual implementation, there may be other division methods.
  • multiple units or components may be combined or Can be integrated into another system, or some features can be ignored, or not implemented.
  • the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
  • the units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit.
  • the above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.
  • the integrated unit if implemented in the form of a software functional unit and sold or used as an independent product, may be stored in a computer-readable storage medium.
  • the technical solutions of the present application can be embodied in the form of software products in essence, or the parts that contribute to the prior art, or all or part of the technical solutions, and the computer software products are stored in a storage medium , including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present application.
  • the aforementioned storage medium includes: U disk, mobile hard disk, Read-Only Memory (ROM, Read-Only Memory), Random Access Memory (RAM, Random Access Memory), magnetic disk or optical disk and other media that can store program codes .

Abstract

Disclosed are a rendering method based on a cloud service, and a related device therefor, which can render a video having a better quality, and can play the video on a terminal device having a limited computation capability, thereby improving the user experience. The method of the present application comprises: a serving node receiving a rendering instruction of a client for a target display area; the service node sending a rendering request to a rendering node according to the rendering instruction, wherein the rendering request is used for instructing the rendering node to invoke a graphics processing unit (GPU) provided in the rendering node to render the target display area, so as to generate a video stream that comprises a plurality of playing pictures; the serving node sending, to the client, notification information carrying a stream pulling address of the video stream, wherein the notification information is used for instructing the client to acquire the video stream from the stream pulling address and play the video stream in the target display area.

Description

一种基于云服务的渲染方法及其相关设备A cloud service-based rendering method and related equipment
本申请要求于2020年12月18日提交中国专利局、申请号为202011505914.5、申请名称为“一种基于云服务的渲染方法及其相关设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application filed on December 18, 2020 with the application number 202011505914.5 and the application title is "a rendering method based on cloud services and related equipment", the entire contents of which are by reference Incorporated in this application.
技术领域technical field
本申请涉及计算机图形学技术领域,尤其涉及一种基于云服务的渲染方法及其相关设备。The present application relates to the technical field of computer graphics, and in particular, to a cloud service-based rendering method and related devices.
背景技术Background technique
随着计算机行业的迅速发展,浏览器中的内容变得更加丰富和有趣。例如,某个终端设备上的浏览器可播放大型的三维(3-dimension,3D)游戏、高清晰的多媒体视频等动态内容,从而为用户提供更佳的观看体验。With the rapid development of the computer industry, the content in the browser has become richer and more interesting. For example, a browser on a certain terminal device can play dynamic content such as large-scale three-dimensional (3-dimension, 3D) games and high-definition multimedia videos, thereby providing users with a better viewing experience.
若终端设备的浏览器要播放某个视频,需要终端设备上的图像处理单元(graphics processing unit,GPU)执行一系列复杂的图像渲染处理,从而渲染出想要显示的视频。然而,在一些轻便型的终端设备上,例如,智能手机、平板电脑等等,这类设备的GPU的计算能力一般较差,故这类算力受限的设备通过自身的GPU执行视频的渲染处理时,往往无法渲染出质量较优的视频,导致用户体验不佳。If the browser of the terminal device wants to play a certain video, an image processing unit (graphics processing unit, GPU) on the terminal device needs to perform a series of complex image rendering processing, so as to render the video to be displayed. However, on some portable terminal devices, such as smart phones, tablet computers, etc., the computing power of the GPU of such devices is generally poor, so such devices with limited computing power perform video rendering through their own GPUs During processing, it is often impossible to render videos with better quality, resulting in poor user experience.
发明内容SUMMARY OF THE INVENTION
本申请实施例提供了一种基于云服务的渲染方法及其相关设备,可渲染出质量较优的视频,并在算力受限的终端设备上播放,从而提高用户体验。Embodiments of the present application provide a cloud service-based rendering method and related devices, which can render a video with better quality and play it on a terminal device with limited computing power, thereby improving user experience.
本申请实施例的第一方面提供了一种基于云服务的渲染方法,该方法包括:A first aspect of the embodiments of the present application provides a rendering method based on a cloud service, the method comprising:
在某个算力受限的终端设备上,通常部署有客户端,例如,浏览器等等。客户端可在整个屏幕区域中显示一定的内容(例如,显示某个三维网页,包含静态内容和动态内容),以供用户进行观看和使用。当客户端确定其所在的终端设备的GPU,无法渲染需在目标显示区域中播放的视频流时,则向服务节点发送针对目标显示区域的渲染指令,该渲染指令用于指示服务器节点完成视频流的远程渲染,以在目标显示区域中播放该视频流。On a terminal device with limited computing power, a client, such as a browser, is usually deployed. The client can display certain content in the entire screen area (for example, display a three-dimensional web page, including static content and dynamic content) for the user to watch and use. When the client determines that the GPU of its terminal device cannot render the video stream that needs to be played in the target display area, it sends a rendering instruction for the target display area to the service node, and the rendering instruction is used to instruct the server node to complete the video stream. remote rendering to play the video stream in the target display area.
服务节点接收客户端针对目标显示区域的渲染指令后,可基于渲染指令确定客户端请求目标显示区域的远程渲染,则可生成渲染请求,该渲染请求用于指示渲染节点调用自身的GPU针对目标显示区域进行渲染,以生成包括多个播放画面的视频流。然后,服务节点将渲染请求发送至渲染节点。After receiving the client's rendering instruction for the target display area, the service node can determine, based on the rendering instruction, that the client requests remote rendering of the target display area, and then generates a rendering request, which is used to instruct the rendering node to call its own GPU to display the target. Regions are rendered to generate a video stream that includes multiple playback frames. The service node then sends the render request to the render node.
渲染节点接收到渲染请求后,则通过GPU完成视频流的渲染,从而得到视频流。After the rendering node receives the rendering request, it completes the rendering of the video stream through the GPU, thereby obtaining the video stream.
最后,服务节点向客户端发送携带有视频流的拉流地址的通知信息,通知信息用于指示客户端从拉流地址获取视频流并在目标显示区域播放视频流。如此一来,客户端接收到通知信息,可从通知信息中获取拉流地址,并基于拉流地址从渲染节点获取视频流,以在目标显示区域中播放视频流。Finally, the service node sends notification information carrying the streaming address of the video stream to the client, where the notification information is used to instruct the client to obtain the video stream from the streaming address and play the video stream in the target display area. In this way, after receiving the notification information, the client can obtain the pull stream address from the notification information, and obtain the video stream from the rendering node based on the pull stream address, so as to play the video stream in the target display area.
从上述方法可以看出:服务节点接收自客户端针对目标显示区域的渲染指令后,可向渲染节点发送渲染请求,以使得渲染节点调用自身的GPU针对目标显示区域进行渲染,得到视频流。然后,服务节点向客户端发送携带有视频流的拉流地址的通知信息,以使得客户端基于拉流地址从渲染节点获取视频流,从而在目标显示区域中播放视频流。前述过程中,由于视频流的渲染处理是由远程的渲染节点完成的,渲染节点的GPU的计算能力通常较强,可渲染出质量较优的视频流。故客户端所在的终端设备即使算力受限,也可从渲染单元获取已渲染的质量较优的视频流,并在目标显示区域中播放该视频流,从而提高用户体验。It can be seen from the above method that after receiving the rendering instruction for the target display area from the client, the service node can send a rendering request to the rendering node, so that the rendering node invokes its own GPU to render the target display area to obtain a video stream. Then, the service node sends notification information carrying the streaming address of the video stream to the client, so that the client obtains the video stream from the rendering node based on the streaming address, so as to play the video stream in the target display area. In the foregoing process, since the rendering processing of the video stream is completed by a remote rendering node, the GPU of the rendering node generally has relatively strong computing power, and can render a video stream with better quality. Therefore, even if the computing power of the terminal device where the client is located is limited, it can obtain the rendered video stream with better quality from the rendering unit, and play the video stream in the target display area, thereby improving user experience.
在一种可能的实现方式中,渲染指令携带有渲染需求信息,服务节点向渲染节点发送渲染请求之前,该方法还包括:服务节点从渲染资源池中选择与渲染需求信息匹配的渲染节点。前述实现方式中,渲染资源池中包含多个渲染节点,不同的渲染节点的GPU具备不同的计算能力。服务节点在接收到来自客户端的渲染指令后,可从渲染指令中确定渲染需求信息,该渲染需求信息用于指示对目标显示区域进行渲染所需的计算能力。因此,服务节点可从渲染资源池中,选择与渲染需求信息匹配的渲染节点。如此一来,由于选择得到的渲染节点的GPU具备足够的计算能力,故可渲染出质量较优的视频流。In a possible implementation manner, the rendering instruction carries rendering demand information, and before the service node sends the rendering request to the rendering node, the method further includes: the service node selects a rendering node matching the rendering demand information from the rendering resource pool. In the foregoing implementation manner, the rendering resource pool includes multiple rendering nodes, and GPUs of different rendering nodes have different computing capabilities. After receiving the rendering instruction from the client, the service node may determine the rendering requirement information from the rendering instruction, where the rendering requirement information is used to indicate the computing power required for rendering the target display area. Therefore, the service node can select the rendering node matching the rendering requirement information from the rendering resource pool. In this way, since the GPU of the selected rendering node has sufficient computing power, a video stream with better quality can be rendered.
在一种可能的实现方式中,渲染指令携带有渲染需求信息,服务节点向渲染节点发送渲染请求之前,该方法还包括:服务节点调用云服务创建渲染需求信息匹配的渲染节点。前述实现方式中,服务节点在接收到来自客户端的渲染指令后,可从渲染指令中确定渲染需求信息,该渲染需求信息用于指示对目标显示区域进行渲染所需的计算能力。因此,服务节点可从直接调用云服务,创建出与渲染需求信息匹配的渲染节点。如此一来,由于创建得到的渲染节点的GPU具备足够的计算能力,故可渲染出质量较优的视频流。In a possible implementation manner, the rendering instruction carries rendering demand information, and before the service node sends the rendering request to the rendering node, the method further includes: the service node invokes the cloud service to create a rendering node matching the rendering demand information. In the foregoing implementation manner, after receiving the rendering instruction from the client, the service node may determine the rendering requirement information from the rendering instruction, where the rendering requirement information is used to indicate the computing power required for rendering the target display area. Therefore, the service node can directly call the cloud service to create a rendering node that matches the rendering demand information. In this way, since the GPU of the created rendering node has sufficient computing power, a video stream with better quality can be rendered.
在一种可能的实现方式中,服务节点接收客户端针对目标显示区域的渲染请求之前,该方法还包括:服务节点提供三维网页的访问入口;服务节点接收客户端针对三维网页的访问请求;服务节点根据访问请求向客户端发送三维网页的渲染指令。前述实现方式中,服务节点可向客户端提供三维网页的访问入口,以使得客户端通过该访问入口向服务节点发送三维网页面的访问请求。然后,服务节点基于访问请求确定客户端需要访问三维网页后,则向客户端发送三维网页的渲染指令,以使得客户端针对整个屏幕区域进行渲染,以生成三维网页。In a possible implementation manner, before the service node receives the rendering request from the client for the target display area, the method further includes: the service node provides an access entry for the 3D web page; the service node receives the access request from the client for the 3D web page; serving The node sends a rendering instruction of the 3D webpage to the client according to the access request. In the foregoing implementation manner, the service node may provide the client with an access entry for the three-dimensional web page, so that the client sends an access request for the three-dimensional web page to the service node through the access entry. Then, after determining that the client needs to access the three-dimensional webpage based on the access request, the service node sends a rendering instruction of the three-dimensional webpage to the client, so that the client renders the entire screen area to generate the three-dimensional webpage.
在一种可能的实现方式中,服务节点向客户端发送携带有视频流的拉流地址的通知信息之前,该方法还包括:服务节点接收渲染节点发送的拉流地址。前述实现方式中,渲染节点在完成渲染得到视频流后,可为该视频流设置专属的拉流地址,并将拉流地址发送至服务节点,以使得服务节点将拉流地址转发至客户端,进而使得客户端能够基于该拉流地址从渲染节点中获取已渲染的视频流。In a possible implementation manner, before the service node sends the notification information carrying the streaming address of the video stream to the client, the method further includes: the service node receives the streaming address sent by the rendering node. In the foregoing implementation manner, after the rendering node completes rendering and obtains the video stream, it can set a dedicated streaming address for the video stream, and send the streaming address to the service node, so that the service node forwards the streaming address to the client. Further, the client can obtain the rendered video stream from the rendering node based on the pull stream address.
在一种可能的实现方式中,服务节点向客户端发送携带有视频流的拉流地址的通知信息之前,该方法还包括:服务节点预先记录拉流地址。前述实现方式中,服务节点与渲染节点事先记录有为该视频流设置的拉流地址。因此,在渲染节点完成渲染得到视频流后,服务节点可直接将视频流的拉流地址发送至客户端,使得客户端能够基于该拉流地址从渲 染节点中获取已渲染的视频流。In a possible implementation manner, before the service node sends the notification information carrying the streaming address of the video stream to the client, the method further includes: the service node pre-records the streaming address. In the foregoing implementation manner, the service node and the rendering node record the streaming address set for the video stream in advance. Therefore, after the rendering node completes rendering and obtains the video stream, the service node can directly send the streaming address of the video stream to the client, so that the client can obtain the rendered video stream from the rendering node based on the streaming address.
在一种可能的实现方式中,渲染节点包括设置在数据中心的设置有GPU的虚拟机、容器以及裸金属服务器。In a possible implementation manner, the rendering node includes a virtual machine provided with a GPU, a container, and a bare metal server provided in a data center.
在一种可能的实现方式中,渲染节点为设置有GPU的物理服务器。In a possible implementation manner, the rendering node is a physical server provided with a GPU.
从以上技术方案可以看出,本申请实施例具有以下优点:As can be seen from the above technical solutions, the embodiments of the present application have the following advantages:
本申请实施例的第二方面提供了一种基于云服务的渲染装置,该装置即为前述的服务节点,该装置包括:接收模块,用于接收客户端针对目标显示区域的渲染指令;发送模块,用于根据渲染指令向渲染节点发送渲染请求,渲染请求用于指示渲染节点调用设置在渲染节点的图像处理单元GPU针对目标显示区域进行渲染以生成包括多个播放画面的视频流;发送模块,还用于向客户端发送携带有视频流的拉流地址的通知信息,通知信息用于指示客户端从拉流地址获取视频流并在目标显示区域播放视频流。A second aspect of the embodiments of the present application provides a rendering device based on cloud services, the device is the aforementioned service node, and the device includes: a receiving module for receiving a rendering instruction from a client for a target display area; a sending module is used to send a rendering request to the rendering node according to the rendering instruction, and the rendering request is used to instruct the rendering node to call the image processing unit GPU arranged on the rendering node to render the target display area to generate a video stream including a plurality of playback pictures; the sending module, It is also used to send notification information carrying the streaming address of the video stream to the client, where the notification information is used to instruct the client to obtain the video stream from the streaming address and play the video stream in the target display area.
从上述装置可以看出:服务节点接收自客户端针对目标显示区域的渲染指令后,可向渲染节点发送渲染请求,以使得渲染节点调用自身的GPU针对目标显示区域进行渲染,得到视频流。然后,服务节点向客户端发送携带有视频流的拉流地址的通知信息,以使得客户端基于拉流地址从渲染节点获取视频流,从而在目标显示区域中播放视频流。前述过程中,由于视频流的渲染处理是由远程的渲染节点完成的,渲染节点的GPU的计算能力通常较强,可渲染出质量较优的视频流。故客户端所在的终端设备即使算力受限,也可从渲染单元获取已渲染的质量较优的视频流,并在目标显示区域中播放该视频流,从而提高用户体验。It can be seen from the above device that after receiving the rendering instruction for the target display area from the client, the service node can send a rendering request to the rendering node, so that the rendering node invokes its own GPU to render the target display area to obtain a video stream. Then, the service node sends notification information carrying the streaming address of the video stream to the client, so that the client obtains the video stream from the rendering node based on the streaming address, so as to play the video stream in the target display area. In the foregoing process, since the rendering processing of the video stream is completed by a remote rendering node, the GPU of the rendering node generally has relatively strong computing power, and can render a video stream with better quality. Therefore, even if the computing power of the terminal device where the client is located is limited, it can obtain the rendered video stream with better quality from the rendering unit, and play the video stream in the target display area, thereby improving user experience.
在一种可能的实现方式中,渲染指令携带有渲染需求信息,该装置还包括:处理模块,用于从渲染资源池中选择与渲染需求信息匹配的渲染节点。In a possible implementation manner, the rendering instruction carries rendering requirement information, and the apparatus further includes: a processing module configured to select a rendering node matching the rendering requirement information from the rendering resource pool.
在一种可能的实现方式中,渲染指令携带有渲染需求信息,该装置还包括:处理模块,用于调用云服务创建渲染需求信息匹配的渲染节点。In a possible implementation manner, the rendering instruction carries rendering requirement information, and the apparatus further includes: a processing module configured to call a cloud service to create a rendering node matching the rendering requirement information.
在一种可能的实现方式中,渲染节点包括设置在数据中心的设置有GPU的虚拟机、容器以及裸金属服务器。In a possible implementation manner, the rendering node includes a virtual machine provided with a GPU, a container, and a bare metal server provided in a data center.
在一种可能的实现方式中,渲染节点为设置有GPU的物理服务器。In a possible implementation manner, the rendering node is a physical server provided with a GPU.
在一种可能的实现方式中,发送模块,还用于提供三维网页的访问入口;接收模块,还用于接收客户端针对三维网页的访问请求;发送模块,还用于根据访问请求向客户端发送三维网页的渲染指令。In a possible implementation manner, the sending module is further configured to provide an access entry for the three-dimensional web page; the receiving module is further configured to receive an access request from the client for the three-dimensional web page; the sending module is further configured to send the client to the client according to the access request Sends rendering instructions for 3D web pages.
在一种可能的实现方式中,接收模块,还用于接收渲染节点发送的拉流地址。In a possible implementation manner, the receiving module is further configured to receive the pull stream address sent by the rendering node.
在一种可能的实现方式中,处理模块,还用于预先记录拉流地址。In a possible implementation manner, the processing module is further configured to record the pull stream address in advance.
本申请实施例的第三方面提供了一种网络设备,网络设备包括:处理器和存储器;A third aspect of the embodiments of the present application provides a network device, where the network device includes: a processor and a memory;
存储器用于存储计算机执行指令;memory for storing computer-executed instructions;
处理器用于执行存储器所存储的计算机执行指令,以使网络设备实现如第一方面或第一方面中任意一种可能的实现方式所述的方法。The processor is configured to execute computer-executable instructions stored in the memory, so that the network device implements the method described in the first aspect or any possible implementation manner of the first aspect.
本申请实施例的第四方面一种计算机存储介质,包括计算机可读指令,当计算机可读指令被执行时,实现如第一方面或第一方面中任意一种可能的实现方式所述的方法。A fourth aspect of the embodiments of the present application is a computer storage medium, comprising computer-readable instructions, when the computer-readable instructions are executed, the method described in the first aspect or any possible implementation manner of the first aspect is implemented .
本申请实施例的第五方面一种包含指令的计算机程序产品,当其在计算机上运行时,使得计算机执行如第一方面或第一方面中任意一种可能的实现方式所述的方法。A fifth aspect of the embodiments of the present application is a computer program product containing instructions, which, when executed on a computer, cause the computer to execute the method described in the first aspect or any possible implementation manner of the first aspect.
本申请实施例中,服务节点接收自客户端针对目标显示区域的渲染指令后,可向渲染节点发送渲染请求,以使得渲染节点调用自身的GPU针对目标显示区域进行渲染处理,得到视频流。然后,服务节点向客户端发送携带有视频流的拉流地址的通知信息,以使得客户端基于拉流地址从渲染节点获取视频流,从而在目标显示区域中播放视频流。前述过程中,由于视频流的渲染处理是由远程的渲染节点完成的,渲染节点的GPU的计算能力通常较强,可渲染出质量较优的视频流。故客户端所在的终端设备即使算力受限,也可从渲染单元获取已渲染的质量较优的视频流,并在目标显示区域中播放该视频流,从而提高用户体验。In the embodiment of the present application, after receiving the rendering instruction for the target display area from the client, the service node may send a rendering request to the rendering node, so that the rendering node invokes its own GPU to perform rendering processing on the target display area to obtain a video stream. Then, the service node sends notification information carrying the streaming address of the video stream to the client, so that the client obtains the video stream from the rendering node based on the streaming address, so as to play the video stream in the target display area. In the foregoing process, since the rendering processing of the video stream is completed by a remote rendering node, the GPU of the rendering node generally has relatively strong computing power, and can render a video stream with better quality. Therefore, even if the computing power of the terminal device where the client is located is limited, it can obtain the rendered video stream with better quality from the rendering unit, and play the video stream in the target display area, thereby improving user experience.
附图说明Description of drawings
图1为本申请实施例提供的云服务系统的一个示意图;1 is a schematic diagram of a cloud service system provided by an embodiment of the present application;
图2为本申请实施例提供的基于云服务的渲染方法的一个流程示意图;2 is a schematic flowchart of a rendering method based on a cloud service provided by an embodiment of the present application;
图3为本申请实施例提供的基于云服务的渲染方法的另一流程示意图;3 is another schematic flowchart of a rendering method based on a cloud service provided by an embodiment of the present application;
图4为本申请实施例提供的基于云服务的渲染方法的又一流程示意图;4 is another schematic flowchart of a rendering method based on a cloud service provided by an embodiment of the present application;
图5为本申请实施例提供的基于云服务的渲染装置的一个结构示意图;5 is a schematic structural diagram of a rendering apparatus based on a cloud service provided by an embodiment of the present application;
图6为本申请实施例提供的网络设备的一个结构示意图。FIG. 6 is a schematic structural diagram of a network device provided by an embodiment of the present application.
具体实施方式Detailed ways
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行详细描述。The technical solutions in the embodiments of the present application will be described in detail below with reference to the accompanying drawings in the embodiments of the present application.
本申请的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的实施例能够以除了在这里图示或描述的内容以外的顺序实施。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或模块的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或模块,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或模块。在本申请中出现的对步骤进行的命名或者编号,并不意味着必须按照命名或者编号所指示的时间/逻辑先后顺序执行方法流程中的步骤,已经命名或者编号的流程步骤可以根据要实现的技术目的变更执行次序,只要能达到相同或者相类似的技术效果即可。本申请中所出现的模块的划分,是一种逻辑上的划分,实际应用中实现时可以有另外的划分方式,例如多个模块可以结合成或集成在另一个系统中,或一些特征可以忽略,或不执行,另外,所显示的或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些端口,模块之间的间接耦合或通信连接可以是电性或其他类似的形式,本申请中均不作限定。并且,作为分离部件说明的模块或子模块可以是也可以不是物理上的分离,可以是也可以不是物理模块,或者可以分布到多个电路模块中,可以根据实际的需要选择其中的部分或全部模块来实现本申请方案的目的。The terms "first", "second" and the like in the description and claims of the present application and the above drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It is to be understood that data so used may be interchanged under appropriate circumstances so that the embodiments described herein can be practiced in sequences other than those illustrated or described herein. Furthermore, the terms "comprising" and "having", and any variations thereof, are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device comprising a series of steps or modules is not necessarily limited to those expressly listed Rather, those steps or modules may include other steps or modules not expressly listed or inherent to the process, method, product or apparatus. The naming or numbering of the steps in this application does not mean that the steps in the method flow must be executed in the time/logical sequence indicated by the naming or numbering, and the named or numbered process steps can be implemented according to the The technical purpose is to change the execution order, as long as the same or similar technical effects can be achieved. The division of modules in this application is a logical division. In practical applications, there may be other divisions. For example, multiple modules may be combined or integrated into another system, or some features may be ignored. , or not implemented, in addition, the shown or discussed mutual coupling or direct coupling or communication connection may be through some ports, and the indirect coupling or communication connection between modules may be electrical or other similar forms. There are no restrictions in the application. In addition, the modules or sub-modules described as separate components may or may not be physically separated, may or may not be physical modules, or may be distributed into multiple circuit modules, and some or all of them may be selected according to actual needs. module to achieve the purpose of the solution of this application.
随着计算机技术的飞速发展,用户对浏览器的要求也随之提高,例如,浏览器所展示的网页中,既包含文本信息等等静态内容,也包含高清的视频等动态内容,从而满足用户的各种需求。若终端设备的浏览器要播放某个视频,需要终端设备上的图像处理单元(graphics processing unit,GPU)执行一系列复杂的图像渲染处理,从而渲染出想要显示的视频。然而,在一些轻便型的终端设备上,例如,智能手机、平板电脑等等,这类设备的GPU的计算能力一般较差,故这类算力受限的设备通过自身的GPU执行视频的渲染处理时,往往无法渲染出质量较优的视频,导致用户体验不佳。With the rapid development of computer technology, users' requirements for browsers have also increased. For example, the web pages displayed by browsers include both static content such as text information, and dynamic content such as high-definition videos, so as to satisfy users' needs various needs. If the browser of the terminal device wants to play a certain video, an image processing unit (graphics processing unit, GPU) on the terminal device needs to perform a series of complex image rendering processing, so as to render the video to be displayed. However, on some portable terminal devices, such as smart phones, tablet computers, etc., the computing power of the GPU of such devices is generally poor, so such devices with limited computing power perform video rendering through their own GPUs During processing, it is often impossible to render videos with better quality, resulting in poor user experience.
为了解决上述问题,本申请实施例提供了一种云服务系统。图1为本申请实施例提供的云服务系统的一个示意图,如图1所示,云服务系统包括:客户端、服务节点以及渲染节点。在客户端、服务节点以及渲染节点,两两之间可实现通信,即两两之间可实现信息传输。可见,客户端可直接与渲染节点进行通信,也可通过服务节点与渲染节点进行通信。下文将对客户端、服务节点以及渲染节点分别进行介绍:In order to solve the above problem, an embodiment of the present application provides a cloud service system. FIG. 1 is a schematic diagram of a cloud service system provided by an embodiment of the present application. As shown in FIG. 1 , the cloud service system includes: a client, a service node, and a rendering node. Communication can be achieved between the client, the service node, and the rendering node, that is, information transmission can be achieved between them. It can be seen that the client can communicate with the rendering node directly, or communicate with the rendering node through the service node. The following will introduce the client, service node and rendering node respectively:
客户端通常部署在某一终端设备上,即客户端为终端设备上运行的一个应用程序,例如,浏览器,故用户可在终端设备启动浏览器,从而通过浏览器浏览三维网页等等。需要说明的是,客户端与服务节点之间可通过超文本传输协议(hyper text transfer protocol,HTTP)完成信息传输,客户端与渲染节点之间可通过Websocket、超文本直播流(http live streaming,HLS)、webrtc等方式完成信息传输,客户端所显示的网页可通过超级文本标记语言(hyper text markup language,HTML)进行描述,客户端所支持的编程语言可以是javascript,也可以是其他类型的编程语言。值得注意的是,客户端可基于javascript的方式检测其所在的终端设备的渲染能力,即其所在的终端设备的GPU的计算能力,从而判断GPU是否能渲染出质量较优的动态内容,例如,视频流等等。The client is usually deployed on a certain terminal device, that is, the client is an application running on the terminal device, such as a browser, so the user can start the browser on the terminal device to browse three-dimensional web pages through the browser. It should be noted that the information transmission can be completed between the client and the service node through the hypertext transfer protocol (HTTP), and the client and the rendering node can be through Websocket, hypertext live streaming (http live streaming, HLS), webrtc, etc. to complete information transmission, the web page displayed by the client can be described by hyper text markup language (HTML), and the programming language supported by the client can be javascript or other types of Programming language. It is worth noting that the client can detect the rendering capability of the terminal device where it is located based on javascript, that is, the computing capability of the GPU of the terminal device where it is located, so as to determine whether the GPU can render dynamic content with better quality, for example, Video streaming and more.
服务节点为一个网络(Web)服务节点,可通过多种方式进行部署,例如,服务节点可以为单独的一台物理服务器(也可称为网络设备),又如,服务节点还可以为某台物理服务器上加载的某个虚拟机,再如,服务节点还可以为某台物理服务器上加载的某个容器等等。服务节点可为客户端和渲染节点提供页面服务,例如,包含静态内容的页面服务,包含动态内容的页面服务以及包含静态内容和动态内容的页面服务等等。下面通过一个例子对前述的页面服务进行简单的介绍:服务节点可将用于渲染某个网页的渲染程序发送至客户端,客户端可执行该渲染程序,从而渲染出该网页以进行显示。A service node is a network (Web) service node, which can be deployed in various ways. For example, a service node can be a separate physical server (also called a network device), or a service node can also be a certain server. A virtual machine loaded on a physical server, for example, a service node can also be a container loaded on a physical server, and so on. Serving nodes can serve pages to clients and rendering nodes, such as serving pages with static content, serving pages with dynamic content, and serving pages with static content and dynamic content, and so on. The foregoing page service is briefly introduced through an example: the service node can send a rendering program for rendering a certain webpage to the client, and the client can execute the rendering program to render the webpage for display.
渲染节点也可通过多种方式进行部署,例如,渲染节点可以为单独的一台物理服务器,又如,渲染节点还可以为某台物理服务器上加载的某个虚拟机,再如,渲染节点还可以为某台物理服务器上加载的某个容器等等。值得注意的是,当渲染节点和服务节点均为虚拟机(或容器)时,二者可部署于同一台物理服务器上,也可部署于不同的物理服务器上,此处不做限制。无论渲染节点以何种方式进行部署,渲染节点均包含GPU,故渲染节点可代替客户端执行渲染程序,从而实现远程渲染,且完成渲染得到视频流后,可将视频流发送至客户端进行显示。需要说明的是,客户端和渲染单元支持相同的三维渲染编程技术,例如,网络图形库(web graphics library,WebGL)技术等等。相应的,渲染程序可以WebGL程序或其他形式呈现,WebGL程序可通过javascript编写WebGL接口,该程序可 包含渲染时所需使用的渲染数据以及所需进行的渲染操作,其中,渲染数据可包含待渲染目标的顶点坐标、三角形索引、颜色、金属度以及粗糙度等数据,渲染操作可包含光栅化的一系列操作,例如坐标变换、几何离散化等等。Rendering nodes can also be deployed in various ways. For example, a rendering node can be a separate physical server, or a rendering node can also be a virtual machine loaded on a physical server. Could be a container loaded on a physical server, etc. It is worth noting that when both the rendering node and the service node are virtual machines (or containers), they can be deployed on the same physical server or on different physical servers, which is not limited here. No matter how the rendering node is deployed, the rendering node contains a GPU, so the rendering node can execute the rendering program on behalf of the client, thereby realizing remote rendering, and after the rendering is completed and the video stream is obtained, the video stream can be sent to the client for display. . It should be noted that the client and the rendering unit support the same three-dimensional rendering programming technology, for example, a network graphics library (web graphics library, WebGL) technology and so on. Correspondingly, the rendering program can be presented in a WebGL program or in other forms. The WebGL program can write a WebGL interface through javascript, and the program can include the rendering data to be used during rendering and the rendering operations to be performed, wherein the rendering data can include the rendering data to be rendered. The target's vertex coordinates, triangle index, color, metalness, and roughness data, and rendering operations can include a series of rasterization operations, such as coordinate transformation, geometric discretization, and so on.
需要说明的是,为了方便说明,本申请中所涉及的“客户端执行渲染程序”,可理解为“客户端所在的终端设备的GPU执行渲染程序”。同样地,“渲染节点执行渲染程序”,可理解为“渲染节点的GPU执行渲染程序”,后续不再赘述。It should be noted that, for the convenience of description, "the client executes the rendering program" involved in this application may be understood as "the GPU of the terminal device where the client is located executes the rendering program". Similarly, "the rendering node executes the rendering program" can be understood as "the GPU of the rendering node executes the rendering program", which will not be repeated in the following.
为了进一步理解上述系统的实现流程,下文结合图2作进一步的介绍。图2为本申请实施例提供的基于云服务的渲染方法的一个流程示意图,如图2所示,该方法包括:In order to further understand the implementation process of the above-mentioned system, a further introduction is given below with reference to FIG. 2 . FIG. 2 is a schematic flowchart of a rendering method based on a cloud service provided by an embodiment of the present application. As shown in FIG. 2 , the method includes:
201、服务节点提供三维网页的访问入口。201. The service node provides an access entry for a three-dimensional webpage.
本实施例中,服务节点可为客户端提供三维网页的访问入口,使得客户端在屏幕上显示该访问入口,若用户需要访问三维网页,则可向该访问入口输入三维页面的访问请求。需要说明的是,三维网页的访问入口通常为一个包含静态内容的网页,那么,渲染访问入口所需的计算能力不高,故客户端可在本地完成访问入口的渲染处理。具体地,服务节点可将三维页面的访问入口的渲染程序发送至客户端,客户端直接执行该渲染程序,从而渲染出三维页面的访问入口,并在终端设备的屏幕上显示该访问入口,以供用户进行使用。In this embodiment, the service node can provide the client with an access portal for the 3D web page, so that the client terminal displays the access portal on the screen. If the user needs to access the 3D web page, the user can input a 3D page access request to the access portal. It should be noted that the access portal of a 3D web page is usually a web page containing static content, so the computing power required to render the access portal is not high, so the client can complete the rendering processing of the access portal locally. Specifically, the service node can send the rendering program of the access entry of the three-dimensional page to the client, and the client directly executes the rendering program, thereby rendering the access entry of the three-dimensional page, and displays the access entry on the screen of the terminal device to for users to use.
例如,设三维网页为一个包含文本(描述产品的信息等等)和视频流(展示产品的形状等等)的产品网站,用户可在该产品网站上浏览产品的具体信息。此时,三维网页的访问入口可为一个登陆页面,用户在登录页面输入账号密码后,则可进入产品网站进行浏览。For example, suppose a three-dimensional web page is a product website containing text (information describing the product, etc.) and video stream (showing the shape of the product, etc.), and users can browse the specific information of the product on the product website. In this case, the access entrance of the 3D web page may be a login page, and after the user enters the account password on the login page, he can enter the product website for browsing.
又如,设三维网页为一个基于虚拟现实(virtual teality,VR)技术构造的一个三维建筑物,用户可在三维建筑物内部中进行游览,从而了解该建筑物的信息。此时,三维网页的访问入口可为三维建筑物的初始画面,如三维建筑物的门口,用户点击门口后,则可以进入三维建筑物内部进行游览。For another example, suppose a three-dimensional web page is a three-dimensional building constructed based on virtual reality (VR) technology, and a user can tour the interior of the three-dimensional building to learn the information of the building. In this case, the access entrance of the 3D webpage may be the initial image of the 3D building, such as the door of the 3D building. After the user clicks on the door, the user can enter the interior of the 3D building for tour.
202、服务节点接收客户端针对三维网页的访问请求。202. The service node receives an access request from the client for the three-dimensional webpage.
客户端显示三维网页的访问入口后,用户可向其输入三维网页的访问请求。其中,访问请求可以是前述用户的登录操作或用户的页面点击操作,还可以是用于实现网页跳转、将网站添加到收藏夹、弹出提示框、音频输出等功能的操作。因此,客户端通过访问入口接收到对三维网页的访问请求后,则将三维网页的访问请求发送至服务节点。After the client terminal displays the access portal of the three-dimensional web page, the user may input an access request for the three-dimensional web page to the client. The access request may be the aforementioned user's login operation or the user's page click operation, or may be an operation for implementing functions such as webpage jumping, adding a website to favorites, popping up a prompt box, and audio output. Therefore, after receiving the access request for the three-dimensional web page through the access portal, the client sends the access request for the three-dimensional web page to the service node.
203、服务节点根据访问请求向客户端发送三维网页的渲染指令。203. The service node sends a rendering instruction of the three-dimensional webpage to the client according to the access request.
服务节点接收来自客户端的访问请求后,可确定客户端需要访问三维网页,则向客户端发送三维网页的渲染指令,该渲染指令用于指示客户端检测本地的渲染能力,从而确定是否在本地完成三维网页的渲染处理。After receiving the access request from the client, the service node can determine that the client needs to access the 3D web page, and then sends a rendering instruction of the 3D web page to the client. Rendering of 3D web pages.
此外,服务节点还可向客户端发送三维网页的渲染程序。需要说明的是,三维网页的渲染程序和三维网页的渲染指令可以同步发送至客户端,也可异步发送至客户端。例如,服务节点先将三维网页的渲染指令发送至客户端,再将三维网页的渲染程序发送至客户端。又如,服务节点先将三维网页的渲染程序发送至客户端,再将三维网页的渲染指令发送至客户端。再如,服务节点将三维网页的渲染程序以及三维网页的渲染指令一并发送至 客户端,此处不做限制。In addition, the service node can also send the rendering program of the 3D web page to the client. It should be noted that the rendering program of the 3D web page and the rendering instruction of the 3D web page may be sent to the client synchronously, or may be sent to the client asynchronously. For example, the service node first sends the rendering instruction of the 3D webpage to the client, and then sends the rendering program of the 3D webpage to the client. For another example, the service node first sends the rendering program of the 3D webpage to the client, and then sends the rendering instruction of the 3D webpage to the client. For another example, the service node sends the rendering program of the 3D web page and the rendering instruction of the 3D web page to the client together, which is not limited here.
204、客户端根据三维网页的渲染指令检测本地的渲染能力,并判断本地的渲染能力是否满足要求。204. The client detects the local rendering capability according to the rendering instruction of the 3D webpage, and determines whether the local rendering capability meets the requirements.
客户端接收来自服务节点的三维网页的渲染指令后,则对本地的渲染能力进行检测。客户端可通过多种方式检测本地的渲染能力:例如,客户端可尝试运行某个小视频的渲染程序(该渲染程序可以预置在客户端中,也可以由服务节点发送至客户端,此处不做限制),并获取GPU运行该渲染程序的功耗、帧率等参数,并基于这些参数确定本地的渲染能力,即客户端所在的终端设备的GPU的计算能力。又如,客户端可直接获取其所在的终端设备的显卡(包含GPU)的型号,从而确定本地的渲染能力。After the client receives the rendering instruction of the 3D web page from the service node, it detects the local rendering capability. The client can detect local rendering capabilities in various ways: for example, the client can try to run a rendering program for a small video (the rendering program can be preset in the client, or it can be sent to the client by the service node. There is no restriction), and obtain parameters such as the power consumption and frame rate of the GPU running the rendering program, and determine the local rendering capability based on these parameters, that is, the computing capability of the GPU of the terminal device where the client is located. For another example, the client can directly obtain the model of the graphics card (including the GPU) of the terminal device where it is located, so as to determine the local rendering capability.
三维网页通常包含文本信息等静态内容以及视频流等动态内容,为了便于说明,下文以文本信息代表静态内容,以视频流代表动态内容进行介绍。因此,客户端可在三维网页的渲染程序中,确定执行文本信息的渲染程序所需的计算能力,以及执行视频流的渲染程序所需的计算能力,一般地,执行文本信息的渲染程序所需的计算能力小于执行视频流的渲染程序所需的计算能力。若确定客户端所在的终端设备的GPU的计算能力大于执行视频流的渲染程序所需的计算能力,则说明客户端确定本地的渲染能力满足要求,客户端可在本地进行三维网页的渲染处理,即直接执行三维网页的渲染程序,从而渲染出三维网页,并在屏幕中显示三维网页(包含文本信息以及视频流),其中,屏幕中的目标显示区域用于播放视频流,屏幕中除目标显示区域之外的其余区域用于显示文本信息。3D web pages usually include static content such as text information and dynamic content such as video streams. For ease of description, the text information is used to represent the static content, and the video stream is used to represent the dynamic content. Therefore, in the rendering program of the 3D web page, the client can determine the computing power required for executing the rendering program for text information and the computing power required for executing the rendering program for video streams. Generally, the rendering program for executing text information needs to be The computing power is less than the computing power required to execute the rendering program of the video stream. If it is determined that the computing capability of the GPU of the terminal device where the client is located is greater than the computing capability required to execute the rendering program of the video stream, it means that the client determines that the local rendering capability meets the requirements, and the client can render the 3D webpage locally. That is, the rendering program of the 3D web page is directly executed, thereby rendering the 3D web page, and displaying the 3D web page (including text information and video stream) on the screen. The rest of the area outside the area is used to display textual information.
若确定客户端所在的终端设备的GPU的计算能力小于执行视频流的渲染程序所需的计算能力,则说明客户端确定本地的渲染能力不满足要求,则执行步骤205。If it is determined that the computing capability of the GPU of the terminal device where the client is located is less than the computing capability required for executing the rendering program of the video stream, it means that the client determines that the local rendering capability does not meet the requirements, and step 205 is performed.
205、若客户端确定本地的渲染能力不满足要求,则向服务节点发送针对目标显示区域的渲染指令。205. If the client determines that the local rendering capability does not meet the requirements, send a rendering instruction for the target display area to the service node.
当客户端确定本地的渲染能力不满足要求,则在本地实现文本信息的渲染处理,并向服务节点请求视频流的远程渲染处理。具体地,客户端执行文本信息的渲染程序,从而渲染出文本信息,并在屏幕中除目标显示区域之外的其余区域显示文本信息。与此同时,客户端还可向服务节点发送针对目标显示区域的渲染指令(也可以理解为视频流的渲染指令),该渲染指令用于指示服务器节点完成视频流的远程渲染,从而在目标显示区域中播放该视频流。When the client determines that the local rendering capability does not meet the requirements, it implements the rendering processing of the text information locally, and requests the remote rendering processing of the video stream from the service node. Specifically, the client executes a rendering program for text information, thereby rendering the text information, and displaying the text information in the remaining areas of the screen except the target display area. At the same time, the client can also send a rendering instruction for the target display area to the service node (which can also be understood as a rendering instruction of the video stream), and the rendering instruction is used to instruct the server node to complete the remote rendering of the video stream, so that the target display play the video stream in the zone.
206、服务节点根据针对目标显示区域的渲染指令向渲染节点发送渲染请求。206. The service node sends a rendering request to the rendering node according to the rendering instruction for the target display area.
服务节点接收客户端针对目标显示区域的渲染指令后,则向渲染节点发送渲染请求,渲染请求用于指示渲染节点调用设置在渲染节点的GPU针对目标显示区域进行渲染以生成包括多个播放画面的视频流。After the service node receives the rendering instruction from the client for the target display area, it sends a rendering request to the rendering node, and the rendering request is used to instruct the rendering node to call the GPU set on the rendering node to render the target display area to generate a rendering including multiple playback images. video stream.
举例而言,渲染请求包括上述的渲染指令。For example, the rendering request includes the above-mentioned rendering instructions.
可选地,服务节点可对上述的渲染指令作出格式转换,将接收到的渲染指令转换成适合渲染节点进行图像渲染的格式。Optionally, the service node can perform format conversion on the above rendering instruction, and convert the received rendering instruction into a format suitable for rendering the image by the rendering node.
此外,在服务节点发送渲染请求之前,服务节点可确定用于实现远程渲染处理的渲染节点。具体地,对目标显示区域的渲染指令中携带有渲染需求信息,渲染需求信息用于指 示对目标显示区域进行渲染所需的计算能力,即渲染视频流所需的计算能力。因此,服务节点可根据渲染需求信息,通过多种方式确定实现远程渲染处理的渲染节点,例如,在云服务系统中预先部署有一个渲染资源池,该渲染资源池包含多个渲染节点,多个渲染节点可以构成虚拟机集群、容器集群、物理服务器集群等等。不同渲染节点的GPU的计算能力不同,因此,服务节点可在渲染资源池中,选择与渲染需求信息匹配的渲染节点,用于实现视频流的远程渲染处理。又如,服务节点可以在云服务系统中,直接调用云服务创建出一个新的渲染节点,该渲染节点可以为虚拟机、容器等等,且该渲染节点与渲染需求信息匹配,故可用于实现视频流的远程渲染处理。Furthermore, before the service node sends a rendering request, the service node may determine a render node for implementing remote rendering processing. Specifically, the rendering instruction for the target display area carries the rendering requirement information, and the rendering requirement information is used to indicate the computing power required for rendering the target display area, that is, the computing power required for rendering the video stream. Therefore, the service node can determine the rendering node that implements remote rendering processing in various ways according to the rendering demand information. For example, a rendering resource pool is pre-deployed in the cloud service system. Render nodes can form virtual machine clusters, container clusters, physical server clusters, and more. The GPUs of different rendering nodes have different computing capabilities. Therefore, the service node can select a rendering node that matches the rendering demand information in the rendering resource pool to implement remote rendering processing of video streams. For another example, the service node can directly call the cloud service in the cloud service system to create a new rendering node. The rendering node can be a virtual machine, container, etc., and the rendering node matches the rendering demand information, so it can be used to implement Remote rendering processing of video streams.
207、渲染节点根据渲染请求进行渲染准备。207. The rendering node prepares for rendering according to the rendering request.
渲染节点接收来自服务节点的渲染请求后,则确定需要满足客户端的远程渲染需求,故会启动一系列跟客户端相关的渲染准备。可以理解的是,渲染节点为具备GPU的虚拟机、容器或物理服务器等,即渲染节点自身的系统为与客户端相关的程序(例如,浏览器内核等等)提供了运行环境,故渲染节点也可运行与客户端相关的程序,经过该准备后,渲染节点可替代客户端进行视频流的渲染处理。After the rendering node receives the rendering request from the service node, it determines that it needs to meet the remote rendering requirements of the client, so it will start a series of rendering preparations related to the client. It can be understood that the rendering node is a virtual machine, container or physical server with GPU, that is, the system of the rendering node itself provides a running environment for the program related to the client (for example, browser kernel, etc.), so the rendering node It is also possible to run a program related to the client, and after the preparation, the rendering node can replace the client to perform the rendering processing of the video stream.
208、渲染节点从服务节点中获取视频流的渲染程序。208. The rendering node obtains a rendering program of the video stream from the service node.
服务节点中存储有三维网页的渲染程序,即存储有视频流的渲染程序。故渲染节点完成渲染准备后,可从服务节点中获取视频流的渲染程序。The service node stores the rendering program of the three-dimensional web page, that is, the rendering program that stores the video stream. Therefore, after the rendering node completes the rendering preparation, the rendering program of the video stream can be obtained from the service node.
209、渲染节点执行视频流的渲染程序,以生成包括多个播放画面的视频流,并为视频流设置拉流地址。209. The rendering node executes a rendering program of the video stream, so as to generate a video stream including a plurality of playback pictures, and set a stream pull address for the video stream.
得到视频流的渲染程序后,渲染节点调用设置在渲染节点的GPU执行视频流的渲染程序,从而生成可在目标显示区域中播放的视频流。After obtaining the rendering program of the video stream, the rendering node invokes the GPU set in the rendering node to execute the rendering program of the video stream, thereby generating a video stream that can be played in the target display area.
得到视频流后,渲染节点可为该视频流设置专属的拉流地址,视频流的拉流地址包含渲染节点的互联网协议(internet protocol,IP)地址与端口、客户端的标识(token)、当前会话的身份识别号(identity document,ID)、视频流的ID等信息。After obtaining the video stream, the rendering node can set a dedicated streaming address for the video stream. The streaming address of the video stream includes the Internet Protocol (IP) address and port of the rendering node, the client's token (token), the current session The identity document (ID), the ID of the video stream and other information.
210、服务节点接收渲染节点发送的视频流的拉流地址。210. The service node receives the streaming address of the video stream sent by the rendering node.
渲染节点得到视频流的拉流地址后,则将视频流的拉流地址发送至服务节点。After the rendering node obtains the pull stream address of the video stream, it sends the pull stream address of the video stream to the service node.
211、服务节点向客户端发送携带有视频流的拉流地址的通知信息。211. The service node sends notification information carrying the streaming address of the video stream to the client.
服务节点接收到视频流的拉流地址后,则将该拉流地址包装成通知信息,通知信息用于指示客户端从拉流地址获取视频流并在目标显示区域播放视频流。然后,服务节点将通知信息发送至客户端。After receiving the pull stream address of the video stream, the service node wraps the pull stream address into notification information, and the notification information is used to instruct the client to obtain the video stream from the pull stream address and play the video stream in the target display area. Then, the service node sends the notification information to the client.
212、客户端从拉流地址获取视频流,并在目标显示区域播放视频流。212. The client obtains the video stream from the streaming address, and plays the video stream in the target display area.
客户端接收来自服务节点的通知信息后,可从通知信息中获取视频流的拉流地址。然后,基于拉流地址从渲染节点中获取已编码的视频流,并已编码的视频流进行解码,最后在目标显示区域中播放已解码的视频流。如此一来,客户端则可在屏幕的目标显示区域中播放视频流,在屏幕的其余区域中显示文本信息,展现一个完整的三维网页供用户使用。After receiving the notification information from the service node, the client can obtain the streaming address of the video stream from the notification information. Then, obtain the encoded video stream from the rendering node based on the pull stream address, decode the encoded video stream, and finally play the decoded video stream in the target display area. In this way, the client can play the video stream in the target display area of the screen, display text information in the rest of the screen, and present a complete three-dimensional web page for the user to use.
本申请实施例中,服务节点接收自客户端针对目标显示区域的渲染指令后,可向渲染节点发送渲染请求,以使得渲染节点调用自身的GPU针对目标显示区域进行渲染,得到视 频流。然后,服务节点向客户端发送携带有视频流的拉流地址的通知信息,以使得客户端基于拉流地址从渲染节点获取视频流,从而在目标显示区域中播放视频流。前述过程中,由于视频流的渲染处理是由远程的渲染节点完成的,渲染节点的GPU的计算能力通常较强,可渲染出质量较优的视频流。故客户端所在的终端设备即使算力受限,也可从渲染单元获取已渲染的质量较优的视频流,并在目标显示区域中播放该视频流,从而提高用户体验。In the embodiment of the present application, after receiving the rendering instruction for the target display area from the client, the service node may send a rendering request to the rendering node, so that the rendering node invokes its own GPU to render the target display area to obtain a video stream. Then, the service node sends notification information carrying the streaming address of the video stream to the client, so that the client obtains the video stream from the rendering node based on the streaming address, so as to play the video stream in the target display area. In the foregoing process, since the rendering processing of the video stream is completed by a remote rendering node, the GPU of the rendering node generally has relatively strong computing power, and can render a video stream with better quality. Therefore, even if the computing power of the terminal device where the client is located is limited, it can obtain the rendered video stream with better quality from the rendering unit, and play the video stream in the target display area, thereby improving user experience.
图3为本申请实施例提供的基于云服务的渲染方法的另一流程示意图,如图3所示,该方法包括:FIG. 3 is another schematic flowchart of a rendering method based on a cloud service provided by an embodiment of the present application. As shown in FIG. 3 , the method includes:
301、管理人员预先在渲染节点中部署视频流的渲染程序。301. The administrator deploys the rendering program of the video stream in the rendering node in advance.
管理人员(通常是三维页面的拥有者)可将视频流等动态内容的渲染程序进行打包,然后预先部署在渲染节点中,如此一来,渲染节点相当于提前存储有视频流的渲染程序。Managers (usually the owners of 3D pages) can package rendering programs for dynamic content such as video streams, and then pre-deploy them in rendering nodes. In this way, rendering nodes are equivalent to rendering programs that store video streams in advance.
302、渲染节点与服务节点预先记录视频流的拉流地址。302. The rendering node and the service node pre-record the streaming address of the video stream.
渲染节点还可与服务节点进行事先约定,共同为视频流提前设置专属的拉流地址,并存储视频流的拉流地址。关于视频流的拉流地址的介绍,可参考图2所示实施例中步骤209的相关说明部分,此处不再赘述。The rendering node can also make a prior agreement with the service node to jointly set a dedicated streaming address for the video stream in advance, and store the streaming address of the video stream. For the introduction of the streaming address of the video stream, reference may be made to the relevant description part of step 209 in the embodiment shown in FIG. 2 , and details are not repeated here.
303、服务节点提供三维网页的访问入口。303. The service node provides an access entry for the three-dimensional webpage.
304、服务节点接收客户端针对三维网页的访问请求。304. The service node receives an access request from the client for the three-dimensional webpage.
305、服务节点根据访问请求向客户端发送三维网页的渲染指令。305. The service node sends a rendering instruction of the three-dimensional webpage to the client according to the access request.
306、客户端根据三维网页的渲染指令检测本地的渲染能力,并判断本地的渲染能力是否满足要求。306. The client detects the local rendering capability according to the rendering instruction of the 3D webpage, and determines whether the local rendering capability meets the requirements.
307、若客户端确定本地的渲染能力不满足要求,则向服务节点发送针对目标显示区域的渲染指令。307. If the client determines that the local rendering capability does not meet the requirements, send a rendering instruction for the target display area to the service node.
308、服务节点根据针对目标显示区域的渲染指令向渲染节点发送渲染请求。308. The service node sends a rendering request to the rendering node according to the rendering instruction for the target display area.
309、渲染节点根据渲染请求进行渲染准备。309. The rendering node prepares for rendering according to the rendering request.
关于步骤303至步骤309的介绍,可参考图2所示实施例中步骤201至步骤207的相关说明部分,此处不再赘述。For the introduction of step 303 to step 309, reference may be made to the relevant description part of step 201 to step 207 in the embodiment shown in FIG. 2, and details are not repeated here.
310、渲染节点执行视频流的渲染程序,以生成包括多个播放画面的视频流。310. The rendering node executes a rendering program of the video stream to generate a video stream including multiple playback pictures.
本实施例中,由于渲染节点预先存储有视频流的渲染程序,故渲染节点完成渲染准备后,可直接执行视频流的渲染程序,以生成可在目标显示区域中播放的视频流。In this embodiment, since the rendering node pre-stores the rendering program of the video stream, the rendering node can directly execute the rendering program of the video stream after completing the rendering preparation, so as to generate a video stream that can be played in the target display area.
311、服务节点向客户端发送携带有视频流的拉流地址的通知信息。311. The service node sends notification information carrying the streaming address of the video stream to the client.
在渲染节点完成渲染得到视频流后,服务节点可在本地获取预先存储的视频流的拉流地址,并将视频流的拉流地址包装成通知信息,再将通知信息发送至客户端。After the rendering node completes the rendering and obtains the video stream, the service node can locally obtain the pull address of the pre-stored video stream, wrap the pull address of the video stream into notification information, and then send the notification information to the client.
312、客户端从拉流地址获取视频流,并在目标显示区域播放视频流。312. The client obtains the video stream from the streaming address, and plays the video stream in the target display area.
关于步骤312的介绍,可参考图2所示实施例中步骤212的相关说明部分,此处不再赘述。For the introduction of step 312, reference may be made to the relevant description part of step 212 in the embodiment shown in FIG. 2, and details are not repeated here.
图4为本申请实施例提供的基于云服务的渲染方法的又一流程示意图,如图4所示,该方法包括:FIG. 4 is another schematic flowchart of a cloud service-based rendering method provided by an embodiment of the present application. As shown in FIG. 4 , the method includes:
401、服务节点提供三维网页的访问入口。401. The service node provides an access entry for a three-dimensional webpage.
402、服务节点接收客户端针对三维网页的访问请求。402. The service node receives an access request from the client for the three-dimensional webpage.
403、服务节点根据访问请求向客户端发送三维网页的渲染指令。403. The service node sends a rendering instruction of the three-dimensional webpage to the client according to the access request.
404、客户端根据三维网页的渲染指令检测本地的渲染能力,并判断本地的渲染能力是否满足要求。404. The client detects the local rendering capability according to the rendering instruction of the 3D webpage, and determines whether the local rendering capability meets the requirements.
关于步骤401至步骤404的介绍,可参考图2所示实施例中步骤201至步骤204的相关说明部分,此处不再赘述。For the introduction of steps 401 to 404 , reference may be made to the relevant descriptions of steps 201 to 204 in the embodiment shown in FIG. 2 , and details are not repeated here.
405、若客户端确定本地的渲染能力不满足要求,则向渲染节点发送视频流的渲染程序。405. If the client determines that the local rendering capability does not meet the requirements, send the rendering program of the video stream to the rendering node.
本实施例中,若客户端确定本地的渲染能力不满足要求,由于客户端中已得到三维页面的渲染程序(在步骤403中,从服务节点中获取得到),故客户端直接将视频流的渲染程序发送至渲染节点。In this embodiment, if the client determines that the local rendering capability does not meet the requirements, since the rendering program of the 3D page has been obtained in the client (obtained from the service node in step 403), the client directly converts the video stream to the rendering program. The renderer is sent to the render node.
406、渲染节点进行渲染准备。406. The rendering node prepares for rendering.
渲染节点接收来自客户端的视频流的渲染程序后,则进行一系列跟客户端相关的渲染准备。渲染节点进行渲染准备的过程,可参考图2所示实施例中步骤207的相关说明部分,此处不再赘述。After the rendering node receives the rendering program of the video stream from the client, it performs a series of rendering preparations related to the client. For the process of rendering preparation by the rendering node, reference may be made to the relevant description part of step 207 in the embodiment shown in FIG. 2 , and details are not repeated here.
407、渲染节点执行视频流的渲染程序,以生成包括多个播放画面的视频流,并为视频流设置拉流地址。407. The rendering node executes a rendering program of the video stream to generate a video stream including multiple playback pictures, and sets a streaming address for the video stream.
关于步骤407的介绍,可参考图2所示实施例中步骤209的相关说明部分,此处不再赘述。For the introduction of step 407, reference may be made to the relevant description part of step 209 in the embodiment shown in FIG. 2, and details are not repeated here.
408、渲染节点向客户端发送视频流的拉流地址。408. The rendering node sends the streaming address of the video stream to the client.
在渲染节点完成渲染得到视频流后,且为视频流设置专属的拉流地址后,则将拉流地址直接发送至客户端。渲染节点将拉流地址发送至客户端的方式有多种,例如,渲染节点可直接将视频流的拉流地址发送至渲染节点,又如,渲染节点可将视频流的拉流地址发送至服务节点,使得服务节点将视频流的拉流地址包装成通知信息,再发送至客户端等等。After the rendering node completes rendering and obtains the video stream, and after setting a dedicated streaming address for the video stream, the streaming address is sent directly to the client. There are various ways for the render node to send the pull stream address to the client. For example, the render node can directly send the pull stream address of the video stream to the render node, and for example, the render node can send the pull stream address of the video stream to the service node. , so that the service node wraps the pull stream address of the video stream into notification information, and then sends it to the client and so on.
409、客户端从拉流地址获取视频流,并在目标显示区域播放视频流。409. The client obtains the video stream from the streaming address, and plays the video stream in the target display area.
关于步骤409的介绍,可参考图2所示实施例中步骤212的相关说明部分,此处不再赘述。For the introduction of step 409, reference may be made to the relevant description part of step 212 in the embodiment shown in FIG. 2, and details are not repeated here.
以上是对本申请实施例提供的基于云服务的渲染方法所进行的详细说明,以下将对本申请实施例提供的基于云服务的渲染装置进行介绍。图5为本申请实施例提供的基于云服务的渲染装置的一个结构示意图,如图5所示,该装置即为前述的服务节点,该装置包括:The above is a detailed description of the rendering method based on the cloud service provided by the embodiment of the present application, and the following will introduce the rendering device based on the cloud service provided by the embodiment of the present application. FIG. 5 is a schematic structural diagram of a cloud service-based rendering device provided by an embodiment of the present application. As shown in FIG. 5 , the device is the aforementioned service node, and the device includes:
接收模块501,用于接收客户端针对目标显示区域的渲染指令;A receiving module 501, configured to receive a client rendering instruction for the target display area;
发送模块503,用于根据渲染指令向渲染节点发送渲染请求,渲染请求用于指示渲染节点调用设置在渲染节点的图像处理单元GPU针对目标显示区域进行渲染以生成包括多个播放画面的视频流;The sending module 503 is used to send a rendering request to the rendering node according to the rendering instruction, and the rendering request is used to instruct the rendering node to call the image processing unit GPU arranged on the rendering node to render the target display area to generate a video stream including a plurality of playback pictures;
发送模块503,还用于向客户端发送携带有视频流的拉流地址的通知信息,通知信息 用于指示客户端从拉流地址获取视频流并在目标显示区域播放视频流。The sending module 503 is also used to send notification information carrying the pull stream address of the video stream to the client, where the notification information is used to instruct the client to obtain the video stream from the pull stream address and play the video stream in the target display area.
从上述装置可以看出:服务节点接收自客户端针对目标显示区域的渲染指令后,可向渲染节点发送渲染请求,以使得渲染节点调用自身的GPU针对目标显示区域进行渲染,得到视频流。然后,服务节点向客户端发送携带有视频流的拉流地址的通知信息,以使得客户端基于拉流地址从渲染节点获取视频流,从而在目标显示区域中播放视频流。前述过程中,由于视频流的渲染处理是由远程的渲染节点完成的,渲染节点的GPU的计算能力通常较强,可渲染出质量较优的视频流。故客户端所在的终端设备即使算力受限,也可从渲染单元获取已渲染的质量较优的视频流,并在目标显示区域中播放该视频流,从而提高用户体验。It can be seen from the above device that after receiving the rendering instruction for the target display area from the client, the service node can send a rendering request to the rendering node, so that the rendering node invokes its own GPU to render the target display area to obtain a video stream. Then, the service node sends notification information carrying the streaming address of the video stream to the client, so that the client obtains the video stream from the rendering node based on the streaming address, so as to play the video stream in the target display area. In the foregoing process, since the rendering processing of the video stream is completed by a remote rendering node, the GPU of the rendering node generally has relatively strong computing power, and can render a video stream with better quality. Therefore, even if the computing power of the terminal device where the client is located is limited, it can obtain the rendered video stream with better quality from the rendering unit, and play the video stream in the target display area, thereby improving user experience.
在一种可能的实现方式中,渲染指令携带有渲染需求信息,该装置还包括:处理模块502,用于从渲染资源池中选择与渲染需求信息匹配的渲染节点。In a possible implementation manner, the rendering instruction carries rendering requirement information, and the apparatus further includes: a processing module 502, configured to select a rendering node matching the rendering requirement information from the rendering resource pool.
在一种可能的实现方式中,渲染指令携带有渲染需求信息,该装置还包括:处理模块502,用于调用云服务创建渲染需求信息匹配的渲染节点。In a possible implementation manner, the rendering instruction carries rendering requirement information, and the apparatus further includes: a processing module 502, configured to call a cloud service to create a rendering node matching the rendering requirement information.
在一种可能的实现方式中,渲染节点包括设置在数据中心的设置有GPU的虚拟机、容器以及裸金属服务器。In a possible implementation manner, the rendering node includes a virtual machine provided with a GPU, a container, and a bare metal server provided in a data center.
在一种可能的实现方式中,渲染节点为设置有GPU的物理服务器。In a possible implementation manner, the rendering node is a physical server provided with a GPU.
在一种可能的实现方式中,发送模块503,还用于提供三维网页的访问入口;接收模块501,还用于接收客户端针对三维网页的访问请求;发送模块503,还用于根据访问请求向客户端发送三维网页的渲染指令。In a possible implementation manner, the sending module 503 is further configured to provide an access entry for the three-dimensional web page; the receiving module 501 is further configured to receive an access request from the client for the three-dimensional web page; the sending module 503 is further configured to access the three-dimensional web page according to the access request Send a rendering command of the 3D web page to the client.
在一种可能的实现方式中,接收模块501,还用于接收渲染节点发送的拉流地址。In a possible implementation manner, the receiving module 501 is further configured to receive the streaming address sent by the rendering node.
在一种可能的实现方式中,处理模块502,还用于预先记录拉流地址。In a possible implementation manner, the processing module 502 is further configured to record the pull stream address in advance.
需要说明的是,上述装置各模块/单元之间的信息交互、执行过程等内容,由于与本申请方法实施例基于同一构思,其带来的技术效果与本申请方法实施例相同,具体内容可参考本申请实施例前述所示的方法实施例中的叙述,此处不再赘述。It should be noted that the information exchange, execution process and other contents between the modules/units of the above-mentioned apparatus are based on the same concept as the method embodiments of the present application, and the technical effects brought by them are the same as those of the method embodiments of the present application, and the specific content can be Reference is made to the descriptions in the method embodiments shown in the foregoing embodiments of the present application, which will not be repeated here.
图6为本申请实施例提供的网络设备的一个结构示意图。如图6所示,本申请实施例中网络设备一个实施例可以包括一个或一个以上中央处理器601,存储器602,输入输出接口603,有线或无线网络接口604,电源605。FIG. 6 is a schematic structural diagram of a network device provided by an embodiment of the present application. As shown in FIG. 6 , an embodiment of the network device in this embodiment of the present application may include one or more central processing units 601 , a memory 602 , an input/output interface 603 , a wired or wireless network interface 604 , and a power supply 605 .
存储器602可以是短暂存储或持久存储。更进一步地,中央处理器601可以配置为与存储器602通信,在网络设备上执行存储器602中的一系列指令操作。The memory 602 may be ephemeral storage or persistent storage. Furthermore, the central processing unit 601 may be configured to communicate with the memory 602 to execute a series of instruction operations in the memory 602 on the network device.
本实施例中,中央处理器601可以执行前述图2、图3和图4所示实施例中服务节点所执行的操作,具体此处不再赘述。In this embodiment, the central processing unit 601 may perform the operations performed by the service nodes in the foregoing embodiments shown in FIG. 2 , FIG. 3 , and FIG. 4 , and details are not repeated here.
本实施例中,中央处理器601中的具体功能模块划分可以与前述图5中所描述的接收模块、处理模块和发送模块等模块的划分方式类似,此处不再赘述。In this embodiment, the division of specific functional modules in the central processing unit 601 may be similar to the division of modules such as the receiving module, the processing module, and the sending module described above in FIG. 5 , which will not be repeated here.
本申请实施例还涉及一种计算机存储介质,包括计算机可读指令,当所述计算机可读指令被执行时,实现如图2、图3和图4所述的方法。The embodiments of the present application also relate to a computer storage medium, including computer-readable instructions, when the computer-readable instructions are executed, the methods described in FIG. 2 , FIG. 3 and FIG. 4 are implemented.
本申请实施例还涉及一种包含指令的计算机程序产品,当其在计算机上运行时,使得计算机执行如图2、图3和图4所述的方法。Embodiments of the present application also relate to a computer program product containing instructions, which, when executed on a computer, cause the computer to execute the methods described in FIG. 2 , FIG. 3 and FIG. 4 .
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the system, device and unit described above can refer to the corresponding process in the foregoing method embodiments, which is not repeated here.
在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the apparatus embodiments described above are only illustrative. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components may be combined or Can be integrated into another system, or some features can be ignored, or not implemented. On the other hand, the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit. The above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。The integrated unit, if implemented in the form of a software functional unit and sold or used as an independent product, may be stored in a computer-readable storage medium. Based on this understanding, the technical solutions of the present application can be embodied in the form of software products in essence, or the parts that contribute to the prior art, or all or part of the technical solutions, and the computer software products are stored in a storage medium , including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, Read-Only Memory (ROM, Read-Only Memory), Random Access Memory (RAM, Random Access Memory), magnetic disk or optical disk and other media that can store program codes .

Claims (19)

  1. 一种基于云服务的渲染方法,其特征在于,所述方法包括:A rendering method based on cloud services, characterized in that the method comprises:
    服务节点接收客户端针对目标显示区域的渲染指令;The service node receives the client's rendering instruction for the target display area;
    所述服务节点根据所述渲染指令向渲染节点发送渲染请求,所述渲染请求用于指示所述渲染节点调用设置在所述渲染节点的图像处理单元GPU针对所述目标显示区域进行渲染以生成包括多个播放画面的视频流;The service node sends a rendering request to the rendering node according to the rendering instruction, where the rendering request is used to instruct the rendering node to call the image processing unit GPU disposed on the rendering node to render the target display area to generate a rendering including: Video streams of multiple playback screens;
    所述服务节点向所述客户端发送携带有所述视频流的拉流地址的通知信息,所述通知信息用于指示所述客户端从所述拉流地址获取所述视频流并在所述目标显示区域播放所述视频流。The service node sends notification information carrying the streaming address of the video stream to the client, where the notification information is used to instruct the client to obtain the video stream from the streaming address and upload the video stream in the The target display area plays the video stream.
  2. 根据权利要求1所述的方法,其特征在于,所述渲染指令携带有渲染需求信息,所述服务节点向渲染节点发送所述渲染请求之前,所述方法还包括:The method according to claim 1, wherein the rendering instruction carries rendering requirement information, and before the service node sends the rendering request to the rendering node, the method further comprises:
    所述服务节点从渲染资源池中选择与所述渲染需求信息匹配的所述渲染节点。The service node selects the rendering node matching the rendering requirement information from the rendering resource pool.
  3. 根据权利要求1所述的方法,其特征在于,所述渲染指令携带有渲染需求信息,所述服务节点向渲染节点发送所述渲染请求之前,所述方法还包括:The method according to claim 1, wherein the rendering instruction carries rendering requirement information, and before the service node sends the rendering request to the rendering node, the method further comprises:
    所述服务节点调用云服务创建所述渲染需求信息匹配的所述渲染节点。The service node invokes a cloud service to create the rendering node matching the rendering requirement information.
  4. 根据权利要求2或3所述的方法,其特征在于,所述渲染节点包括设置在数据中心的设置有所述GPU的虚拟机、容器以及裸金属服务器。The method according to claim 2 or 3, wherein the rendering node comprises a virtual machine provided with the GPU, a container and a bare metal server provided in a data center.
  5. 根据权利要求1所述的方法,其特征在于,所述渲染节点为设置有所述GPU的物理服务器。The method according to claim 1, wherein the rendering node is a physical server provided with the GPU.
  6. 根据权利要求1至5任一项所述的方法,其特征在于,所述服务节点接收客户端针对目标显示区域的渲染请求之前,所述方法还包括:The method according to any one of claims 1 to 5, wherein before the service node receives a rendering request from the client for the target display area, the method further comprises:
    所述服务节点提供三维网页的访问入口;The service node provides the access portal of the three-dimensional webpage;
    所述服务节点接收所述客户端针对所述三维网页的访问请求;receiving, by the service node, an access request from the client for the three-dimensional web page;
    所述服务节点根据所述访问请求向所述客户端发送所述三维网页的渲染指令。The service node sends a rendering instruction of the three-dimensional webpage to the client according to the access request.
  7. 根据权利要求1至6任一项所述的方法,其特征在于,所述服务节点向所述客户端发送携带有所述视频流的拉流地址的通知信息之前,所述方法还包括:The method according to any one of claims 1 to 6, wherein before the service node sends the notification information carrying the streaming address of the video stream to the client, the method further comprises:
    所述服务节点接收所述渲染节点发送的所述拉流地址。The service node receives the streaming address sent by the rendering node.
  8. 根据权利要求1至6任一项所述的方法,其特征在于,所述服务节点向所述客户端发送携带有所述视频流的拉流地址的通知信息之前,所述方法还包括:The method according to any one of claims 1 to 6, wherein before the service node sends the notification information carrying the streaming address of the video stream to the client, the method further comprises:
    所述服务节点预先记录所述拉流地址。The service node pre-records the pull stream address.
  9. 一种基于云服务的渲染装置,其特征在于,所述装置包括:A cloud service-based rendering device, characterized in that the device comprises:
    接收模块,用于接收客户端针对目标显示区域的渲染指令;The receiving module is used to receive the rendering instruction of the client for the target display area;
    发送模块,用于根据所述渲染指令向渲染节点发送渲染请求,所述渲染请求用于指示所述渲染节点调用设置在所述渲染节点的图像处理单元GPU针对所述目标显示区域进行渲染以生成包括多个播放画面的视频流;A sending module, configured to send a rendering request to a rendering node according to the rendering instruction, where the rendering request is used to instruct the rendering node to call the image processing unit GPU disposed on the rendering node to render the target display area to generate A video stream including multiple playback screens;
    所述发送模块,还用于向所述客户端发送携带有所述视频流的拉流地址的通知信息,所述通知信息用于指示所述客户端从所述拉流地址获取所述视频流并在所述目标显示区域 播放所述视频流。The sending module is further configured to send notification information carrying the streaming address of the video stream to the client, where the notification information is used to instruct the client to obtain the video stream from the streaming address and play the video stream in the target display area.
  10. 根据权利要求9所述的装置,其特征在于,所述渲染指令携带有渲染需求信息,所述装置还包括:The apparatus according to claim 9, wherein the rendering instruction carries rendering requirement information, and the apparatus further comprises:
    处理模块,用于从渲染资源池中选择与所述渲染需求信息匹配的所述渲染节点。A processing module, configured to select the rendering node matching the rendering requirement information from the rendering resource pool.
  11. 根据权利要求9所述的装置,其特征在于,所述渲染指令携带有渲染需求信息,所述装置还包括:The apparatus according to claim 9, wherein the rendering instruction carries rendering requirement information, and the apparatus further comprises:
    处理模块,用于调用云服务创建所述渲染需求信息匹配的所述渲染节点。A processing module, configured to call a cloud service to create the rendering node matching the rendering requirement information.
  12. 根据权利要求10或11所述的装置,其特征在于,所述渲染节点包括设置在数据中心的设置有所述GPU的虚拟机、容器以及裸金属服务器。The apparatus according to claim 10 or 11, wherein the rendering node comprises a virtual machine provided with the GPU, a container and a bare metal server provided in a data center.
  13. 根据权利要求9所述的装置,其特征在于,所述渲染节点为设置有所述GPU的物理服务器。The apparatus according to claim 9, wherein the rendering node is a physical server provided with the GPU.
  14. 根据权利要求9至13任一项所述的装置,其特征在于,所述发送模块,还用于提供三维网页的访问入口;The device according to any one of claims 9 to 13, wherein the sending module is further configured to provide an access entry for a three-dimensional webpage;
    所述接收模块,还用于接收所述客户端针对所述三维网页的访问请求;The receiving module is further configured to receive an access request from the client for the three-dimensional webpage;
    所述发送模块,还用于根据所述访问请求向所述客户端发送所述三维网页的渲染指令。The sending module is further configured to send a rendering instruction of the three-dimensional webpage to the client according to the access request.
  15. 根据权利要求9至14任一项所述的装置,其特征在于,所述接收模块,还用于接收所述渲染节点发送的所述拉流地址。The apparatus according to any one of claims 9 to 14, wherein the receiving module is further configured to receive the pull stream address sent by the rendering node.
  16. 根据权利要求9至14任一项所述的装置,其特征在于,所述处理模块,还用于预先记录所述拉流地址。The apparatus according to any one of claims 9 to 14, wherein the processing module is further configured to record the pull stream address in advance.
  17. 一种网络设备,其特征在于,所述网络设备包括:处理器和存储器;A network device, characterized in that the network device comprises: a processor and a memory;
    所述存储器用于存储计算机执行指令;the memory is used to store computer-executable instructions;
    所述处理器用于执行所述存储器所存储的计算机执行指令,以使所述网络设备实现如所述权利要求1至8任一项所述的方法。The processor is configured to execute computer-executable instructions stored in the memory to cause the network device to implement the method of any one of claims 1 to 8.
  18. 一种计算机存储介质,其特征在于,包括计算机可读指令,当所述计算机可读指令被执行时,实现如权利要求1至8任一项所述的方法。A computer storage medium, characterized by comprising computer-readable instructions, which, when executed, implement the method according to any one of claims 1 to 8.
  19. 一种包含指令的计算机程序产品,当其在计算机上运行时,使得计算机执行如权利要求1至8任一项所述的方法。A computer program product comprising instructions which, when run on a computer, cause the computer to perform the method of any one of claims 1 to 8.
PCT/CN2021/139019 2020-12-18 2021-12-17 Rendering method based on cloud service, and related device therefor WO2022127890A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011505914.5A CN114650434A (en) 2020-12-18 2020-12-18 Cloud service-based rendering method and related equipment thereof
CN202011505914.5 2020-12-18

Publications (1)

Publication Number Publication Date
WO2022127890A1 true WO2022127890A1 (en) 2022-06-23

Family

ID=81991685

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/139019 WO2022127890A1 (en) 2020-12-18 2021-12-17 Rendering method based on cloud service, and related device therefor

Country Status (2)

Country Link
CN (1) CN114650434A (en)
WO (1) WO2022127890A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115665120A (en) * 2022-12-28 2023-01-31 浙江华东工程数字技术有限公司 Cloud CAD processing method and system, computer equipment and storage medium
CN117119264A (en) * 2023-10-18 2023-11-24 北京奇点智播科技有限公司 Video data processing system and method

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115278301B (en) * 2022-07-27 2023-12-22 河南昆仑技术有限公司 Video processing method, system and equipment
CN115904514B (en) * 2022-11-17 2023-07-14 广州极数科技有限公司 Method for realizing cloud rendering pixel flow based on three-dimensional scene and terminal equipment

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105242957A (en) * 2015-09-28 2016-01-13 广州云晫信息科技有限公司 Method and system for cloud computing system to allocate GPU resources to virtual machine
CN105635751A (en) * 2015-12-25 2016-06-01 北京大学第三医院 Video cloud platform video playing method and device
CN110557624A (en) * 2019-07-16 2019-12-10 西安万像电子科技有限公司 Data transmission method and device and server
CN111450528A (en) * 2020-03-31 2020-07-28 网易(杭州)网络有限公司 Cloud game rendering service system, method and device
CN111614780A (en) * 2020-05-28 2020-09-01 深圳航天智慧城市系统技术研究院有限公司 Cloud rendering system and method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105242957A (en) * 2015-09-28 2016-01-13 广州云晫信息科技有限公司 Method and system for cloud computing system to allocate GPU resources to virtual machine
CN105635751A (en) * 2015-12-25 2016-06-01 北京大学第三医院 Video cloud platform video playing method and device
CN110557624A (en) * 2019-07-16 2019-12-10 西安万像电子科技有限公司 Data transmission method and device and server
CN111450528A (en) * 2020-03-31 2020-07-28 网易(杭州)网络有限公司 Cloud game rendering service system, method and device
CN111614780A (en) * 2020-05-28 2020-09-01 深圳航天智慧城市系统技术研究院有限公司 Cloud rendering system and method

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115665120A (en) * 2022-12-28 2023-01-31 浙江华东工程数字技术有限公司 Cloud CAD processing method and system, computer equipment and storage medium
CN117119264A (en) * 2023-10-18 2023-11-24 北京奇点智播科技有限公司 Video data processing system and method
CN117119264B (en) * 2023-10-18 2024-01-26 北京奇点智播科技有限公司 Video data processing system and method

Also Published As

Publication number Publication date
CN114650434A (en) 2022-06-21

Similar Documents

Publication Publication Date Title
WO2022127890A1 (en) Rendering method based on cloud service, and related device therefor
US9836437B2 (en) Screencasting for multi-screen applications
KR20220093216A (en) Information reproduction method, apparatus, computer readable storage medium and electronic device
CN107645491A (en) Media flow transmission equipment and media serving device
CN110446114B (en) Multimedia data processing device, method, electronic equipment and storage medium
WO2021082299A1 (en) Video playback method and device
WO2019024658A1 (en) Interface display method and apparatus
CN112383539A (en) Method and device for calling cloud browser based on remote process and electronic equipment
WO2022057575A1 (en) Multimedia data publishing method and apparatus, and device and medium
CN107409237A (en) Adjusted for the cloud game data flowable state of output device and network quality
US11809771B2 (en) Orchestrated control for displaying media
JP6588577B2 (en) Conversion of FLASH content to HTML content by generating an instruction list
CN112055252A (en) Multi-screen interaction method and device, computer readable medium and electronic equipment
JP2024504053A (en) Two-dimensional code display method, apparatus, device and medium
WO2017140226A1 (en) Video processing method and device therefor
Lee et al. FLUID-XP: flexible user interface distribution for cross-platform experience
Zorrilla et al. HTML5-based system for interoperable 3D digital home applications
WO2021098306A1 (en) Object comparison method, and device
CN107241651B (en) Media data playing method and device and intelligent terminal
US20190230188A1 (en) Hosted application as web widget toolkit
CN113315982B (en) Live broadcast method, computer storage medium and equipment
EP3229478B1 (en) Cloud streaming service system, image cloud streaming service method using application code, and device therefor
US10296592B2 (en) Spherical video in a web browser
CN115052186B (en) Screen projection method and related equipment
CN117407611A (en) Portal wall-mounting method, portal wall-mounting device and computer storage medium

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21905816

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21905816

Country of ref document: EP

Kind code of ref document: A1