Video and audio stream adjustment method, video and audio transmission system, equipment and medium

By adjusting the transmission parameters of the audio and video stream in the existing audio and video streaming system using INFO requests, the problem of transmission interruption is solved, and the stability and user experience are improved.

CN119854276APending Publication Date: 2025-04-18CHINA UNITED NETWORK COMM GRP CO LTD +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311337748.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-10-16
Publication Date
2025-04-18

AI Technical Summary

Technical Problem

The existing audio and video stream adjustment scheme will cause the transmission of the audio and video stream to be interrupted during the adjustment process, affecting stability and user experience.

Method used

Based on the original session connection, the session server sends an INFO request carrying transmission parameters to the monitoring device, and adjusts the transmission parameters of the audio and video stream, including code rate and resolution, without interrupting the session connection.

Benefits of technology

The audio and video stream adjustment is achieved without affecting transmission stability, reducing the possibility of data loss and improving the user's viewing experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119854276A_ABST
    Figure CN119854276A_ABST
Patent Text Reader

Abstract

The invention provides a video and audio stream adjustment method, a video and audio transmission system, equipment and a medium. The method comprises the following steps that: a streaming media server, a session server and monitoring equipment establish session connection based on a GB / T-28181 standard and an SIP (Session Initiation Protocol), and transmit video and audio streaming data through the session connection; if the transmission parameters need to be adjusted, the session server initiates an INFO request carrying the transmission parameters needing to be adjusted under the session connection, and the monitoring equipment transmits video and audio stream data to the streaming media server through the original session connection according to the received INFO request and the adjusted transmission parameters. According to the method, on the basis of the original session connection, the transmission parameters of the video and audio streams are adjusted by sending the INFO request carrying the transmission parameters to the monitoring equipment, and the adjustment of the video and audio streams can be realized without cutting off the original session connection, so that the influence on the transmission stability of the video and audio streams is avoided, and the possibility of data loss is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of communications, and in particular to a method for adjusting video and audio streams, a video and audio transmission system, a device and a medium. Background Art

[0002] With the continuous development of network multimedia communication technology, the audio and video monitoring system technology based on the GB / T-28181 national standard is becoming more and more mature. In actual situations, after requesting the required audio and video stream, the terminal may need to adjust the parameters of the audio and video stream.

[0003] The current audio and video stream adjustment scheme is that the video surveillance system closes the current transmission session of the audio and video stream, re-establishes a new session, and requests the audio and video stream in the new session according to the parameters that need to be adjusted to achieve parameter adjustment of the audio and video stream. However, the above adjustment scheme will generate an interruption time interval during the entire transmission process of the audio and video stream, affecting the transmission stability of the audio and video stream and reducing the user's viewing experience. Summary of the invention

[0004] The present application provides a method for adjusting an audio and video stream, an audio and video transmission system, a device and a medium, so as to prevent the parameter adjustment of the audio and video stream from affecting the transmission stability of the audio stream.

[0005] On the one hand, the present application provides an audio and video stream adjustment method, which is applied to an audio and video transmission system, wherein the audio and video transmission system includes a streaming media server, a session server and a monitoring device; the method includes: the streaming media server establishes a session connection with the monitoring device based on the GB / T-28181 standard by negotiating and interacting with the session server based on the SIP session protocol; and the monitoring device sends the audio and video stream data to the streaming media server according to the first transmission parameter through the established session connection; if the transmission parameter needs to be adjusted, the session server sends an INFO request in the session connection to the monitoring device, the INFO request carries a unique identifier of the session connection and a second transmission parameter; the monitoring device sends the audio and video stream data to the streaming media server through the session connection according to the second transmission parameter based on the INFO request; wherein the second transmission parameter includes at least one of the following: the bit rate and resolution of the audio and video stream data.

[0006] In one possible implementation, the monitoring device sends audio and video stream data to the streaming media server through a session connection according to the second transmission parameters based on the INFO request, including: the monitoring device detects whether the unique identifier of the session connection carried by the INFO request is valid based on the INFO request; and the monitoring device detects whether it supports the second transmission parameters; if the unique identifier of the session connection is valid and the monitoring device supports the second transmission parameters, the monitoring device sends the audio and video stream data to the streaming media server through the session connection according to the second transmission parameters.

[0007] In a possible implementation, the audio and video transmission system also includes a video monitoring system; the method also includes: the video monitoring system periodically obtains the current network status based on the NADA algorithm; if the video monitoring system detects that the network status switches from a non-high load state to a high load state, a data quality reduction instruction is sent to the session server; and if the video monitoring system detects that the network status switches from a high load state to a non-high load state, a data quality improvement instruction is sent to the session server; if the transmission parameters need to be adjusted, the session server sends an INFO request within the session connection to the monitoring device, including: if a data quality reduction instruction is received, the session server sends an INFO request within the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is lower than the bit rate and / or resolution in the first transmission parameter; if a data quality improvement instruction is received, the session server sends an INFO request within the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is higher than the bit rate and / or resolution in the first transmission parameter.

[0008] In a possible implementation, the video and audio transmission system also includes a client; the method also includes: the client sends the number of playback windows to the video surveillance system; if the number of playback windows is less than a preset first threshold, the video surveillance system does not perform adjustment processing; if the number of playback windows is not less than the preset first threshold and not greater than a preset second threshold, the video surveillance system sends a first indication instruction to the session server, and the second threshold is greater than the first threshold; if the number of playback windows is greater than the second threshold, the video surveillance system sends a second indication instruction to the session server; if the transmission parameter needs to be adjusted, the session server sends an INFO request in the session connection to the monitoring device, including: if the first indication instruction is received, the session server sends the INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is lower than the bit rate and / or resolution in the first transmission parameter, and the bit rate and / or resolution in the second transmission parameter is not higher than the preset parameter value; if the second indication instruction is received, the session server sends the INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is a preset target parameter value, and the target parameter value is lower than the preset parameter value.

[0009] In a possible implementation, multiple session connections are established between the streaming media server and the monitoring device, and the multiple session connections are processed in parallel.

[0010] In a possible implementation, the multiple session connections include a preview session connection and a storage session connection. The video and audio stream data transmitted by the preview session connection is used for real-time preview, and the video and audio stream data transmitted by the storage session connection is used for storage.

[0011] On the other hand, the present application provides an audio and video transmission system, including: a streaming media server, a session server and a monitoring device; wherein the streaming media server is used to establish a session connection with the monitoring device based on the GB / T-28181 standard by negotiating and interacting with the session server based on the SIP session protocol; the monitoring device is used to send audio and video stream data to the streaming media server according to the first transmission parameter through the established session connection; if the transmission parameters need to be adjusted, the session server sends an INFO request within the session connection to the monitoring device, the INFO request carries a unique identifier of the session connection and a second transmission parameter; the monitoring device is also used to send audio and video stream data to the streaming media server according to the second transmission parameter through the session connection according to the INFO request; wherein the transmission parameters include at least one of the following: bit rate and resolution of the audio and video stream data.

[0012] In one possible implementation, the monitoring device is specifically used to: detect, based on the INFO request, whether the unique identifier of the session connection carried in the INFO request is valid; and, detect whether the monitoring device itself supports the second transmission parameter; if the unique identifier of the session connection is valid and the monitoring device supports the second transmission parameter, the monitoring device sends audio and video stream data to the streaming media server through the session connection in accordance with the second transmission parameter.

[0013] On the other hand, the present application provides an electronic device, comprising: a processor, and a memory communicatively connected to the processor; the memory stores computer-executable instructions; the processor executes the computer-executable instructions stored in the memory to implement the above method.

[0014] On the other hand, the present application provides a computer-readable storage medium, in which computer-executable instructions are stored. When the computer-executable instructions are executed by a processor, they are used to implement the above method.

[0015] In the audio and video stream adjustment method, audio and video transmission system, device and medium provided by the present application, the streaming media server, session server and monitoring device establish a session connection based on the GB / T-28181 standard and the SIP protocol, and transmit audio and video stream data through the session connection; if the transmission parameters need to be adjusted, the session server initiates an INFO request carrying the transmission parameters to be adjusted under the session connection, and the monitoring device transmits the audio and video stream data to the streaming media server through the original session connection according to the adjusted transmission parameters based on the received INFO request. The scheme of the present application, based on the original session connection, adjusts the transmission parameters of the audio and video stream by sending an INFO request carrying the transmission parameters to the monitoring device, and the audio and video stream can be adjusted without cutting off the original session connection, thereby avoiding affecting the stability of the audio and video stream transmission and reducing the possibility of data loss. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0017] Figure 1 The schematic diagram of the architecture of an audio and video monitoring system based on GB / T-28181 provided by the present application is shown as an example;

[0018] Figure 2 The flowchart of the method for adjusting the video and audio streams provided in the first embodiment is exemplarily shown in FIG.

[0019] Figure 3 An interactive diagram of the video and audio stream adjustment method provided in the first embodiment is exemplarily shown in FIG.

[0020] Figure 4 A schematic diagram of a flow chart of another video and audio stream adjustment method provided in the first embodiment is exemplarily shown;

[0021] Figure 5 A flowchart of another method for adjusting video and audio streams provided in the first embodiment is exemplarily shown in FIG.

[0022] Figure 6 exemplarily shows an interaction diagram of another video and audio stream adjustment method provided by the first embodiment;

[0023] Figure 7 A flowchart of another method for adjusting video and audio streams provided in the first embodiment is exemplarily shown in FIG.

[0024] Figure 8 An interactive diagram of another video and audio stream adjustment method provided by the first embodiment is exemplarily shown in FIG.

[0025] Fig. 9 An interactive diagram of another video and audio stream adjustment method provided by the first embodiment is exemplarily shown in FIG.

[0026] Fig.10 The structural diagram of the video and audio transmission system provided by the second embodiment is exemplarily shown in FIG.

[0027] Fig.11 A schematic diagram of the structure of the electronic device provided in the third embodiment is shown as an example.

[0028] The above drawings have shown clear embodiments of the present application, which will be described in more detail later. These drawings and text descriptions are not intended to limit the scope of the present application in any way, but to illustrate the concept of the present application to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION

[0029] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are merely examples of devices and methods consistent with some aspects of the present application as detailed in the appended claims.

[0030] The terms "including" and "having" in this application are used to express an open-ended inclusion, and mean that in addition to the listed elements / components / etc., there may be additional elements / components / etc.; the terms "first" and "second" etc. are only used as marks or distinctions, and are not intended to limit the order or quantity of their objects. In addition, the different elements and areas in the drawings are only shown schematically, and are therefore not limited to the sizes or distances shown in the drawings. The technical solution is described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0031] First, the terms involved in this application are explained:

[0032] GB / T-28181 standard: refers to the national standard GB / T-28181-2022 "Technical Requirements for Information Transmission, Exchange and Control of Public Security Video Surveillance Networking Systems". This standard specifies the interconnection structure of public security audio and video surveillance networking systems, basic requirements and security requirements for transmission, exchange and control, as well as technical requirements such as control and transmission processes and protocol interfaces. It is a national standard in the field of audio and video surveillance.

[0033] SIP Session Protocol: Session initialization Protocol (SIP) is a text-based application layer control protocol used to create, modify and release sessions of one or more participants.

[0034] INFO request: refers to an extended method based on the SIP session protocol. The signaling channel of this request is the signaling channel established after the call is established, which is used to transport the control information related to the session generated in the session.

[0035] SDP: Session Description Protocol (SDP for short).

[0036] SSRC: Synchronization source (SSRC for short).

[0037] UDP: User Datagram Protocol (UDP for short).

[0038] TCP: Transmission Control Protocol (TCP for short).

[0039] RTP: Real-time Transport Protocol (RTP for short).

[0040] NADA algorithm: Network Assisted Dynamic Adaptation (NADA algorithm)

[0041] With the continuous development of the Internet, a large number of domestic audio and video monitoring applications have been pouring in. Based on the needs of terminal standardization and platform interoperability, different audio and video monitoring application platforms are uniformly connected to monitoring equipment through interoperability protocols. At present, the audio and video monitoring system built based on the interoperability protocol of the GB / T-28181 standard is the mainstream, but the GB / T-28181 standard also has limitations. When the terminal requests an audio and video stream and wants to adjust the parameters of the current audio and video stream, it is necessary to first cut off the transmission session of the current audio and video stream, and then request a new transmission session to complete the parameter adjustment of the audio and video stream. This method of statically adjusting the audio and video stream parameters will produce an interruption time interval, affecting the transmission stability of the audio and video stream, and this method will also cause the terminal screen to freeze, reducing the user's viewing experience.

[0042] The technical content provided by this application is intended to solve the above-mentioned technical problems of related technologies. The video and audio stream adjustment method provided by this application can be applied to Figure 1 The following is a schematic diagram of the audio and video monitoring system architecture based on the GB / T-28181 standard. Figure 1 As shown, the system includes: a streaming media server, a session server and a monitoring device. The streaming media server is based on the GB / T-28181 standard, and establishes a session connection with the monitoring device by negotiating and interacting with the session server based on the SIP session protocol. The monitoring device sends video and audio stream data to the streaming media server through the established session connection.

[0043] In the audio and video stream adjustment method, audio and video transmission system, device and medium provided by the embodiments of the present application, the streaming media server, the session server and the monitoring device establish a session connection based on the GB / T-28181 standard and the SIP protocol, and transmit the audio and video stream data through the session connection; if the transmission parameters need to be adjusted, the session server initiates an INFO request carrying the transmission parameters to be adjusted under the session connection, and the monitoring device transmits the audio and video stream data to the streaming media server through the original session connection according to the adjusted transmission parameters based on the received INFO request. The scheme of the present application, based on the original session connection, adjusts the transmission parameters of the audio and video stream by sending an INFO request carrying the transmission parameters to the monitoring device, and the audio and video stream can be adjusted without cutting off the original session connection, thereby avoiding affecting the stability of the audio and video stream transmission and reducing the possibility of data loss.

[0044] The technical solutions of the present application and the technical solutions of the present application are described in detail with specific embodiments below. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. In the description of the present application, unless otherwise clearly specified and limited, each term should be understood in a broad sense in the art. The embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0045] Embodiment 1

[0046] Figure 2 A schematic diagram of a flow chart of a method for adjusting a video and audio stream is shown in FIG. 1 . The execution subject of this example may be a video and audio transmission system, such as Figure 2 As shown, the method includes:

[0047] Step 101: The streaming media server establishes a session connection with the monitoring device by negotiating and interacting with the session server based on the SIP session protocol based on the GB / T-28181 standard; and the monitoring device sends video and audio stream data to the streaming media server according to the first transmission parameter through the established session connection;

[0048] Step 102: If the transmission parameters need to be adjusted, the session server sends an INFO request in the session connection to the monitoring device, where the INFO request carries a unique identifier of the session connection and a second transmission parameter;

[0049] Step 103: The monitoring device sends the video and audio stream data to the streaming media server through the session connection according to the INFO request and the second transmission parameters; wherein the transmission parameters include at least one of the following: bit rate and resolution of the video and audio stream data.

[0050] In practical applications, the execution subject of this method can be an audio-visual transmission system, which includes a streaming media server, a session server and a monitoring device. In practical applications, the requesting end, such as a user terminal, can request the audio-visual stream data of the registered monitoring device from the session server through the network. Correspondingly, the streaming media server will establish a session connection with the monitoring device based on the GB / T-28181 standard by negotiating and interacting with the session server based on the SIP session protocol. After the session connection is established, the monitoring device sends the audio-visual stream data to the streaming media server through the session connection.

[0051] As an example, before the session connection is established, the streaming media server and the monitoring device need to register in the session server. Specifically, the streaming media server and the monitoring device need to send registration requests to the session server based on the SIP session protocol according to the GB / T-28181 standard. After receiving the registration requests from the streaming media server and the monitoring device, the session server returns a corresponding reply message to complete the registration process. Taking the registration process of the monitoring device as an example, the monitoring device sends a Register request to the session server, and the session server verifies the request. If the session server detects that the identity of the monitoring device is legitimate, it sends a response 200OK to the monitoring device to complete the registration.

[0052] After the streaming media server and the monitoring device are registered in the session server, when the requesting end requests the audio and video stream data of the registered monitoring device from the session server, the streaming media server, the session server and the monitoring device establish a session connection based on the GB / T-28181 standard and the SIP protocol, and transmit the audio and video stream data based on the session connection.

[0053] Specifically, the establishment of a session connection and the transmission of audio and video stream data based on the session connection include: the session server generates a unique identifier (Call-id) for identifying the session connection of this request, and sends an INVITE request carrying the unique identifier and a first transmission parameter to the monitoring device to start the session connection, wherein the first transmission parameter can be encapsulated in the SDP information of the INVITE request. Specifically, the SDP information is used for media negotiation between the sending entity and the receiving entity, including but not limited to: the receiving IP address and receiving port of the audio and video stream data, the SSRC identifier, the network connection method for sending the audio and video stream data, the format of the audio and video stream data, etc. As an example, the receiving port is a streaming media server, and the network connection method for sending the audio and video stream data includes but is not limited to UDP mode, TCP active mode, and TCP passive mode; the format of the audio and video stream data includes but is not limited to the bit rate and resolution of the audio and video stream data. After receiving the INVITE request carrying the first transmission parameter, the monitoring device sends a response 200OK to the session server, and the response also carries SDP information. The SDP information of the 200OK response may include but is not limited to: the sending IP address and sending port of the audio and video stream data, the network connection method for sending the audio and video stream data, the format of the audio and video stream data, etc. As an example, the sending port is a monitoring device. After receiving the 200OK response sent by the monitoring device, the session server sends an ACK request to the monitoring device, indicating that the streaming media server and the monitoring device have completed the negotiation of the data information of the audio and video streams. The monitoring device starts to send encapsulated audio and video stream data to the streaming media server based on the negotiated audio and video stream data format, that is, the first transmission parameter. In actual use, the audio and video stream data can be encapsulated by RTP, and the streaming media server can decode the audio and video stream data encapsulated by RTP through multimedia video processing tools after receiving it.

[0054] Based on this solution, as an example, during the aforementioned audio and video stream transmission process, if the transmission parameters need to be adjusted, the session server can send an INFO request within the session connection to the monitoring device, wherein the INFO request carries the unique identifier of the session connection and the second transmission parameter. The monitoring device sends the audio and video stream data to the streaming media server through the session connection according to the second transmission parameter based on the INFO request; wherein the second transmission parameter includes but is not limited to: the bit rate and resolution of the audio and video stream data. Specifically, the INFO request can carry application layer information through the SIP signaling channel, but will not change the state of the SIP session or the initial parameters of the session, so it is possible to achieve transmission parameter adjustment while avoiding affecting the stable communication of the session. As an example, during the aforementioned audio and video stream transmission process, if the transmission of the audio and video stream ends, the session server sends a BYE request within the session to the monitoring device, and the monitoring device replies with a 200OK response to the session server to end the session connection.

[0055] As an example, Figure 3 An interactive diagram of a method for adjusting video and audio streams is shown as an example. Figure 3 As shown, the audio and video transmission system includes a streaming media server 31, a session server 32 and a monitoring device 33.

[0056] Specifically, the streaming media server 31 is mainly used to receive video and audio streaming data, the session server 32 is mainly used to establish and maintain the session, and the monitoring device 33 is mainly used to send video and audio streaming data. Figure 3 As shown in the figure, the process of establishing a session, transmitting and adjusting the video and audio streams is as follows: the session server 32 sends an INVITE request carrying Call-id and SDP information to the monitoring device 33 to start the session connection and negotiate the media; after receiving the INVITE request, the monitoring device 33 sends a 200OK response carrying Call-id and SDP information to the session server 32; after receiving the 200OK response, the session server 32 sends an ACK request to the monitoring device 33 to complete the negotiation of the media; after receiving the ACK request, the monitoring device 33 sends a first ACK request to the streaming media server 31 The transmission parameters send RTP-encapsulated audio and video stream data; when the transmission parameters need to be adjusted, the session server 32 sends an INFO request carrying the Call-id and the second transmission parameters to the monitoring device 33; after receiving the INFO request, the monitoring device 33 sends a 200OK response to the session server 32, and sends the RTP-encapsulated audio and video stream data to the streaming media server 31 with the second transmission parameters; if the transmission of the audio and video stream data is completed, the session server 32 sends a BYE request to the monitoring device 33, and the monitoring device 33 replies with a 200OK response to the session server 32 to end the session connection.

[0057] Considering the reliability of the adjustment, after receiving the INFO request carrying the second transmission parameter, the monitoring device may first detect the feasibility of the adjustment. Figure 4 A schematic diagram of a method for adjusting video and audio streams is shown in FIG. Figure 4 As shown, based on any example, step 103 specifically includes:

[0058] Step 201: The monitoring device detects, according to the INFO request, whether the unique identifier of the session connection carried in the INFO request is valid; and the monitoring device detects whether it supports the second transmission parameter.

[0059] Step 202: If the unique identifier of the session connection is valid and the monitoring device supports the second transmission parameter, the monitoring device sends the video and audio stream data to the streaming media server through the session connection according to the second transmission parameter.

[0060] Among them, whether the unique identifier is valid represents whether the transmission of the corresponding audio and video stream is normal. In practical applications, the status of each unique identifier can be maintained in an identifier list. As an example, when the audio and video stream received by the streaming media server is disconnected, it will be synchronized to the session server through the session connection. The session server updates the status of the unique identifier corresponding to the disconnected audio and video stream to invalid in the identifier list it maintains. Alternatively, when the audio and video transmission sent by the monitoring device ends, the monitoring device will update the status of the unique identifier corresponding to the audio and video stream that has ended the transmission to invalid in the identifier list maintained locally. Among them, the respective identifier lists of the session server and the monitoring device can be synchronized through the session connection. Correspondingly, in this example, after the monitoring device receives the INFO request carrying the unique identifier and the second transmission parameter, it can query the current status of the unique identifier from the locally maintained identifier list.

[0061] In addition to determining the validity of the unique identifier, the monitoring device further detects whether it can support the second transmission parameter. As an example, the monitoring device detects whether it supports the second transmission parameter, which may specifically include:

[0062] Obtain the maximum resolution and / or maximum bit rate of the monitoring device;

[0063] If the maximum resolution of the monitoring device is not less than the resolution in the second transmission parameter or the maximum bit rate of the monitoring device is not less than the bit rate in the second transmission parameter, it is determined that the monitoring device supports the second transmission parameter;

[0064] If the maximum resolution of the monitoring device is smaller than the resolution in the second transmission parameters and the maximum bit rate of the monitoring device is smaller than the bit rate in the second transmission parameters, it is determined that the monitoring device does not support the second transmission parameters.

[0065] In practical applications, the maximum resolution and / or maximum bit rate of the monitoring device can be determined based on the hardware parameters and / or software parameters of the monitoring device, for example, it can be determined based on the maximum resolution of the camera of the monitoring device and the maximum transmission parameters of the communication component. It should be noted that in this example, if the bit rate or resolution supports at least one of them, parameter adjustment can be performed. For example, assuming that the second transmission parameter includes the bit rate and resolution to be adjusted, if the maximum resolution of the monitoring device is greater than the resolution in the second transmission parameter, but the maximum bit rate of the monitoring device is less than the bit rate in the second transmission parameter, the adjustment is also performed. As an example, the monitoring device subsequently transmits the audio and video stream data according to the resolution in the second transmission parameter. As for the bit rate, the corresponding adjustment strategy can be adopted as needed. For example, the original bit rate can be left unchanged, or the audio and video stream data can be transmitted according to the maximum bit rate of the monitoring device, that is, as close as possible to the requirements of the second transmission parameter.

[0066] In this example, after receiving the INFO request carrying the second transmission parameter, the monitoring device first detects whether the unique identifier carried by the INFO request is valid; and whether the monitoring device itself supports the second transmission parameter. When the unique identifier is valid and the monitoring device supports the second transmission parameter, the transmission parameter adjustment is performed, thereby ensuring that the transmission parameter adjustment is performed only when the audio and video streams to be adjusted are in normal transmission and the monitoring device meets the adjustment requirements, thereby further ensuring the reliability of the transmission parameter adjustment.

[0067] In actual application, the transmission parameter adjustment of the audio and video stream can be triggered by different situations. As an example, it can be initiated by the user. Specifically, the user terminal initiates an adjustment request to the session server, and the session server sends an INFO request within the session to the monitoring device based on the adjustment request initiated by the user terminal.

[0068] As another example, the transmission parameter adjustment of the video and audio stream can be triggered based on the network status. For example, the video and audio transmission system also includes a video monitoring system; Figure 5 A schematic diagram of a method for adjusting video and audio streams is shown in FIG. Figure 5 As shown, based on any example, the video and audio stream adjustment method also includes:

[0069] Step 301: The video surveillance system periodically obtains the current network status based on the NADA algorithm;

[0070] Step 302: If the video surveillance system detects that the network state switches from a non-high-load state to a high-load state, a data quality reduction instruction is sent to the session server; and if the video surveillance system detects that the network state switches from a high-load state to a non-high-load state, a data quality improvement instruction is sent to the session server;

[0071] Accordingly, step 102 may specifically include:

[0072] Step 303: If a data quality reduction instruction is received, the session server sends an INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is lower than the bit rate and / or resolution in the first transmission parameter;

[0073] Step 304: If a data quality improvement instruction is received, the session server sends an INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is higher than the bit rate and / or resolution in the first transmission parameter.

[0074] Among them, the network state includes a high load state, a low load state and a normal load state. The low load state and the normal load state are collectively referred to as a non-high load state. Specifically, the network state can be determined based on the NADA algorithm according to the parameter values ​​of the network parameters. For example, the network parameters include but are not limited to the throughput, network bandwidth and packet loss rate of the current network. As an example, the parameter values ​​of the network parameters are calculated based on the NADA algorithm. When the network throughput is not less than the network bandwidth, it means that the current network has reached saturation. If the packet loss rate increases at the same time, it can be determined that the current network state is a high load state.

[0075] In this example, the transmission parameters of the video and audio stream data can be dynamically adjusted based on the current network status. Specifically, the NADA algorithm is an algorithm based on delay estimation, which can quickly stabilize the rate in a dynamic link, converge quickly, and have high bandwidth utilization when the link is not affected by random packet loss. The video surveillance system periodically obtains the current network status based on the NADA algorithm. If the video surveillance system detects that the network status has deteriorated, for example, the network status switches from a non-high-load state to a high-load state, a data quality reduction instruction is sent to the session server; accordingly, the session server sends an INFO request carrying the second transmission parameter in the session connection to the monitoring device according to the data quality reduction instruction, so as to instruct the monitoring device to adjust to the transmission of the video and audio stream data according to a lower transmission parameter than the current transmission parameter, for example, the bit rate level can be reduced by one level, and the resolution level can be reduced by one level. Among them, different levels of bit rate and resolution can be pre-set, and the higher the level, the higher the bit rate and resolution. For example, lowering the bit rate level by one level may mean lowering the bit rate by half, such as from 2Mbps to 1Mbps; optionally, lowering the resolution by one level may mean lowering one level among the five specifications D1 to D5 divided according to the standard of digital TV system display format, such as from D3 to D2.

[0076] In another case, if the video surveillance system detects that the network status has improved, for example, the network status switches from a high-load status to a non-high-load status, a data quality improvement instruction is sent to the session server. Accordingly, the session server sends an INFO request carrying a second transmission parameter in the session connection to the monitoring device according to the data quality improvement instruction, so as to instruct the monitoring device to adjust to transmit the video and audio stream data according to a transmission parameter higher than the current transmission parameter, for example, the first bit rate level can be increased, and the first resolution level can be increased. Through the above example, the transmission parameters can be adjusted dynamically and timely based on the changes in the network status, thereby maximizing the use of network resources and improving the quality and stability of video and audio stream data transmission.

[0077] As an example, Figure 6 An interactive diagram of a method for adjusting video and audio streams is shown as an example. Figure 6As shown, the video and audio transmission system includes a streaming video monitoring system 51, a media server 31, a session server 32 and a monitoring device 33.

[0078] Specifically, after the monitoring device 33 sends the RTP-encapsulated video and audio stream data to the streaming server 31 with the first transmission parameter, the video monitoring system 51 continuously monitors the network status. If the network status improves, the video monitoring system 51 sends a data quality improvement instruction to the session server 32; after receiving the data quality improvement instruction, the session server 32 sends an INFO request with a second transmission parameter with a higher parameter in the session connection to the monitoring device 33; after receiving the INFO request, the monitoring device 33 sends a 200OK response to the session server 32, and sends the RTP-encapsulated video and audio stream data to the streaming server 31 with the second transmission parameter. When the video surveillance system 51 detects that the network status has deteriorated, it sends a data quality reduction instruction to the session server 32; after receiving the data quality reduction instruction, the session server 32 sends an INFO request carrying a second transmission parameter with a lower parameter in the session connection to the monitoring device 33; after receiving the INFO request, the monitoring device 33 sends a 200OK response to the session server 32, and sends RTP-encapsulated audio and video stream data to the streaming media server 31 with the second transmission parameter; if the transmission of the audio and video stream data is completed, the session server 32 sends a BYE request to the monitoring device 33, and the monitoring device 33 replies with a 200OK response to the session server 32 to end the session connection.

[0079] In this example, the video surveillance system determines the current network status based on the NADA algorithm. When the network status changes, the video surveillance system sends the corresponding quality adjustment instruction to the session server. The session server sends an INFO request carrying the corresponding second transmission parameter according to the quality adjustment instruction, and the monitoring device adjusts the transmission of the video and audio stream according to the second transmission parameter in the INFO request. This example takes into account the real-time network status. When the network status changes, the transmission parameters of the video and audio stream data are adjusted in time to reduce the packet loss rate and jamming of the video and audio stream data transmission when the network status is high-loaded, and improve the video and audio quality when the network status is low-loaded, thereby rationally utilizing network resources and improving the viewing experience.

[0080] In actual use, another triggering situation for adjusting the transmission parameters of the video and audio streams is the change in the number of windows in the user playback interface. Correspondingly, when the number of windows on the playback end changes, it means that the user's requirements for the video and audio content and details of the playback are also different.

[0081] As an example, the transmission parameter adjustment of the video and audio stream may be triggered based on the number of playback windows.For example, the video and audio transmission system further includes a client; Figure 7 A schematic diagram of a method for adjusting video and audio streams is shown in FIG. Figure 7 As shown, based on any example, the video and audio stream adjustment method also includes:

[0082] Step 401: The client sends the number of playback windows to the video surveillance system;

[0083] Step 402: If the number of play windows is less than a preset first threshold, the video surveillance system does not perform adjustment processing; if the number of play windows is not less than the preset first threshold and not greater than a preset second threshold, the video surveillance system sends a first instruction to the session server, and the second threshold is greater than the first threshold; if the number of play windows is greater than the second threshold, the video surveillance system sends a second instruction to the session server;

[0084] Accordingly, step 102 may specifically include:

[0085] Step 403: If the first indication instruction is received, the session server sends an INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is lower than the bit rate and / or resolution in the first transmission parameter, and the bit rate and / or resolution in the second transmission parameter is not higher than a preset parameter value;

[0086] Step 404: If the second instruction is received, the session server sends an INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is a preset target parameter value, and the target parameter value is lower than the preset parameter value.

[0087] The client can be a user terminal with display function, and the number of playback windows can be controlled by user clicks or by client software. Specifically, limited by the size of the viewing screen, when the user watches through multiple windows, it is considered that the user has low requirements for the details of each window, and the data quality can be reduced; when the user reduces the number of preview windows, it is considered that the customer has high requirements for the details of each window, and the data quality needs to be improved.

[0088] In this example, the video monitoring system compares the number of playback windows of the client with the first threshold and the second threshold. If the number of playback windows changes within a range less than the first threshold, no adjustment is required. If the number of playback windows increases within a range less than the first threshold to a range not less than the preset first threshold and not greater than the preset second threshold, a first indication instruction is sent to the session server. Accordingly, the session server sends an INFO request carrying the second transmission parameter in the session connection to the monitoring device according to the first indication instruction to instruct the monitoring device to adjust to a transmission parameter lower than the current transmission parameter for the transmission of the video and audio stream data. The data quality of the second transmission parameter is less than the data quality of the first transmission parameter and is not higher than the preset parameter value. For example, the first threshold is preset to 4, the second threshold is preset to 9, and the preset parameter values ​​are 2Mbps bit rate and 720p resolution; when the number of playback windows changes arbitrarily from 1 to 3, there is no need to adjust the data quality; when the number of playback windows changes from 1 to 3 to 4 to 9, the bit rate of the video stream data is reduced from 3Mbps to 1Mbps, and the resolution is reduced from 1080p to 480p, and the adjusted bit rate and resolution are both less than the preset parameter values. In practical applications, the extent of the decrease in the data quality of the second transmission parameter can also be adjusted according to the magnitude of the increase in the number of windows.

[0089] Another scenario is that if the number of playback windows received by the video surveillance system changes from no more than two thresholds to greater than the second threshold, a second indication instruction is sent to the session server. Correspondingly, the session server sends an INFO request carrying the second transmission parameter in the session connection to the monitoring device according to the second indication instruction to instruct the monitoring device to adjust to a preset target parameter value, that is, a fixed audio and video stream data quality. Among them, the preset target parameter value is less than the preset parameter value when the number of playback windows is not less than the preset first threshold and not greater than the preset second threshold. For example, the preset second threshold is 9, the preset parameter value is 2Mbps bit rate and 720p resolution, and the preset target parameter value is 512Kbps and D1 resolution; when the number of playback windows changes from no more than 9 to greater than 9, the quality of the video stream data is set to a fixed preset target parameter value and is less than the preset parameter value.

[0090] As an example, Figure 8 An interactive diagram of a method for adjusting video and audio streams is shown as an example. Figure 8 As shown, the video and audio transmission system includes a streaming client 71, a video monitoring system 51, a media server 31, a session server 32 and a monitoring device 33.

[0091] Specifically, after the monitoring device 33 sends the RTP-encapsulated audio and video stream data to the streaming media server 31 with the first transmission parameter, the client 71 continuously sends the number of playback windows to the video monitoring system 51. If the video monitoring system 51 determines that the number of playback windows changes within a range less than the first threshold, the video monitoring system 51 does not perform adjustment; if the video monitoring system 51 determines that the number of playback windows changes from a range less than the first threshold to a range not less than the first threshold and not greater than the second threshold, the video monitoring system 51 sends a first indication instruction to the session server 32; after receiving the first indication instruction, the session server 32 sends an INFO request carrying the second transmission parameter in the session connection to the monitoring device 33; after receiving the INFO request, the monitoring device 33 sends a 200OK response to the session server 32, and sends the RTP-encapsulated audio and video stream data to the streaming media server 31 with the second transmission parameter. When the video monitoring system 51 determines that the number of playback windows changes from a range less than the second threshold to a range not less than the second threshold, a second indication instruction is sent to the session server 32; after receiving the second indication instruction, the session server 32 sends an INFO request carrying the second transmission parameter in the session connection to the monitoring device 33; after receiving the INFO request, the monitoring device 33 sends a 200OK response to the session server 32, and sends RTP-encapsulated audio and video stream data to the streaming media server 31 with the second transmission parameter; if the transmission of the audio and video stream data is completed, the session server 32 sends a BYE request to the monitoring device 33, and the monitoring device 33 replies with a 200OK response to the session server 32 to end the session connection.

[0092] In this example, the video monitoring system is based on the number of playback windows of the client. When the number of playback windows changes, the video monitoring system sends a corresponding instruction to the session server. The session server sends an INFO request carrying the corresponding second transmission parameter according to the instruction, and the monitoring device adjusts the transmission of the video and audio stream according to the second transmission parameter in the INFO request. This example takes into account the number of playback windows of the client. When the number of playback windows changes, the transmission parameters of the video and audio stream data are adjusted in time, and the quality of the video and audio stream data is flexibly adjusted according to the needs of the client, which reduces the quality and details of the video and audio stream data when the number of playback windows increases, saving network resources.

[0093] In actual applications, multiple session connections may be established in parallel. It should be noted that in this solution, the INFO request sent by the session server to the monitoring device carries a unique identifier, so it can uniquely determine which session connection the audio and video stream data that needs to be adjusted belongs to. Therefore, the transmission parameters can be adjusted independently under each session connection without affecting each other.

[0094] Based on any one of the examples, multiple session connections are established between the streaming media server and the monitoring device, and the multiple session connections are processed in parallel.

[0095] In this example, the session server generates a unique identifier representing each request based on different video and audio stream data requests. Different video and audio stream data requests can be requests to the same monitoring device or to different monitoring devices. The session server establishes multiple session connections based on the generated multiple unique identifiers so that the monitoring device can perform corresponding video and audio stream data transmission based on the session connection. Within the memory capacity of the session server, the parallel processing of multiple session connections can speed up the response efficiency of the video and audio data request and reduce the waiting time of the user.

[0096] In one example, the multiple session connections include a preview session connection and a storage session connection. The video and audio stream data transmitted by the preview session connection is used for real-time preview, and the video and audio stream data transmitted by the storage session connection is used for storage.

[0097] In actual applications, according to user needs, if the same audio and video stream needs to be stored when previewing the audio and video stream, the session server initiates two session connections to the same monitoring device based on the two audio and video stream requests, wherein the initiation of the session connection and the transmission of the audio and video stream data can refer to the method described in any of the above examples. If the audio and video stream data of the browsing session connection and the storage session connection changes due to changes in the network status or the number of user-side windows, the corresponding adjustments can also be made with reference to the method described in the above examples. Specifically, under preset circumstances or according to user needs, the first transmission parameters of the audio and video stream data for preview and the audio and video stream data for storage can be set separately. For example, the bit rate and resolution of the first transmission parameters of the audio and video stream data for preview can be higher than those of the audio and video stream data for storage, so as to meet the requirements of previewing high-quality audio and video while reducing the space occupied by storing audio and video stream data and making rational use of resources.

[0098] As an example, take the transmission parameter adjustment scenario of real-time preview and video storage as an example. Fig. 9 An interactive diagram of a method for adjusting video and audio streams is shown as an example. Fig. 9 As shown, the video and audio transmission system includes a streaming client 71, a video monitoring system 51, a media server 31, a session server 32 and a monitoring device 33.

[0099] Specifically, the client 71 sends a video and audio stream request for previewing and a video and audio stream request for storage to the session server 32 through the video monitoring system 51; after receiving the video and audio stream request for previewing and the video and audio stream request for storage, the session server 32 sends an INVITE request carrying a Call-id identifying the two requests and corresponding SDP information to the monitoring device 33, so as to negotiate the media data of the two session connections; after receiving the INVITE requests for the two session connections, the monitoring device 33 sends a 200OK response carrying a Call-id identifying the two requests and corresponding SDP information to the session server 32; after receiving the 200OK responses for the two session connections, the session server 32 sends an ACK request to the monitoring device 33, so as to complete the negotiation of the media in the two session connections; after receiving the AC of the two session connections, the monitoring device 33 After the K request, the video and audio stream data encapsulated in RTP are sent to the streaming media server 31 with the first transmission parameter; according to the user's needs, or the change of the network status, or the change of the number of windows on the user side in the preview session connection, when the video and audio data stream of the corresponding session connection is adjusted, the session server 32 sends the INFO request carrying the Call-id and the second transmission parameter to the monitoring device 33 through the triggered adjusted session connection; after receiving the INFO request, the monitoring device 33 sends a 200OK response to the session server 32, and sends the video and audio stream data encapsulated in RTP to the streaming media server 31 through the corresponding session connection with the second transmission parameter; if the transmission of the video and audio stream data ends, the session server 32 sends a BYE request to the monitoring device 33 through the corresponding session connection, and the monitoring device 33 replies a 200OK response to the session server 32 to end the corresponding session connection. This example can establish different types of transmission paths for video and audio stream data according to the user's needs, and adjust according to the network conditions or the change of the number of windows on the user side, so as to meet the needs of users under multi-session connections.

[0100] In the audio and video stream adjustment method provided in this embodiment, a session connection is first established through a streaming media server, a session server, and a monitoring device based on the GB / T-28181 standard and the SIP protocol, and audio and video stream data is transmitted through the session connection; based on the audio and video stream parameter adjustment requirements in different situations, the session server initiates an INFO request in the existing session connection, and the monitoring device adjusts the transmission parameters through the INFO request, and then transmits the audio and video stream data to the streaming media server; in the case of multiple requests, the establishment of the session connection and the corresponding audio and video stream data adjustment can also be processed in parallel. The solution of the present application, based on the original audio and video stream data transmission, uses the INFO request sent to the monitoring device in the session connection, and provides an adjustment strategy for the audio and video stream data transmission parameters based on the actual situation and user needs, so as to adjust the transmission parameters of the audio and video stream data while maintaining the existing audio and video stream data transmission, thereby reducing the possibility of data loss during the transmission of the audio and video stream data.

[0101] Embodiment 2

[0102] Fig.10 The structure diagram of the video and audio transmission system provided by the second embodiment of the present application is shown in FIG. Fig.10 As shown, the system includes: a streaming media server 31, a session server 32 and a monitoring device 33; wherein,

[0103] The streaming media server 31 is used to establish a session connection with the monitoring device by negotiating and interacting with the session server based on the SIP session protocol based on the GB / T-28181 standard;

[0104] The monitoring device 33 is used to send the video and audio stream data to the streaming media server according to the first transmission parameter through the established session connection;

[0105] The session server 32 is used for sending an INFO request in the session connection to the monitoring device if the transmission parameter needs to be adjusted, and the INFO request carries a unique identifier of the session connection and a second transmission parameter;

[0106] The monitoring device 33 is also used to send the video and audio stream data to the streaming media server through the session connection according to the INFO request and the second transmission parameters; wherein the transmission parameters include at least one of the following: the bit rate and resolution of the video and audio stream data.

[0107] In actual use, the requesting end, such as a user terminal, can request the video and audio stream data of the registered monitoring device from the session server through the network.

[0108] As an example, before the session connection is established, the streaming media server 31 and the monitoring device 33 need to be registered in the session server. Specifically, the streaming media server 31 and the monitoring device 33 need to send registration requests to the session server based on the SIP session protocol according to the GB / T-28181 standard. After receiving the registration requests of the streaming media server and the monitoring device, the session server returns a corresponding reply message to complete the registration process. After the streaming media server 31 and the monitoring device 33 are registered in the session server 32, when the requesting end requests the video and audio stream data of the registered monitoring device 33 from the session server 32, the streaming media server 31, the session server 32 and the monitoring device 33 establish a session connection based on the GB / T-28181 standard and the SIP protocol, and transmit the video and audio stream data based on the session connection.

[0109] Specifically, the first transmission parameter can be encapsulated in the SDP information of the INVITE request. The SDP information is used for media negotiation between the sending entity and the receiving entity, including but not limited to: the receiving IP address and receiving port of the audio and video stream data, the SSRC identifier, the network connection method for sending the audio and video stream data, the audio and video stream data format, etc. In actual use, the audio and video stream data can be encapsulated by RTP, and the streaming media server 31 can decode the audio and video stream data encapsulated by RTP through a multimedia video processing tool.

[0110] Based on any one of the examples, the monitoring device 33 is specifically used for:

[0111] The monitoring device detects, according to the INFO request, whether the unique identifier of the session connection carried in the INFO request is valid; and the monitoring device detects whether it supports the second transmission parameter;

[0112] If the unique identifier of the session connection is valid and the monitoring device supports the second transmission parameter, the monitoring device sends the video and audio stream data to the streaming media server through the session connection according to the second transmission parameter.

[0113] In conjunction with the above confirmation of the INFO request, in one example, the video and audio transmission system further includes a video monitoring system; the video monitoring system 51 is specifically used for:

[0114] The video surveillance system periodically obtains the current network status based on the NADA algorithm;

[0115] If the video surveillance system detects that the network state switches from a non-high-load state to a high-load state, a data quality reduction instruction is sent to the session server; and if the video surveillance system detects that the network state switches from a high-load state to a non-high-load state, a data quality improvement instruction is sent to the session server;

[0116] In conjunction with the above-mentioned video surveillance system, in one example, the session server 32 is specifically used for:

[0117] If a data quality reduction instruction is received, the session server sends an INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is lower than the bit rate and / or resolution in the first transmission parameter;

[0118] If a data quality improvement instruction is received, the session server sends an INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is higher than the bit rate and / or resolution in the first transmission parameter.

[0119] Specifically, the network status may be determined based on the NADA algorithm according to the parameter values ​​of the network parameters.

[0120] In combination with the above-mentioned session server, in one example, the video and audio transmission system further includes a client 71; the client 71 is specifically used for:

[0121] The client sends the number of playback windows to the video surveillance system;

[0122] In combination with the above-mentioned client, in one example, the video monitoring system 51 is specifically used for:

[0123] If the number of playback windows is less than a preset first threshold, the video surveillance system does not perform adjustment processing; if the number of playback windows is not less than the preset first threshold and not greater than a preset second threshold, the video surveillance system sends a first instruction to the session server, and the second threshold is greater than the first threshold; if the number of playback windows is greater than the second threshold, the video surveillance system sends a second instruction to the session server;

[0124] In conjunction with the above-mentioned video surveillance system, in one example, the session server 32 is specifically used for:

[0125] If the first indication instruction is received, the session server sends an INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is lower than the bit rate and / or resolution in the first transmission parameter, and the bit rate and / or resolution in the second transmission parameter is not higher than a preset parameter value;

[0126] If the second instruction is received, the session server sends an INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is a preset target parameter value, and the target parameter value is lower than the preset parameter value.

[0127] In practical applications, the extent of the decrease in the data quality of the second transmission parameter may also be adjusted according to the extent of the increase in the number of windows.

[0128] In combination with the above-mentioned session server, in one example, the streaming media server 31 is specifically used for:

[0129] Multiple session connections are established between the streaming media server and the monitoring device, and the multiple session connections are processed in parallel.

[0130] In combination with the above-mentioned streaming media server, in one example, the multiple session connections include a preview session connection and a storage session connection. The audio and video stream data transmitted by the preview session connection is used for real-time preview, and the audio and video stream data transmitted by the storage session connection is used for storage.

[0131] Embodiment 3

[0132] Fig.11 This is a schematic diagram of the structure of an electronic device provided in Embodiment 3 of the present application, and the electronic device includes:

[0133] The electronic device includes a processor 291 and a memory 292; it may also include a communication interface 293 and a bus 294. The processor 291, the memory 292, and the communication interface 293 may communicate with each other through the bus 294. The communication interface 293 may be used for information transmission. The processor 291 may call the logic instructions in the memory 292 to execute the above-mentioned example method.

[0134] In addition, the logic instructions in the above-mentioned memory 292 can be implemented in the form of software functional units and can be stored in a computer-readable storage medium when sold or used as an independent product.

[0135] The memory 292 is a computer-readable storage medium that can be used to store software programs and computer executable programs, such as program instructions / modules corresponding to the methods in the embodiments of the present application. The processor 291 executes functional applications and data processing by running the software programs, instructions, and modules stored in the memory 292, that is, implementing the methods in the above method examples.

[0136] The memory 292 may include a program storage area and a data storage area, wherein the program storage area may store an operating system and an application required for at least one function; the data storage area may store data created according to the use of the terminal device, etc. In addition, the memory 292 may include a high-speed random access memory and may also include a non-volatile memory.

[0137] An embodiment of the present application further provides a computer-readable storage medium, in which computer-executable instructions are stored. When the computer-executable instructions are executed by a processor, they are used to implement the method in any embodiment.

[0138] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the invention disclosed herein. The present application is intended to cover any modification, use or adaptation of the present application, which follows the general principles of the present application and includes common knowledge or customary techniques in the art that are not disclosed in the present application. The specification and examples are intended to be exemplary only, and the true scope and spirit of the present application are indicated by the following claims.

[0139] It should be understood that the present application is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.

Claims

1. A method for adjusting video and audio streams, characterized in that: Applied to an audio-visual transmission system, the audio-visual transmission system includes a streaming media server, a conversation server and a monitoring device; the method includes: The streaming media server establishes a session connection with the monitoring device by negotiating and interacting with the session server based on the SIP session protocol based on the GB / T-28181 standard; and the monitoring device sends the video and audio stream data to the streaming media server according to the first transmission parameter through the established session connection; If the transmission parameter needs to be adjusted, the session server sends an INFO request in the session connection to the monitoring device, where the INFO request carries a unique identifier of the session connection and a second transmission parameter; The monitoring device sends the audio and video stream data to the streaming media server according to the INFO request through the session connection and the second transmission parameter; wherein the second transmission parameter includes at least one of the following: bit rate and resolution of the audio and video stream data.

2. The method according to claim 1, characterized in that: The monitoring device sends the video and audio stream data to the streaming media server through the session connection according to the INFO request and the second transmission parameter, including: The monitoring device detects, according to the INFO request, whether the unique identifier of the session connection carried in the INFO request is valid; and the monitoring device detects whether it supports the second transmission parameter; If the unique identifier of the session connection is valid and the monitoring device supports the second transmission parameter, the monitoring device sends the video and audio stream data to the streaming media server through the session connection according to the second transmission parameter.

3. The method according to claim 1, characterized in that The video and audio transmission system also includes a video monitoring system; the method also includes: The video surveillance system periodically obtains the current network status based on the NADA algorithm; If the video surveillance system detects that the network state switches from a non-high-load state to a high-load state, a data quality reduction instruction is sent to the session server; and if the video surveillance system detects that the network state switches from a high-load state to a non-high-load state, a data quality improvement instruction is sent to the session server; If the transmission parameter needs to be adjusted, the session server sends an INFO request in the session connection to the monitoring device, including: If the data quality reduction instruction is received, the session server sends an INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is lower than the bit rate and / or resolution in the first transmission parameter; If the data quality improvement instruction is received, the session server sends an INFO request within the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is higher than the bit rate and / or resolution in the first transmission parameter.

4. The method according to claim 3, characterized in that The video and audio transmission system also includes a client; the method also includes: The client sends the number of playback windows to the video surveillance system; If the number of playback windows is less than a preset first threshold, the video surveillance system does not perform adjustment processing; if the number of playback windows is not less than the preset first threshold and not greater than a preset second threshold, the video surveillance system sends a first instruction to the session server, and the second threshold is greater than the first threshold; if the number of playback windows is greater than the second threshold, the video surveillance system sends a second instruction to the session server; If the transmission parameter needs to be adjusted, the session server sends an INFO request in the session connection to the monitoring device, including: If the first indication instruction is received, the session server sends an INFO request in the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is lower than the bit rate and / or resolution in the first transmission parameter, and the bit rate and / or resolution in the second transmission parameter is not higher than a preset parameter value; If the second indication instruction is received, the session server sends an INFO request within the session connection to the monitoring device; wherein the bit rate and / or resolution in the second transmission parameter is a preset target parameter value, and the target parameter value is lower than the preset parameter value.

5. The method according to any one of claims 1 to 4, characterized in that: A plurality of session connections are established between the streaming media server and the monitoring device, and the plurality of session connections are processed in parallel.

6. The method according to claim 5, characterized in that The multiple session connections include a preview session connection and a storage session connection. The video and audio stream data transmitted by the preview session connection is used for real-time preview, and the video and audio stream data transmitted by the storage session connection is used for storage.

7. A video and audio transmission system, characterized in that: include: Streaming media server, session server and monitoring equipment; among which, The streaming media server is used to establish a session connection with the monitoring device by negotiating and interacting with the session server based on the SIP session protocol based on the GB / T-28181 standard; The monitoring device is used to send video and audio stream data to the streaming media server according to the first transmission parameter through the established session connection; The session server is used for sending an INFO request in the session connection to the monitoring device if the transmission parameter needs to be adjusted, wherein the INFO request carries a unique identifier of the session connection and a second transmission parameter; The monitoring device is also used to send audio and video stream data to the streaming media server according to the INFO request through the session connection and the second transmission parameters; wherein the transmission parameters include at least one of the following: bit rate and resolution of the audio and video stream data.

8. The system according to claim 7, characterized in that The monitoring device is specifically used for: The monitoring device detects, according to the INFO request, whether the unique identifier of the session connection carried in the INFO request is valid; and the monitoring device detects whether it supports the second transmission parameter; If the unique identifier of the session connection is valid and the monitoring device supports the second transmission parameter, the monitoring device sends the video and audio stream data to the streaming media server through the session connection according to the second transmission parameter.

9. An electronic device, characterized in that: include: A processor, and a memory communicatively connected to the processor; The memory stores computer-executable instructions; the processor executes the computer-executable instructions stored in the memory to implement the method according to any one of claims 1 to 6.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, which are used to implement the method according to any one of claims 1 to 6 when executed by a processor.