Screen projection method and device with efficient transmission, equipment and storage medium

By searching for screen projection devices in the terminal and dynamically adjusting the compression algorithm according to network and performance parameters, the audio and video data is processed, and the problem of delay and lag in wireless screen projection technology is solved, improving the transmission effect and user experience.

CN118945408APending Publication Date: 2024-11-12LANGYUAN TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202410936989.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-12
Publication Date
2024-11-12

AI Technical Summary

Technical Problem

The existing wireless screen projection technology has limitations in terms of high bandwidth requirements and real-time performance, resulting in delay, lag and packet loss in video data when the network is not in good condition, affecting the transmission effect and user experience.

Method used

Search the screen projection device through the terminal and establish a network connection, obtain network and performance parameters, determine the target compression algorithm from the compression algorithm library based on these parameters, compress and encode the audio and video data, and dynamically adjust the compression algorithm to optimize transmission.

Benefits of technology

Improves the real-time and user experience of data transmission, ensures compression effect, and adapts to data transmission under different network and performance conditions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118945408A_ABST
    Figure CN118945408A_ABST
Patent Text Reader

Abstract

The invention provides an efficient transmission screen projection method, device and equipment and a storage medium, and the efficient transmission screen projection method comprises the steps: searching screen projection equipment through a terminal, building network connection with the screen projection equipment, obtaining the network parameters of a connected network and the performance parameters of the terminal, and carrying out the screen projection according to the network parameters and the performance parameters. And determining a target compression algorithm from the compression algorithm library, performing compression processing on the audio and video data through the target compression algorithm to obtain compressed data, performing coding processing on the compressed data, and sending a coding processing result to the screen projection equipment for display, the audio and video data are compressed through the target compression algorithm and then transmitted to the screen projection equipment, so that the real-time performance of data transmission is improved, and the transmission effect and the user experience are improved; meanwhile, based on the network parameters and the performance parameters, the target compression algorithm is determined from the compression algorithm library for compression, the compression effect is guaranteed, and the data transmission effect is better guaranteed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of screen projection, and in particular to a screen projection method, device, equipment and storage medium for efficient transmission. Background Art

[0002] Existing wireless screen projection technology has certain limitations in terms of high bandwidth requirements and real-time performance. Traditional methods usually transmit the video data to be transmitted directly to the screen projection device without any processing. Due to the large size of video data, delays, freezes and packet loss are often prone to occur when the network conditions are poor, affecting the transmission effect and user experience. Summary of the invention

[0003] The embodiments of the present application provide a screen projection method, device, equipment and storage medium for efficient transmission to solve at least one problem existing in the related art. The technical solution is as follows:

[0004] In a first aspect, an embodiment of the present application provides a method for screen projection with efficient transmission, including:

[0005] Search for a screen projection device through the terminal and establish a network connection with the screen projection device;

[0006] Acquire network parameters of the connected network and performance parameters of the terminal, and determine a target compression algorithm from a compression algorithm library according to the network parameters and the performance parameters;

[0007] Compressing the audio and video data using the target compression algorithm to obtain compressed data;

[0008] The compressed data is encoded and the encoding result is sent to the screen projection device for display.

[0009] In one embodiment, the network parameter includes at least one of bandwidth, delay, and packet loss rate, and the performance parameter includes CPU performance, memory capacity, and GPU performance; and determining the target compression algorithm from the compression algorithm library according to the network parameter and the performance parameter includes:

[0010] Obtaining a network evaluation result according to at least one of bandwidth, delay, and packet loss rate;

[0011] Determining a target compression algorithm from a compression algorithm library according to CPU performance, memory capacity, GPU performance, and the network evaluation result, wherein the network parameter includes at least one of bandwidth, delay, and packet loss rate, and the performance parameter includes CPU performance, memory capacity, and GPU performance; determining a target compression algorithm from a compression algorithm library according to the network parameter and the performance parameter includes:

[0012] Obtaining a network evaluation result according to at least one of bandwidth, delay, and packet loss rate;

[0013] A target compression algorithm is determined from a compression algorithm library according to CPU performance, memory capacity, GPU performance, and the network evaluation result.

[0014] In one implementation, determining a target compression algorithm from a compression algorithm library according to CPU performance, memory capacity, GPU performance, and the network evaluation result includes:

[0015] When the network evaluation result indicates poor performance, determining an H.264 compression algorithm from a compression algorithm library as a target compression algorithm;

[0016] When the network evaluation result is characterized well, one of the H.264 compression algorithm, the H.265 compression algorithm and the VP9 compression algorithm is determined as the target compression algorithm from the compression algorithm library according to the CPU performance, the memory capacity and the GPU performance.

[0017] In one implementation, when the network evaluation result is characterized as good, determining one of the H.264 compression algorithm, the H.265 compression algorithm, and the VP9 compression algorithm as the target compression algorithm from the compression algorithm library according to the CPU performance, the memory capacity, and the GPU performance includes:

[0018] When the network evaluation result is characterized as good and the CPU performance is characterized as good, if the memory capacity is greater than or equal to the capacity threshold, the H.265 compression algorithm is used as the target compression algorithm; if the memory capacity is less than the capacity threshold, the VP9 compression algorithm is used as the target compression algorithm;

[0019] When the network evaluation result is characterized as good and the CPU performance is characterized as poor, if the memory capacity is greater than or equal to the capacity threshold and the GPU performance is characterized as good, the H.265 compression algorithm is used as the target compression algorithm; if the memory capacity is less than the capacity threshold, the H.264 compression algorithm is used as the target compression algorithm; if the memory capacity is greater than or equal to the capacity threshold and the GPU performance is characterized as poor, the H.264 compression algorithm is used as the target compression algorithm.

[0020] In one embodiment, the method further comprises:

[0021] Re-detecting the network parameters and the performance parameters at preset intervals or in real time, and returning to the step of determining a target compression algorithm from a compression algorithm library according to the network parameters and the performance parameters to dynamically adjust the target compression algorithm;

[0022] or,

[0023] Receive feedback information from the screen projection device, and adjust the current target compression algorithm according to the feedback information.

[0024] In one implementation, adjusting the current target compression algorithm according to the feedback information includes:

[0025] When the feedback information indicates that the transmission efficiency is low, the H.264 compression algorithm is used as the target compression algorithm, or if the current target compression algorithm is the H.264 compression algorithm, the compression parameters are optimized;

[0026] When the feedback information indicates that the definition is low, the H.265 compression algorithm or the VP9 compression algorithm is used as the target compression algorithm, or if the current target compression algorithm is the H.265 compression algorithm or the VP9 compression algorithm, the compression parameters are optimized;

[0027] The compression parameter includes at least one of a bit rate and a key frame interval.

[0028] In one embodiment, encoding the compressed data and sending the encoding result to the screen projection device for display includes:

[0029] Perform low-latency encoding on the compressed data, and segment and package the low-latency encoding result to obtain the encoding processing result;

[0030] Sending the encoding processing result to the screen projection device, decoding and restoring the encoding processing result to obtain audio and video data;

[0031] Performing time stamp synchronization on the video data and the corresponding audio data in the audio and video data;

[0032] When the video data includes multiple video streams, the split-screen function is triggered to display the video data corresponding to each video stream in the corresponding split-screen area, and play the audio data corresponding to the video data;

[0033] In response to the operation instructions of the user interface of the screen projection device, the playback, pause and volume of the corresponding audio data of any split-screen area are controlled.

[0034] In a second aspect, an embodiment of the present application provides a screen projection device with efficient transmission, including:

[0035] A connection module, used to search for a screen projection device through a terminal and establish a network connection with the screen projection device;

[0036] A determination module, used to obtain network parameters of the connected network and performance parameters of the terminal, and determine a target compression algorithm from a compression algorithm library according to the network parameters and the performance parameters;

[0037] A compression module, used to compress the audio and video data using the target compression algorithm to obtain compressed data;

[0038] The sending module is used to encode the compressed data and send the encoding result to the screen projection device for display.

[0039] In one embodiment, the compression module is further configured to:

[0040] Re-detecting the network parameters and the performance parameters at preset intervals or in real time, and returning to the step of determining a target compression algorithm from a compression algorithm library according to the network parameters and the performance parameters to dynamically adjust the target compression algorithm;

[0041] or,

[0042] Receive feedback information from the screen projection device, and adjust the current target compression algorithm according to the feedback information.

[0043] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a processor and a memory, wherein the memory stores instructions, and the instructions are loaded and executed by the processor to implement a method in any one of the above-mentioned embodiments.

[0044] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, which stores a computer program. When the computer program is executed, the method in any one of the above-mentioned embodiments is implemented.

[0045] The beneficial effects of the above technical solution include at least:

[0046] Search for the projection device through the terminal, establish a network connection with the projection device, obtain the network parameters of the connected network and the performance parameters of the terminal, determine the target compression algorithm from the compression algorithm library according to the network parameters and performance parameters, compress the audio and video data by the target compression algorithm to obtain compressed data, encode the compressed data, and send the encoded result to the projection device for display. Compressing the audio and video data by the target compression algorithm and then transmitting it to the projection device is beneficial to improving the real-time performance of data transmission, improving transmission effect and user experience; at the same time, based on the network parameters and performance parameters, determining the target compression algorithm from the compression algorithm library for compression is beneficial to ensuring the compression effect and better ensuring the data transmission effect.

[0047] The above summary is for illustrative purposes only and is not intended to be limiting in any way. In addition to the illustrative aspects, embodiments and features described above, further aspects, embodiments and features of the present application will be readily apparent by reference to the accompanying drawings and the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] In the accompanying drawings, unless otherwise specified, the same reference numerals throughout the multiple drawings represent the same or similar parts or elements. These drawings are not necessarily drawn to scale. It should be understood that these drawings only depict some embodiments disclosed in the present application and should not be regarded as limiting the scope of the present application.

[0049] Figure 1 A schematic diagram of the steps of a screen projection method for efficient transmission according to an embodiment of the present application;

[0050] Figure 2 This is a structural block diagram of a screen projection device for efficient transmission according to an embodiment of the present application;

[0051] Figure 3 This is a structural block diagram of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

[0052] In the following, only some exemplary embodiments are briefly described. As those skilled in the art will appreciate, the described embodiments may be modified in various ways without departing from the spirit or scope of the present application. Therefore, the drawings and descriptions are considered to be exemplary and non-restrictive in nature.

[0053] Reference Figure 1 , a flowchart of a screen projection method for efficient transmission according to an embodiment of the present application is shown, and the screen projection method for efficient transmission may at least include steps S100-S400:

[0054] S100. Search for a screen projection device through the terminal and establish a network connection with the screen projection device.

[0055] S200: Obtain network parameters of the connected network and performance parameters of the terminal, and determine a target compression algorithm from a compression algorithm library according to the network parameters and the performance parameters.

[0056] S300: compressing the audio and video data using a target compression algorithm to obtain compressed data.

[0057] Optionally, the terminal may determine the audio and video data locally, or download the audio and video data from a network or receive the audio and video data from other devices.

[0058] S400, encode the compressed data and send the encoding result to the screen projection device for display.

[0059] The technical solution of the embodiment of the present application searches for the screen projection device through the terminal, establishes a network connection with the screen projection device, obtains the network parameters of the connected network and the performance parameters of the terminal, determines the target compression algorithm from the compression algorithm library according to the network parameters and the performance parameters, compresses the audio and video data through the target compression algorithm to obtain compressed data, encodes the compressed data, and sends the encoded result to the screen projection device for display. The audio and video data are compressed by the target compression algorithm and then transmitted to the screen projection device, which is beneficial to improving the real-time performance of data transmission, improving the transmission effect and user experience; at the same time, based on the network parameters and the performance parameters, the target compression algorithm is determined from the compression algorithm library for compression, which is beneficial to ensuring the compression effect and better ensuring the data transmission effect.

[0060] In one embodiment, when a user needs to project the screen of a terminal, all devices in the local area network are scanned through the terminal's Wi-Fi, Bluetooth or other wireless communication protocols. The terminal screens the searched devices and retains devices with a screen projection function, namely, projection devices. Then, the terminal selects the projection device and establishes an initial connection with the projection device through a wireless communication protocol (such as Wi-Fi Direct or Miracast). After the initial connection is established, the terminal and the projection device further perform identity authentication and device pairing to ensure the security of the connection, thereby establishing a network connection between the terminal and the projection device.

[0061] In one embodiment, the terminal can obtain network parameters of the connected network and performance parameters of the terminal itself, the network parameters of the connected network include but are not limited to at least one of bandwidth, delay and packet loss rate, and the performance parameters of the terminal include CPU performance, memory capacity and GPU performance. Optionally, the terminal can be provided with a compression algorithm library or connected to the compression algorithm library through an interface, so as to utilize the compression algorithm in the compression algorithm library; the compression algorithm includes but is not limited to the H.264 compression algorithm, the H.265 compression algorithm and the VP9 compression algorithm. For example, the terminal can test the network through test software to determine the network parameters.

[0062] In one implementation, step S200 includes steps S210-S220:

[0063] S210: Obtain a network evaluation result according to at least one of bandwidth, delay, and packet loss rate.

[0064] Optionally, the first threshold, the second threshold and the third threshold can be set respectively, taking the bandwidth, delay and packet loss rate as an example, for example: 1), when any one of the bandwidth is less than the first threshold, the delay is greater than the first threshold and the packet loss rate is greater than the first threshold occurs, it can be considered that the network evaluation result is poorly characterized, otherwise the network evaluation result is well characterized; 2), when any two of the bandwidth is less than the first threshold, the delay is greater than the first threshold and the packet loss rate is greater than the first threshold occur, it can be considered that the network evaluation result is poorly characterized, otherwise the network evaluation result is well characterized; 3), when all of the bandwidth is less than the first threshold, the delay is greater than the first threshold and the packet loss rate is greater than the first threshold occur, it can be considered that the network evaluation result is poorly characterized, otherwise the network evaluation result is well characterized; 4), set a score threshold and different weight parameters, normalize the bandwidth, delay and packet loss rate, add a minus sign before the bandwidth, and then perform weighted calculation in combination with different weight parameters to obtain a calculation result. When the calculation result is less than the score threshold, it can be considered that the network evaluation result is well characterized, otherwise the network evaluation result is poorly characterized.

[0065] S220, determining a target compression algorithm from a compression algorithm library according to CPU performance, memory capacity, GPU performance, and network evaluation results.

[0066] Optionally, step S220 includes steps S2201-S2202:

[0067] S2201: When the network evaluation result indicates poor performance, determine the H.264 compression algorithm from the compression algorithm library as the target compression algorithm.

[0068] In one implementation, when the network evaluation result indicates poor performance, the computational complexity and delay need to be reduced as much as possible, so the H.264 compression algorithm is preferentially selected, and the terminal determines the H.264 compression algorithm as the target compression algorithm from the compression algorithm library.

[0069] S2202. When the network evaluation result is good, determine one of the H.264 compression algorithm, the H.265 compression algorithm, and the VP9 compression algorithm as the target compression algorithm from the compression algorithm library according to the CPU performance, memory capacity, and GPU performance.

[0070] It should be noted that different compression algorithms have different CPU computing requirements, and therefore different CPU performance requirements and resource usage. At the same time, a large amount of memory is required during video compression and transmission, especially for high-resolution, high-frame-rate videos. On devices with limited memory resources, the system needs to select a compression algorithm that takes up less memory and adjust the appropriate cache size to avoid freezes or crashes caused by insufficient memory. In addition, some compression algorithms can use the GPU for hardware acceleration, so GPU performance can help the system decide whether to enable hardware acceleration to improve encoding efficiency and reduce CPU load. Therefore, it is necessary to comprehensively analyze CPU performance, memory capacity, and GPU performance to select a suitable compression algorithm.

[0071] Optionally, the CPU running score can be determined by reading the CPU model. When the running score is higher than a preset score threshold, the CPU performance is considered to be good, otherwise the CPU performance is poor. Alternatively, the CPU model is matched with a pre-stored CPU model with good performance in advance. If the corresponding pre-stored CPU model is matched, the CPU performance is considered to be good, otherwise the CPU performance is poor. In addition, the frame rate and video memory capacity of the GPU can be detected. If the frame rate is higher than the frame rate threshold and the video memory capacity is higher than the video memory capacity threshold, the GPU performance is considered to be good, otherwise the GPU performance is considered to be poor.

[0072] In one implementation, when the network evaluation result is good, the target compression algorithm may be determined by at least one of the following methods:

[0073] 1. When the network evaluation results are good and the CPU performance is good, if the memory capacity is greater than or equal to the capacity threshold, it means that the terminal can use a compression algorithm with high compression efficiency while ensuring transmission quality and speed. Therefore, the H.265 compression algorithm is used as the target compression algorithm. If the memory capacity is less than the capacity threshold, it means that the current comprehensive performance of the terminal is insufficient. At this time, the VP9 compression algorithm is used as the target compression algorithm, which occupies less memory than the H.265 compression algorithm and can obtain better quality video than the H.264 compression algorithm.

[0074] 2. When the network evaluation result is characterized well and the CPU performance is characterized poorly, if the memory capacity is greater than or equal to the capacity threshold and the GPU performance is characterized well, the H.265 compression algorithm can use the GPU for hardware acceleration based on the GPU performance, so the H.265 compression algorithm is selected as the target compression algorithm; if the memory capacity is less than the capacity threshold, the H.264 compression algorithm that occupies the smallest memory capacity is used as the target compression algorithm; or, if the memory capacity is greater than or equal to the capacity threshold and the GPU performance is characterized poorly, the GPU performance cannot be used for hardware acceleration. At this time, the H.264 compression algorithm is used as the target compression algorithm to prioritize the transmission speed, reduce latency, and ensure the real-time nature of data transmission.

[0075] In one implementation, after determining the target compression algorithm, the terminal uses the target compression algorithm to compress the audio and video data to obtain compressed data.

[0076] In one implementation, step S400 includes steps S410-S450:

[0077] S410: Perform low-latency encoding on the compressed data, and segment and package the low-latency encoding result to obtain the encoding processing result.

[0078] In one embodiment, the terminal can perform low-latency encoding on the compressed data through a low-latency encoder to minimize the delay of the video data during the encoding, transmission and decoding process to ensure the real-time performance of the video stream; then, the low-latency encoding result is segmented and packaged to obtain the encoding processing result.

[0079] S420: Send the encoding processing result to the screen projection device, decode and restore the encoding processing result to obtain audio and video data.

[0080] Optionally, the terminal sends the encoding processing result to the screen projection device through the connected network, and the screen projection device decodes and restores the encoding processing result to obtain audio and video data.

[0081] S430: Perform time stamp synchronization on the video data and the corresponding audio data in the audio and video data.

[0082] Optionally, the processor of the screen projection device performs timestamp synchronization on the video data and the corresponding audio data in the audio and video data so that the audio data is synchronously corresponding to the video data.

[0083] S440: When the video data includes multiple video streams, the split-screen function is triggered to display the video data corresponding to each video stream in the corresponding split-screen area, and play the audio data corresponding to the video data.

[0084] Optionally, if the video data contains one video stream, the video stream is directly displayed on the screen of the projection device, and the audio data corresponding to the video data is played. If the video data contains multiple video streams, the projection device automatically triggers the split-screen function, displays the video data corresponding to each video stream in the corresponding split-screen area, and plays the audio data corresponding to the video data.

[0085] S450. In response to an operation instruction on the user interface of the screen projection device, control the playback and pause of the video data in any split-screen area and the volume of the corresponding audio data.

[0086] Optionally, a user interface can be displayed on the screen, and the user can operate in the user interface to generate operation instructions, which can control the playback and pause of video data in any split-screen area and the adjustment of the volume and sound effects of the corresponding audio data, thereby meeting the different needs of users and being convenient, fast and personalized.

[0087] In one implementation, the screen projection method for efficient transmission in the embodiment of the present application may further include step S510 or S520:

[0088] S510, re-detecting network parameters and performance parameters at preset intervals or in real time, returning to the step of determining a target compression algorithm from a compression algorithm library according to the network parameters and performance parameters to dynamically adjust the target compression algorithm.

[0089] Optionally, due to the state of the network and the use of the terminal in different situations, the network parameters and performance parameters may change. In order to dynamically adapt to the situation and ensure the video quality and real-time transmission, the terminal can re-detect the network parameters and performance parameters at preset intervals or in real time, and return to the step of determining the target compression algorithm from the compression algorithm library based on the network parameters and performance parameters, that is, return to step S200, thereby dynamically adjusting the target compression algorithm.

[0090] S520, receiving feedback information from the screen projection device, and adjusting the current target compression algorithm according to the feedback information.

[0091] In one embodiment, based on the user's experience, the user can input feedback information on the projection device and send the feedback information to the terminal for the terminal to receive, so that the terminal adjusts the current target compression algorithm according to the feedback information.

[0092] For example, when the feedback information is that the transmission efficiency is low, the computational complexity and delay should be reduced as much as possible. Therefore, the H.264 compression algorithm is preferentially selected as the target compression algorithm. Or if the current target compression algorithm is the H.264 compression algorithm, the compression parameters are optimized, such as optimizing at least one of the bit rate and the key frame interval, and at least one of reducing the bit rate and increasing the key frame interval is adopted.

[0093] When the feedback information is low clarity, the H.265 compression algorithm or the VP9 compression algorithm is used as the target compression algorithm, or if the current target compression algorithm is the H.265 compression algorithm or the VP9 compression algorithm, the compression parameters are further optimized, such as increasing the bit rate and reducing the key frame interval.

[0094] By using the method of the embodiment of the present application, at least the following effects can be achieved:

[0095] 1) Based on the network parameters and terminal performance parameters, the target compression algorithm is adaptively determined to ensure effective compression of audio and video data, and to ensure transmission quality and real-time transmission;

[0096] 2) Re-detect network parameters and performance parameters at intervals or in real time, or continuously optimize the selection of target compression algorithm based on user feedback information to ensure compression effect, thereby ensuring transmission quality and real-time performance.

[0097] Reference Figure 2 , shows a structural block diagram of a screen projection device for efficient transmission according to an embodiment of the present application, and the device may include:

[0098] A connection module is used to search for a screen projection device through a terminal and establish a network connection with the screen projection device;

[0099] A determination module, used to obtain network parameters of the connected network and performance parameters of the terminal, and determine a target compression algorithm from a compression algorithm library according to the network parameters and the performance parameters;

[0100] A compression module, used to compress the audio and video data through a target compression algorithm to obtain compressed data;

[0101] The sending module is used to encode the compressed data and send the encoding results to the projection device for display.

[0102] In one embodiment, the compression module is further configured to:

[0103] Re-detecting network parameters and performance parameters at preset intervals or in real time, and returning a step of determining a target compression algorithm from a compression algorithm library according to the network parameters and the performance parameters to dynamically adjust the target compression algorithm;

[0104] or,

[0105] Receive feedback from the projection device and adjust the current target compression algorithm based on the feedback.

[0106] The functions of each module in each device in the embodiments of the present application can be found in the corresponding description in the above method, and will not be repeated here.

[0107] Reference Figure 3 , shows a structural block diagram of an electronic device according to an embodiment of the present application, the electronic device includes: a memory 310 and a processor 320, the memory 310 stores instructions that can be run on the processor 320, and the processor 320 loads and executes the instructions to implement the screen projection method for efficient transmission in the above embodiment. The number of the memory 310 and the processor 320 can be one or more.

[0108] In one embodiment, the electronic device also includes a communication interface 330 for communicating with external devices and performing data exchange transmission. If the memory 310, the processor 320 and the communication interface 330 are implemented independently, the memory 310, the processor 320 and the communication interface 330 can be interconnected through a bus and complete mutual communication. The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 3 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.

[0109] Optionally, in a specific implementation, if the memory 310, the processor 320 and the communication interface 330 are integrated on a chip, the memory 310, the processor 320 and the communication interface 330 can communicate with each other through an internal interface.

[0110] An embodiment of the present application provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the screen projection method for efficient transmission provided in the above embodiment.

[0111] An embodiment of the present application also provides a chip, which includes a processor for calling and executing instructions stored in the memory from the memory, so that a communication device equipped with the chip executes the method provided by the embodiment of the present application.

[0112] An embodiment of the present application also provides a chip, including: an input interface, an output interface, a processor and a memory, wherein the input interface, the output interface, the processor and the memory are connected via an internal connection path, and the processor is used to execute the code in the memory. When the code is executed, the processor is used to execute the method provided in the embodiment of the application.

[0113] It should be understood that the processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor, etc. It is worth noting that the processor may be a processor supporting the advanced RISC machines (ARM) architecture.

[0114] Further, optionally, the above-mentioned memory may include a read-only memory and a random access memory, and may also include a non-volatile random access memory. The memory may be a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memories. Among them, the non-volatile memory may include a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may include a random access memory (RAM), which is used as an external cache. By way of example but not limitation, many forms of RAM are available. For example, static RAM (SRAM), dynamic random access memory (DRAM), synchronous DRAM (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM) and direct rambus RAM (DR RAM).

[0115] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function according to the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium.

[0116] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example" or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. Moreover, the described specific features, structures, materials or characteristics may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine different embodiments or examples described in this specification and the features of different embodiments or examples, unless they are contradictory.

[0117] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of this application, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.

[0118] Any process or method description in the flow chart or otherwise described herein can be understood to represent a module, fragment or portion of a code including one or more executable instructions for implementing the steps of a specific logical function or process. And the scope of the preferred embodiment of the present application includes other implementations, in which the functions may not be performed in the order shown or discussed, including in a substantially simultaneous manner or in a reverse order according to the functions involved.

[0119] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, which can be embodied in any computer-readable medium for use by an instruction execution system, apparatus or device (such as a computer-based system, a system including a processor or other system that can fetch instructions from an instruction execution system, apparatus or device and execute instructions), or used in combination with these instruction execution systems, apparatuses or devices.

[0120] It should be understood that the various parts of the present application can be implemented with hardware, software, firmware or a combination thereof. In the above embodiments, multiple steps or methods can be implemented with software or firmware stored in a memory and executed by a suitable instruction execution system. All or part of the steps of the above embodiment method can be completed by instructing the relevant hardware through a program, which can be stored in a computer-readable storage medium, and when the program is executed, it includes one of the steps of the method embodiment or a combination thereof.

[0121] In addition, each functional unit in each embodiment of the present application can be integrated into a processing module, or each unit can exist physically separately, or two or more units can be integrated into one module. The above-mentioned integrated module can be implemented in the form of hardware or in the form of a software functional module. If the above-mentioned integrated module is implemented in the form of a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. The storage medium can be a read-only memory, a disk or an optical disk, etc.

[0122] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of various changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A screen projection method with efficient transmission, characterized in that: include: Search for a screen projection device through the terminal and establish a network connection with the screen projection device; Acquire network parameters of the connected network and performance parameters of the terminal, and determine a target compression algorithm from a compression algorithm library according to the network parameters and the performance parameters; Compressing the audio and video data using the target compression algorithm to obtain compressed data; The compressed data is encoded and the encoding result is sent to the screen projection device for display.

2. The screen projection method with efficient transmission according to claim 1, characterized in that: The network parameter includes at least one of bandwidth, delay and packet loss rate, and the performance parameter includes CPU performance, memory capacity and GPU performance; and determining the target compression algorithm from the compression algorithm library according to the network parameter and the performance parameter includes: Obtaining a network evaluation result according to at least one of bandwidth, delay, and packet loss rate; A target compression algorithm is determined from a compression algorithm library according to CPU performance, memory capacity, GPU performance, and the network evaluation result.

3. The screen projection method for efficient transmission according to claim 2, characterized in that: Determining the target compression algorithm from the compression algorithm library according to the CPU performance, memory capacity, GPU performance and the network evaluation result includes: When the network evaluation result indicates poor performance, determining an H.264 compression algorithm from a compression algorithm library as a target compression algorithm; When the network evaluation result is characterized well, one of the H.264 compression algorithm, the H.265 compression algorithm and the VP9 compression algorithm is determined as the target compression algorithm from the compression algorithm library according to the CPU performance, the memory capacity and the GPU performance.

4. The screen projection method for efficient transmission according to claim 3, characterized in that: When the network evaluation result is characterized as good, determining one of the H.264 compression algorithm, the H.265 compression algorithm, and the VP9 compression algorithm as the target compression algorithm from the compression algorithm library according to the CPU performance, the memory capacity, and the GPU performance includes: When the network evaluation result is characterized as good and the CPU performance is characterized as good, if the memory capacity is greater than or equal to the capacity threshold, the H.265 compression algorithm is used as the target compression algorithm; if the memory capacity is less than the capacity threshold, the VP9 compression algorithm is used as the target compression algorithm; When the network evaluation result is characterized as good and the CPU performance is characterized as poor, if the memory capacity is greater than or equal to the capacity threshold and the GPU performance is characterized as good, the H.265 compression algorithm is used as the target compression algorithm; if the memory capacity is less than the capacity threshold, the H.264 compression algorithm is used as the target compression algorithm; if the memory capacity is greater than or equal to the capacity threshold and the GPU performance is characterized as poor, the H.264 compression algorithm is used as the target compression algorithm.

5. The screen projection method for efficient transmission according to any one of claims 1 to 4, characterized in that: The method further comprises: Re-detecting the network parameters and the performance parameters at preset intervals or in real time, and returning to the step of determining a target compression algorithm from a compression algorithm library according to the network parameters and the performance parameters to dynamically adjust the target compression algorithm; or, Receive feedback information from the screen projection device, and adjust the current target compression algorithm according to the feedback information.

6. The screen projection method with efficient transmission according to claim 5, characterized in that: The adjusting the current target compression algorithm according to the feedback information includes: When the feedback information indicates that the transmission efficiency is low, the H.264 compression algorithm is used as the target compression algorithm, or if the current target compression algorithm is the H.264 compression algorithm, the compression parameters are optimized; When the feedback information indicates that the definition is low, the H.265 compression algorithm or the VP9 compression algorithm is used as the target compression algorithm, or if the current target compression algorithm is the H.265 compression algorithm or the VP9 compression algorithm, the compression parameters are optimized; The compression parameter includes at least one of a bit rate and a key frame interval.

7. The screen projection method for efficient transmission according to any one of claims 1 to 4, characterized in that: The encoding process of the compressed data and sending the encoding process result to the screen projection device for display includes: Perform low-latency encoding on the compressed data, and segment and package the low-latency encoding result to obtain the encoding processing result; Sending the encoding processing result to the screen projection device, decoding and restoring the encoding processing result to obtain audio and video data; Performing time stamp synchronization on the video data and the corresponding audio data in the audio and video data; When the video data includes multiple video streams, the split-screen function is triggered to display the video data corresponding to each video stream in the corresponding split-screen area, and play the audio data corresponding to the video data; In response to the operation instructions of the user interface of the screen projection device, the playback, pause and volume of the corresponding audio data of any split-screen area are controlled.

8. A screen projection device with high efficiency transmission, characterized in that: include: A connection module, used to search for a screen projection device through a terminal and establish a network connection with the screen projection device; A determination module, used to obtain network parameters of the connected network and performance parameters of the terminal, and determine a target compression algorithm from a compression algorithm library according to the network parameters and the performance parameters; A compression module, used to compress the audio and video data using the target compression algorithm to obtain compressed data; The sending module is used to encode the compressed data and send the encoding result to the screen projection device for display.

9. An electronic device, characterized in that: include: A processor and a memory, wherein the memory stores instructions, and the instructions are loaded and executed by the processor to implement the method according to any one of claims 1 to 7.

10. A computer-readable storage medium, wherein a computer program is stored in the computer-readable storage medium, and when the computer program is executed, the method according to any one of claims 1 to 7 is implemented.

Citation Information

Cited By

  • Multimedia file transmission optimization method and system

    CN120768892A