CN112187705B - Audio playing method and equipment - Google Patents

Audio playing method and equipment Download PDF

Info

Publication number
CN112187705B
CN112187705B CN201910598427.9A CN201910598427A CN112187705B CN 112187705 B CN112187705 B CN 112187705B CN 201910598427 A CN201910598427 A CN 201910598427A CN 112187705 B CN112187705 B CN 112187705B
Authority
CN
China
Prior art keywords
data packet
audio data
audio
terminal
source identifier
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910598427.9A
Other languages
Chinese (zh)
Other versions
CN112187705A (en
Inventor
李敬来
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Chengdu TD Tech Ltd
Original Assignee
Chengdu TD Tech Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Chengdu TD Tech Ltd filed Critical Chengdu TD Tech Ltd
Priority to CN201910598427.9A priority Critical patent/CN112187705B/en
Publication of CN112187705A publication Critical patent/CN112187705A/en
Application granted granted Critical
Publication of CN112187705B publication Critical patent/CN112187705B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/60Network streaming of media packets
    • H04L65/75Media network packet handling
    • H04L65/765Media network packet handling intermediate
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/02Details
    • H04L12/16Arrangements for providing special services to substations
    • H04L12/18Arrangements for providing special services to substations for broadcast or conference, e.g. multicast
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/40Support for services or applications

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Telephonic Communication Services (AREA)

Abstract

The embodiment of the invention provides an audio playing method and equipment, wherein the method comprises the following steps: if the difference of the main terminals is detected, if the synchronous source identifier of the first audio data packet is continuously judged to be the same as the synchronous source identifier of the second audio data packet, an audio silence frame carrying the synchronous source identifier different from the synchronous source identifier of the first audio data packet and the synchronous source identifier of the second audio data packet is sent to the monitoring terminal, so that the monitoring terminal recognizes the synchronous information source identification carried by the second audio data packet after receiving the second audio data packet, unlike the synchronization source identification of the currently recorded audio silence frame, when the SSRC of the audio packet changes, the player of the audio silence frame is stopped, a new player is started, the second audio data is continued, when the synchronous information source identifier is not changed due to the change of the main speaking terminal, the problem that the front section of the audio sent by the new main speaking terminal can not be identified and played by the monitoring terminal.

Description

Audio playing method and equipment
Technical Field
The embodiment of the invention relates to the field of communication technology, in particular to an audio playing method and device.
Background
With the application of voice trunking service becoming more and more extensive, under the condition of trunking network, one terminal device talkbacks, and then other terminals in the group can simultaneously monitor the sound.
Currently, the existing audio playing method is as follows: the main speaking terminal sends an audio data packet to the data transfer server; and after receiving the audio data packet, the data transfer server sends the audio data packet to the monitoring terminal, and after receiving the audio data packet, the monitoring terminal starts an audio player to play. The monitoring terminal receives an audio data packet, records a Synchronous Source Recording Code (SSRC) of the current audio data packet, then puts the audio data packets with the same SSRC into a queue of an audio player according to a seq serial number, the player starts a decoder to decode and play according to the seq serial number in the queue, and when the SSRC of the received audio data packet changes (the SSRCs of different types of signal sources are different), the old player is stopped, a new player is started, and the playing continues.
However, the inventor finds that the following technical problems exist in the existing audio playing mode: when the main terminal changes, but the signal source of the main terminal does not change, that is, the SSRC of the audio data packet does not change, at this time, if the monitoring terminal receives the audio data packet of the new main terminal and the seq serial number of the data packet is partially consistent with the seq serial number of the previous main terminal data packet, the monitoring terminal will default that the audio data packet is the expired audio data packet, and then will discard the data packet, so that the previous section of sound of the new main terminal played by the monitoring terminal is inaudible, which affects the listening experience of the user.
Disclosure of Invention
The embodiment of the invention provides an audio playing method and audio playing equipment, which aim to solve the problem that when a talkback terminal changes and a synchronous information source identifier does not change, the front section of audio sent by a new talkback terminal cannot be identified and played by a monitoring terminal.
In a first aspect, an embodiment of the present invention provides an audio playing method, including:
receiving a first audio data packet and recording a synchronous information source identifier carried by the first audio data packet;
sending the first audio data packet to a monitoring terminal for playing;
receiving a second audio data packet and recording a synchronous information source identifier carried by the second audio data packet;
if the fact that a main speaking terminal sending the second audio data packet is different from a main speaking terminal of the first audio data packet is detected, whether a synchronous information source identifier of the first audio data packet is the same as a synchronous information source identifier of the second audio data packet is judged;
if the synchronous source identifier of the first audio data packet is the same as the synchronous source identifier of the second audio data packet, generating an audio silence frame, wherein the synchronous source identifier carried by the audio silence frame is different from the synchronous source identifier of the first audio data packet and the synchronous source identifier of the second audio data packet;
sending the audio silence frame to the monitoring terminal;
and after the audio silence frame is sent, sending the second audio data packet to the monitoring terminal for playing.
In a second aspect, an embodiment of the present invention provides an audio playing device, including:
the first receiving module is used for receiving a first audio data packet and recording a synchronous information source identifier carried by the first audio data packet;
the first sending module is used for sending the first audio data packet to a monitoring terminal for playing;
the second receiving module is used for receiving a second audio data packet and recording a synchronous information source identifier carried by the second audio data packet;
a detection judging module, configured to judge whether a synchronous source identifier of the first audio data packet is the same as a synchronous source identifier of the second audio data packet if it is detected that a talker terminal that sends the second audio data packet is different from a talker terminal that sends the first audio data packet;
an audio silence frame processing module, configured to generate an audio silence frame if the synchronization source identifier of the first audio data packet is the same as the synchronization source identifier of the second audio data packet, where a synchronization source identifier carried by the audio silence frame is different from the synchronization source identifier of the first audio data packet and the synchronization source identifier of the second audio data packet;
the second sending module is used for sending the audio silence frame to the monitoring terminal;
and the third sending module is used for sending the second audio data packet to the monitoring terminal for playing after the audio silence frame is sent.
In a third aspect, an embodiment of the present invention provides an audio playing device, including: at least one processor and memory;
the memory stores computer-executable instructions;
the at least one processor executing the computer-executable instructions stored by the memory causes the at least one processor to perform the audio playback method as described above in the first aspect and various possible designs of the first aspect.
In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, where computer-executable instructions are stored, and when a processor executes the computer-executable instructions, the audio playing method according to the first aspect and various possible designs of the first aspect is implemented.
According to the audio playing method and the audio playing device provided by the embodiment of the invention, whether the synchronous information source identifier of the first audio data packet is the same as the synchronous information source identifier of the second audio data packet is continuously judged by detecting that the main speaking terminal for sending the second audio data packet is different from the main speaking terminal for sending the first audio data packet; when the synchronous source identifier of the first audio data packet is the same as the synchronous source identifier of the second audio data packet, sending an audio silence frame carrying a synchronous source identifier different from the synchronous source identifier of the first audio data packet and the synchronous source identifier of the second audio data packet to the monitoring terminal, so that after the monitoring terminal receives the second audio data packet, identifying the synchronous source identifier carried by the second audio data packet, and when the SSRC of the audio data packet is changed, stopping the player of the audio silence frame, starting a new player, and continuing to perform the second audio data, so as to solve the problem that the source of the master terminal signal is not changed when the master terminal signal is changed in the prior art, that is, the SSRC of the audio data packet is not changed, if the monitoring terminal receives a new audio data packet of the master terminal, and the seq serial number of the data packet is partially consistent with the seq serial number of the previous data packet of the main speaking terminal, the monitoring terminal can default that the audio data packet is an expired audio data packet and then discard the audio data packet, so that the previous section of sound of the new main speaking terminal played by the monitoring terminal cannot be heard, and the listening experience of a user is influenced.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
Fig. 1 is a schematic diagram of a cluster audio playing architecture according to an embodiment of the present invention;
fig. 2 is a first flowchart illustrating an audio playing method according to an embodiment of the present invention;
fig. 3 is a schematic interaction flow diagram of an audio playing method according to an embodiment of the present invention;
FIG. 4 is a diagram illustrating an audio player queue according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of an audio playing device according to an embodiment of the present invention;
fig. 6 is a schematic diagram of a hardware structure of an audio playing device according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Fig. 1 is a schematic diagram of a cluster audio playing architecture according to an embodiment of the present invention. As shown in fig. 1, the system provided by the present embodiment includes a main call terminal 101, a data relay server 102, and a listening terminal 103. The talkback terminal 101 and the monitoring terminal 103 may be a child story machine, a mobile phone, a tablet, a vehicle-mounted terminal, or the like. In this embodiment, the main terminal 101 may also be a monitoring terminal, and the monitoring terminal 103 may also be a main terminal, and the implementation manners of the main terminal 101 and the monitoring terminal 103 are not particularly limited as long as the main terminal 101 and the monitoring terminal 103 can communicate with the data relay server.
The audio of the cluster is played, and the main speaking terminal sends an audio data packet to the data transfer server; and after receiving the audio data packet, the data transfer server sends the audio data packet to the monitoring terminal, and after receiving the audio data packet, the monitoring terminal starts an audio player to play.
The data relay server 102 may be one server or a cluster formed by a plurality of servers.
However, in some scenarios, when the main terminal changes, the SSRC of different signal sources also changes, but when the main terminal changes, but the signal source of the main terminal does not change, that is, the SSRC of the audio data packet does not change, at this time, if the listening terminal receives the audio data packet of a new main terminal and the seq serial number of the data packet is partially consistent with the seq serial number of the previous main terminal data packet, the listening terminal defaults that the audio data packet is an expired audio data packet, and then discards the audio data packet, so that the previous sound of the new main terminal played by the listening terminal cannot be heard, which affects the listening experience of the user. The present embodiment provides an audio playing method to solve the technical problem. The following examples are given for illustrative purposes.
Fig. 2 is a first flowchart illustrating an audio playing method according to an embodiment of the present invention, where an execution subject of this embodiment may be a data relay server in the embodiment shown in fig. 1. As shown in fig. 2, the method includes:
s201: receiving a first audio data packet, and recording a synchronous source identifier carried by the first audio data packet.
In this embodiment, the first audio data packet may be audio data in any format. The first audio data packet may be a speaker terminal of any of the terminal devices in the cluster of fig. 1.
Optionally, the first audio data packet is an audio data packet of a Real-time Transport Protocol, that is, an audio RTP (Real-time Transport Protocol) packet.
Wherein, a Synchronization Source Recording Code (SSRC) is used to identify the Source of the audio data packet. The source here may be a microphone, a camera, an RTP mixer, etc. Identified by a 32-bit digital SSRC identifier in the header of the audio RTP packet, and independent of the network address, the receiver can distinguish different sources according to the SSRC identifier to perform the grouping of the RTP message.
S202: and sending the first audio data packet to a monitoring terminal for playing.
Specifically, the information may be sent to the monitoring terminal through a wired network, or may be sent to the monitoring terminal through a wireless network.
The first audio data packet may carry a multicast identifier, and is used to instruct the sending of the monitoring terminal to other monitoring terminals.
In this embodiment, there may be a plurality of listening terminals. After each monitoring terminal receives an audio data packet, recording the SSRC of the current audio data packet, then placing the audio data packets with the same SSRC into a queue of an audio player according to the seq serial number, starting a decoder by the player, decoding and playing according to the seq serial number in the queue, stopping the old player when the SSRC of the received audio data packet is changed, starting a new player, and continuing playing.
S203: and receiving a second audio data packet and recording a synchronous information source identifier carried by the second audio data packet.
In this embodiment, the second audio data packet may carry a multicast identifier, which is used to instruct sending of the listening terminal to other listening terminals.
Optionally, the second audio data packet is a real-time transport protocol audio data packet.
Wherein the second audio data packet may be a speaker terminal of any one of the terminal devices in the cluster of fig. 1. The terminal that sends the second audio data packet may be the same as or different from the terminal that sends the first audio data packet.
S204: and if detecting that the main terminal sending the second audio data packet is different from the main terminal sending the first audio data packet, judging whether the synchronous source identifier of the first audio data packet is the same as the synchronous source identifier of the second audio data packet.
In this embodiment, the first audio data packet further carries an equipment identifier of a calling terminal that sends the first audio data packet, and the second audio data packet further carries an equipment identifier of a calling terminal that sends the second audio data packet;
specifically, a process of detecting whether the calling terminal sending the second audio data packet is the same as the calling terminal sending the first audio data packet is as follows:
if the equipment identification of the talkback terminal of the second audio data packet is the same as that of the talkback terminal of the first audio data packet, determining that the talkback terminal sending the second audio data packet is the same as that of the first audio data packet;
and if the equipment identification of the main speaking terminal of the second audio data packet is different from the equipment identification of the main speaking terminal of the first audio data packet, determining that the main speaking terminal sending the second audio data packet is different from the main speaking terminal of the first audio data packet.
S205: and if the synchronous source identifier of the first audio data packet is the same as the synchronous source identifier of the second audio data packet, generating an audio silence frame, wherein the synchronous source identifier carried by the audio silence frame is different from the synchronous source identifier of the first audio data packet and the synchronous source identifier of the second audio data packet.
In this embodiment, the data portion in the message of the audio silence frame has no content, and the field is null; the header carries a synchronous source identifier carried by the audio silence frame, and the synchronous source identifier is different from the synchronous source identifier of the first audio data packet and the synchronous source identifier of the second audio data packet.
For example, the sync source identifier of the first audio packet and the sync source identifier of the second audio packet are 0x01, and the sync source identifier carried by an audio silence frame is 0x 02.
S206: and sending the audio silence frame to the monitoring terminal.
In this embodiment, after receiving the audio silence frame, the monitoring terminal recognizes that the synchronization source identifier carried by the audio silence frame is different from the synchronization source identifier of the currently recorded first audio data packet, and when the SSRC of the audio data packet changes, the monitoring terminal stops the player of the first audio data packet, initializes a new player, and continues to perform the audio silence frame. Since the audio silence frame has no data content, the listening terminal does not hear the sound.
S207: and after the audio silence frame is sent, sending the second audio data packet to the monitoring terminal for playing.
In this embodiment, after receiving the second audio data packet, the monitoring terminal recognizes that the synchronization source identifier carried in the second audio data packet is different from the synchronization source identifier of the currently recorded audio silence frame, and when the SSRC of the audio data packet is changed, the player of the audio silence frame is stopped, a new player is started, and the second audio data is continued. Because the new player is adopted, the second audio data can be completely played, and the problem that a section of sound in front of the new main speaking terminal which is played by the monitoring terminal cannot be heard does not occur.
As can be seen from the above description, in this embodiment, by detecting that the talker terminal sending the second audio packet is different from the talker terminal of the first audio packet, it is continuously determined whether the sync source identifier of the first audio packet is the same as the sync source identifier of the second audio packet; when the synchronous source identifier of the first audio data packet is the same as the synchronous source identifier of the second audio data packet, sending an audio silence frame carrying a synchronous source identifier different from the synchronous source identifier of the first audio data packet and the synchronous source identifier of the second audio data packet to the monitoring terminal, so that after the monitoring terminal receives the second audio data packet, identifying the synchronous source identifier carried by the second audio data packet, and when the SSRC of the audio data packet is changed, stopping the player of the audio silence frame, starting a new player, and continuing to perform the second audio data, so as to solve the problem that the source of the master terminal signal is not changed when the master terminal signal is changed in the prior art, that is, the SSRC of the audio data packet is not changed, if the monitoring terminal receives a new audio data packet of the master terminal, and the seq serial number of the data packet is partially consistent with the seq serial number of the previous data packet of the main speaking terminal, the monitoring terminal can default that the audio data packet is an expired audio data packet and then discard the audio data packet, so that the previous section of sound of the new main speaking terminal played by the monitoring terminal cannot be heard, and the listening experience of a user is influenced.
In an embodiment of the present invention, after the step S203, the method further includes: and if detecting that the main speaking terminal for sending the second audio data packet is the same as the main speaking terminal for sending the first audio data packet, sending the second audio data packet to the monitoring terminal.
In an embodiment of the present invention, after the step S204, the method further includes: and if the synchronous source identifier of the first audio data packet is different from the synchronous source identifier of the second audio data packet, sending the second audio data packet to the monitoring terminal.
Fig. 3 is a schematic view of an interaction flow of an audio playing method according to an embodiment of the present invention, and this embodiment explains details of a specific implementation process of this embodiment on the basis of the embodiment of fig. 2. As shown in fig. 3, the method includes:
s301: the data transfer server receives and receives a first audio data packet and records a synchronous information source identifier carried by the first audio data packet;
s302: and the data transfer server sends the first audio data packet to a monitoring terminal for playing.
S303: and the monitoring terminal records the synchronous source identifier of the first audio data packet, starts a player corresponding to the synchronous source identifier of the first audio data packet, puts the first audio data packet into a queue of the audio player according to the seq serial number, and starts a decoder to play the first audio data packet.
Referring to fig. 4, fig. 4 is a schematic diagram of a queue of an audio player according to an embodiment of the present invention. If the seq serial number of the current audio data packet is 12, the current audio data packet is placed behind the audio data packet with the serial number 11, and after the audio data packets with the serial numbers 1 to 11 are played, the audio data packet with the serial number 12 is played.
S304: and the data transfer server receives the second audio data packet and records the synchronous information source identifier carried by the second audio data packet.
S305: and the data transfer server detects whether the talkback terminal sending the second audio data packet is the same as the talkback terminal of the first audio data packet. If yes, go to step S306; if not, go to step S312.
S306: and the data transfer server judges whether the synchronous source identifier of the first audio data packet is the same as the synchronous source identifier of the second audio data packet. If yes, go to step S307; if not, go to step S312.
S307: and the data transit server generates an audio silence frame, wherein the synchronous information source identifier carried by the audio silence frame is different from the synchronous information source identifier of the first audio data packet and the synchronous information source identifier of the second audio data packet.
S308: and the data transfer server sends the audio silence frame to the monitoring terminal.
S309: the monitoring terminal records the audio silence frame, the synchronous source identifier of the audio silence frame is different from the synchronous source identifier of the first audio data packet, the player corresponding to the synchronous source identifier of the first audio data packet is stopped, the player corresponding to the synchronous source identifier of the audio silence frame is initialized, the audio silence frame is placed in the queue of the audio player according to the seq serial number, and the player starts a decoder to play the audio silence frame.
In this embodiment, since the audio silence frame has no data content, the listening terminal does not hear the sound.
S310: and after the audio silence frame is sent, the data transfer server sends the second audio data packet to the monitoring terminal for playing.
S311: the monitoring terminal records that the synchronous source identifier of the second audio data packet is different from the synchronous source identifier of the audio silence frame, a player corresponding to the synchronous source identifier of the audio silence frame is stopped, the player corresponding to the synchronous source identifier of the second audio data packet is initialized, the second audio data packet is placed into a queue of the audio player according to the seq serial number, and the player starts a decoder to play the second audio data packet.
S312: and the data transfer server sends the second audio data packet to the monitoring terminal.
In the audio playing method provided by this embodiment, an audio silence frame carrying a synchronization source identifier different from the synchronization source identifier of the first audio data packet and the synchronization source identifier of the second audio data packet is sent to the monitoring terminal, so as to solve the problem that when the talkback terminal changes and the synchronization source identifier does not change, a previous section of audio sent by a new talkback terminal cannot be identified and played by the monitoring terminal.
Fig. 5 is a schematic structural diagram of an audio playing device according to an embodiment of the present invention. As shown in fig. 5, the audio playback device 50 includes: a first receiving module 501, a first sending module 502, a second receiving module 503, a detection judging module 504, an audio silence frame processing module 505, a second sending module 506 and a third sending module 507.
A first receiving module 501, configured to receive a first audio data packet and record a synchronization source identifier carried in the first audio data packet;
a first sending module 502, configured to send the first audio data packet to a monitoring terminal for playing;
a second receiving module 503, configured to receive a second audio data packet, and record a synchronization source identifier carried in the second audio data packet;
a detection and judgment module 504, configured to judge whether the synchronous source identifier of the first audio data packet is the same as the synchronous source identifier of the second audio data packet if it is detected that the master terminal that sends the second audio data packet is different from the master terminal that sends the first audio data packet;
an audio silence frame processing module 505, configured to generate an audio silence frame if the synchronization source identifier of the first audio data packet is the same as the synchronization source identifier of the second audio data packet, where a synchronization source identifier carried in the audio silence frame is different from the synchronization source identifier of the first audio data packet and the synchronization source identifier of the second audio data packet;
a second sending module 506, configured to send the audio silence frame to the monitoring terminal;
a third sending module 507, configured to send the second audio data packet to the monitoring terminal for playing after the audio silence frame is sent.
The device provided in this embodiment may be used to implement the technical solution of the above method embodiment, and the implementation principle and technical effect are similar, which are not described herein again.
In an embodiment of the present invention, the first audio data packet further carries an equipment identifier of a calling terminal that sends the first audio data packet, and the second audio data packet further carries an equipment identifier of a calling terminal that sends the second audio data packet;
the detection and judgment module 504 is configured to determine that the talkback terminal that sends the second audio data packet is the same as the talkback terminal of the first audio data packet if the device identifier of the talkback terminal of the second audio data packet is the same as the device identifier of the talkback terminal of the first audio data packet; and if the equipment identification of the main speaking terminal of the second audio data packet is different from the equipment identification of the main speaking terminal of the first audio data packet, determining that the main speaking terminal sending the second audio data packet is different from the main speaking terminal of the first audio data packet.
In one embodiment of the present invention, the first audio data packet and the second audio data packet are real-time transport protocol audio data packets.
In an embodiment of the present invention, the third sending module 507 is further configured to
And if detecting that the main speaking terminal for sending the second audio data packet is the same as the main speaking terminal for sending the first audio data packet, sending the second audio data packet to the monitoring terminal.
In an embodiment of the present invention, the third sending module 507 is further configured to
And if the synchronous source identifier of the first audio data packet is different from the synchronous source identifier of the second audio data packet, sending the second audio data packet to the monitoring terminal.
The device provided in this embodiment may be used to implement the technical solution of the above method embodiment, and the implementation principle and technical effect are similar, which are not described herein again.
Fig. 6 is a schematic diagram of a hardware structure of an audio playing device according to an embodiment of the present invention. As shown in fig. 6, the audio playback device 60 of the present embodiment includes: a processor 601 and a memory 602; wherein
A memory 602 for storing computer-executable instructions;
the processor 601 is configured to execute the computer execution instructions stored in the memory to implement the steps performed by the data relay server in the foregoing embodiments. Reference may be made in particular to the description relating to the method embodiments described above.
Alternatively, the memory 602 may be separate or integrated with the processor 601.
When the memory 602 is separately provided, the audio playback apparatus further includes a bus 603 for connecting the memory 602 and the processor 601.
An embodiment of the present invention further provides a computer-readable storage medium, where a computer executing instruction is stored in the computer-readable storage medium, and when a processor executes the computer executing instruction, the audio playing method as described above is implemented.
In the embodiments provided in the present invention, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described device embodiments are merely illustrative, and for example, the division of the modules is only one logical division, and other divisions may be realized in practice, for example, a plurality of modules may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or modules, and may be in an electrical, mechanical or other form.
The modules described as separate parts may or may not be physically separate, and parts displayed as modules may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment.
In addition, functional modules in the embodiments of the present invention may be integrated into one processing unit, or each module may exist alone physically, or two or more modules are integrated into one unit. The unit formed by the modules can be realized in a hardware form, and can also be realized in a form of hardware and a software functional unit.
The integrated module implemented in the form of a software functional module may be stored in a computer-readable storage medium. The software functional module is stored in a storage medium and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network device) or a processor (processor) to execute some steps of the methods according to the embodiments of the present application.
It should be understood that the Processor may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of a method disclosed in connection with the present invention may be embodied directly in a hardware processor, or in a combination of the hardware and software modules within the processor.
The memory may comprise a high-speed RAM memory, and may further comprise a non-volatile storage NVM, such as at least one disk memory, and may also be a usb disk, a removable hard disk, a read-only memory, a magnetic or optical disk, etc.
The bus may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, an Extended ISA (Extended Industry Standard Architecture) bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, the buses in the figures of the present application are not limited to only one bus or one type of bus.
The storage medium may be implemented by any type or combination of volatile or non-volatile memory devices, such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks. A storage media may be any available media that can be accessed by a general purpose or special purpose computer.
An exemplary storage medium is coupled to the processor such the processor can read information from, and write information to, the storage medium. Of course, the storage medium may also be integral to the processor. The processor and the storage medium may reside in an Application Specific Integrated Circuits (ASIC). Of course, the processor and the storage medium may reside as discrete components in an electronic device or host device.
Those of ordinary skill in the art will understand that: all or a portion of the steps of implementing the above-described method embodiments may be performed by hardware associated with program instructions. The program may be stored in a computer-readable storage medium. When executed, the program performs steps comprising the method embodiments described above; and the aforementioned storage medium includes: various media that can store program codes, such as ROM, RAM, magnetic or optical disks.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; while the invention has been described in detail and with reference to the foregoing embodiments, it will be understood by those skilled in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. An audio playing method, comprising:
receiving a first audio data packet and recording a synchronous information source identifier carried by the first audio data packet;
sending the first audio data packet to a monitoring terminal for playing;
receiving a second audio data packet and recording a synchronous information source identifier carried by the second audio data packet;
if the fact that a main speaking terminal sending the second audio data packet is different from a main speaking terminal of the first audio data packet is detected, whether a synchronous information source identifier of the first audio data packet is the same as a synchronous information source identifier of the second audio data packet is judged;
if the synchronous source identifier of the first audio data packet is the same as the synchronous source identifier of the second audio data packet, generating an audio silence frame, wherein the synchronous source identifier carried by the audio silence frame is different from the synchronous source identifier of the first audio data packet and the synchronous source identifier of the second audio data packet;
sending the audio silence frame to the monitoring terminal;
and after the audio silence frame is sent, sending the second audio data packet to the monitoring terminal for playing.
2. The method according to claim 1, wherein the first audio data packet further carries a device identifier of a calling terminal sending the first audio data packet, and the second audio data packet further carries a device identifier of a calling terminal sending the second audio data packet;
the method further comprises a process of detecting whether the calling terminal sending the second audio data packet is the same as the calling terminal sending the first audio data packet:
if the equipment identification of the talkback terminal of the second audio data packet is the same as that of the talkback terminal of the first audio data packet, determining that the talkback terminal sending the second audio data packet is the same as that of the first audio data packet;
and if the equipment identification of the main speaking terminal of the second audio data packet is different from the equipment identification of the main speaking terminal of the first audio data packet, determining that the main speaking terminal sending the second audio data packet is different from the main speaking terminal of the first audio data packet.
3. The method of claim 1, further comprising:
and if detecting that the main speaking terminal for sending the second audio data packet is the same as the main speaking terminal for sending the first audio data packet, sending the second audio data packet to the monitoring terminal.
4. The method of claim 1, wherein determining whether the synchronous source identifier of the first audio packet is the same as the synchronous source identifier of the second audio packet further comprises:
and if the synchronous source identifier of the first audio data packet is different from the synchronous source identifier of the second audio data packet, sending the second audio data packet to the monitoring terminal.
5. The method of any of claims 1 to 4, wherein the first audio data packet and the second audio data packet are real time transport protocol audio data packets.
6. An audio playback device, comprising:
the first receiving module is used for receiving a first audio data packet and recording a synchronous information source identifier carried by the first audio data packet;
the first sending module is used for sending the first audio data packet to a monitoring terminal for playing;
the second receiving module is used for receiving a second audio data packet and recording a synchronous information source identifier carried by the second audio data packet;
a detection judging module, configured to judge whether a synchronous source identifier of the first audio data packet is the same as a synchronous source identifier of the second audio data packet if it is detected that a talker terminal that sends the second audio data packet is different from a talker terminal that sends the first audio data packet;
an audio silence frame processing module, configured to generate an audio silence frame if the synchronization source identifier of the first audio data packet is the same as the synchronization source identifier of the second audio data packet, where a synchronization source identifier carried by the audio silence frame is different from the synchronization source identifier of the first audio data packet and the synchronization source identifier of the second audio data packet;
the second sending module is used for sending the audio silence frame to the monitoring terminal;
and the third sending module is used for sending the second audio data packet to the monitoring terminal for playing after the audio silence frame is sent.
7. The device according to claim 6, wherein the first audio data packet further carries a device identifier of a calling terminal sending the first audio data packet, and the second audio data packet further carries a device identifier of a calling terminal sending the second audio data packet;
the detection and judgment module is used for determining that the talkback terminal sending the second audio data packet is the same as the talkback terminal of the first audio data packet if the equipment identifier of the talkback terminal of the second audio data packet is the same as the equipment identifier of the talkback terminal of the first audio data packet; and if the equipment identification of the main speaking terminal of the second audio data packet is different from the equipment identification of the main speaking terminal of the first audio data packet, determining that the main speaking terminal sending the second audio data packet is different from the main speaking terminal of the first audio data packet.
8. The apparatus according to claim 6, wherein the third sending module is further configured to send the second audio data packet to the listening terminal if it is detected that the speaker terminal sending the second audio data packet is the same as the speaker terminal sending the first audio data packet.
9. An audio playback device, comprising: at least one processor and memory;
the memory stores computer-executable instructions;
the at least one processor executing the computer-executable instructions stored by the memory causes the at least one processor to perform the audio playback method of any of claims 1 to 5.
10. A computer-readable storage medium having computer-executable instructions stored therein, which when executed by a processor, implement the audio playback method of any one of claims 1 to 5.
CN201910598427.9A 2019-07-04 2019-07-04 Audio playing method and equipment Active CN112187705B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910598427.9A CN112187705B (en) 2019-07-04 2019-07-04 Audio playing method and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910598427.9A CN112187705B (en) 2019-07-04 2019-07-04 Audio playing method and equipment

Publications (2)

Publication Number Publication Date
CN112187705A CN112187705A (en) 2021-01-05
CN112187705B true CN112187705B (en) 2022-04-15

Family

ID=73915679

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910598427.9A Active CN112187705B (en) 2019-07-04 2019-07-04 Audio playing method and equipment

Country Status (1)

Country Link
CN (1) CN112187705B (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1087557A2 (en) * 1999-09-22 2001-03-28 Matsushita Electric Industrial Co., Ltd. Apparatus for transmitting digital audio data and receiving apparatus for receiving the digital audio data
CN103259803A (en) * 2013-06-04 2013-08-21 腾讯科技(深圳)有限公司 Audio playback method, device and system
CN106653068A (en) * 2016-10-08 2017-05-10 广东欧珀移动通信有限公司 Audio data playing method, device and terminal
WO2018049627A1 (en) * 2016-09-14 2018-03-22 海能达通信股份有限公司 Cluster group call processing method, related device, and system
CN109120974A (en) * 2018-07-25 2019-01-01 深圳市异度信息产业有限公司 A kind of method and device that audio-visual synchronization plays
CN109257655A (en) * 2018-09-29 2019-01-22 视联动力信息技术股份有限公司 Audio-frequency processing method and device when a kind of program switches
CN109600341A (en) * 2017-09-30 2019-04-09 华为技术有限公司 A kind of instant messaging detection method and equipment
CN109862475A (en) * 2019-01-28 2019-06-07 Oppo广东移动通信有限公司 Audio-frequence player device and method, storage medium, communication terminal

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080285727A1 (en) * 2007-05-16 2008-11-20 Shelia Jean Burgess Communications Controller And Protocol
US7924890B2 (en) * 2006-02-13 2011-04-12 Cisco Technology, Inc. Apparatus and method for increasing reliability of data sensitive to packet loss
US9053699B2 (en) * 2012-07-10 2015-06-09 Google Technology Holdings LLC Apparatus and method for audio frame loss recovery

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1087557A2 (en) * 1999-09-22 2001-03-28 Matsushita Electric Industrial Co., Ltd. Apparatus for transmitting digital audio data and receiving apparatus for receiving the digital audio data
CN1290006A (en) * 1999-09-22 2001-04-04 松下电器产业株式会社 Audio Transmitting device and receiving device
CN103259803A (en) * 2013-06-04 2013-08-21 腾讯科技(深圳)有限公司 Audio playback method, device and system
WO2018049627A1 (en) * 2016-09-14 2018-03-22 海能达通信股份有限公司 Cluster group call processing method, related device, and system
CN106653068A (en) * 2016-10-08 2017-05-10 广东欧珀移动通信有限公司 Audio data playing method, device and terminal
CN109600341A (en) * 2017-09-30 2019-04-09 华为技术有限公司 A kind of instant messaging detection method and equipment
CN109120974A (en) * 2018-07-25 2019-01-01 深圳市异度信息产业有限公司 A kind of method and device that audio-visual synchronization plays
CN109257655A (en) * 2018-09-29 2019-01-22 视联动力信息技术股份有限公司 Audio-frequency processing method and device when a kind of program switches
CN109862475A (en) * 2019-01-28 2019-06-07 Oppo广东移动通信有限公司 Audio-frequence player device and method, storage medium, communication terminal

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
IEEE Standard for Information technology—Telecommunications and information exchange between systems Local and metropolitan area networks—Specific requirements - Part 11: Wireless LAN Medium Access Control (MAC) and Physical Layer (PHY) Specifications;IEEE;《IEEE Std 802.11-2016 (Revision of IEEE Std 802.11-2012)》;20161214;全文 *
基于RTP协议的音频流同步控制策略及实现;王正等;《计算机工程与应用》;20061101(第23期);全文 *
音视频新闻内容侦测***的设计与实现;张峤;《中国优秀硕士学位论文全文数据库(电子期刊)》;20170215(第02期);全文 *

Also Published As

Publication number Publication date
CN112187705A (en) 2021-01-05

Similar Documents

Publication Publication Date Title
US8838447B2 (en) Method for classifying voice conference minutes, device, and system
CN106302997B (en) Output control method, electronic equipment and system
TW201427457A (en) Method, terminal, server and system for sharing information
CN107329726B (en) Method and device for processing input audio data in Android system
WO2016150316A1 (en) Audio output control method and apparatus
EP3846020A1 (en) Sound effect adjusting method and apparatus, electronic device, and storage medium
CN110087215B (en) Information broadcasting method and device based on Bluetooth connection, terminal and storage medium
EP4047471A1 (en) Audio data processing method, server, and storage medium
CN110211578B (en) Sound box control method, device and equipment
US11115765B2 (en) Centrally controlling communication at a venue
CN111447603A (en) Data transmission method and device
CN108132769A (en) A kind of audio data play method and dual-screen mobile terminal
CN109120779B (en) Microphone blockage reminding method and related device
CN110457078A (en) Intelligent Service method, device and equipment
CN110602338B (en) Audio processing method, device, system, storage medium and equipment
CN112187705B (en) Audio playing method and equipment
CN113934397A (en) Broadcast control method in electronic equipment and electronic equipment
CN109040937B (en) Microphone blockage reminding method and related device
CN114639392A (en) Audio processing method and device, electronic equipment and storage medium
CN108196817B (en) Audio recognition method, device and storage medium
CN107424620B (en) Audio decoding method and device
CN112311491A (en) Multimedia data acquisition method and device, storage medium and electronic equipment
US20130132074A1 (en) Method and system for reproducing and distributing sound source of electronic terminal
CN110457077A (en) Intelligent Service method, device and equipment
WO2024093264A1 (en) Audio detection method, apparatus and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant