[go: up one dir, main page]

CN111554312A - Method, device and system for controlling audio coding type - Google Patents

Method, device and system for controlling audio coding type Download PDF

Info

Publication number
CN111554312A
CN111554312A CN202010414151.7A CN202010414151A CN111554312A CN 111554312 A CN111554312 A CN 111554312A CN 202010414151 A CN202010414151 A CN 202010414151A CN 111554312 A CN111554312 A CN 111554312A
Authority
CN
China
Prior art keywords
type
working mode
coding
data
encoding
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.)
Pending
Application number
CN202010414151.7A
Other languages
Chinese (zh)
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.)
Xian Wanxiang Electronics Technology Co Ltd
Original Assignee
Xian Wanxiang Electronics Technology Co 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 Xian Wanxiang Electronics Technology Co Ltd filed Critical Xian Wanxiang Electronics Technology Co Ltd
Priority to CN202010414151.7A priority Critical patent/CN111554312A/en
Publication of CN111554312A publication Critical patent/CN111554312A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
    • G10L19/00Speech or audio signals analysis-synthesis techniques for redundancy reduction, e.g. in vocoders; Coding or decoding of speech or audio signals, using source filter models or psychoacoustic analysis
    • G10L19/04Speech or audio signals analysis-synthesis techniques for redundancy reduction, e.g. in vocoders; Coding or decoding of speech or audio signals, using source filter models or psychoacoustic analysis using predictive techniques
    • G10L19/16Vocoder architecture
    • G10L19/18Vocoders using multiple modes
    • G10L19/22Mode decision, i.e. based on audio signal content versus external parameters

Landscapes

  • Engineering & Computer Science (AREA)
  • Computational Linguistics (AREA)
  • Signal Processing (AREA)
  • Health & Medical Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • Acoustics & Sound (AREA)
  • Multimedia (AREA)
  • Telephonic Communication Services (AREA)

Abstract

The invention discloses a method, a device and a system for controlling audio coding types. Wherein, the method comprises the following steps: judging the working mode of the encoder; distributing corresponding coding types according to the judgment result; and coding the data to be transmitted according to the coding type. The invention solves the technical problem of resource waste caused by the fact that the audio acquisition device and the corresponding coding and decoding device are always in a working state when the computer carries out audio processing.

Description

Method, device and system for controlling audio coding type
Technical Field
The invention relates to the technical field of computers, in particular to a method, a device and a system for controlling audio coding types.
Background
Computer remote operation, such as office work, entertainment and the like, has become a common computer use mode at present, and besides picture zooming, audio zooming is also available. Unlike video, audio zooming is bi-directional, with microphone sound input in addition to the sound played by the computer if there is a voice call. One-way speech processing is relatively simple, but two problems exist with two-way audio processing. The audio data needs to be compressed and encoded before transmission to be suitable for network transmission, but the audio data is different according to the type thereof, such as music, general applicability, and the like.
Aiming at the problem of resource waste caused by the fact that when the computer carries out audio processing, an audio acquisition device and a corresponding coding and decoding device are always in a working state, an effective solution is not provided at present.
Disclosure of Invention
The embodiment of the invention provides a method, a device and a system for controlling audio coding types, which are used for at least solving the technical problem of resource waste caused by the fact that an audio acquisition device and a corresponding coding and decoding device are always in a working state when a computer carries out audio processing.
According to an aspect of the embodiments of the present invention, there is provided a method for controlling audio coding types, including: judging the working mode of the encoder; distributing corresponding coding types according to the judgment result; and coding the data to be transmitted according to the coding type.
Optionally, determining the working mode of the encoder includes: judging whether an application request message of the audio acquisition equipment exists or not; determining the working mode of the encoder as a first type of working mode under the condition that the judgment result is yes; under the condition that the judgment result is negative, determining that the working mode of the encoder is a second type working mode; the first type of working mode is a duplex mode, and the second type of working mode is a simplex mode.
Optionally, the allocating the corresponding coding type according to the determination result includes: under the condition that the working mode of the encoder is a first-class working mode, matching a corresponding first-class encoding type according to the first-class working mode; under the condition that the working mode of the encoder is a second type working mode, matching a corresponding second type encoding type according to the second type working mode; the first type of coding type is a voice coding type based on IP, and the second type of coding type is a music coding type.
Further, optionally, encoding the data to be transmitted according to the encoding type includes: collecting data to be transmitted in an application program; if the coding type is a first type coding type, coding the data to be transmitted according to the first type coding type; and if the coding type is the second type coding type, coding the data to be transmitted according to the second type coding type.
Optionally, after determining the operation mode of the encoder, the method further includes: and sending a working mode switching message to the terminal equipment, wherein the working mode switching message is used for indicating the terminal equipment to switch the first type of working mode into the second type of working mode, or switching the second type of working mode into the first type of working mode.
According to another aspect of the embodiments of the present invention, there is also provided a method for controlling audio coding types, including: receiving a working mode switching message sent by a server; controlling the audio acquisition equipment to acquire data according to the working mode switching message; and coding the collected data according to a preset coding type.
Optionally, controlling the audio acquisition device to acquire data according to the working mode switching message includes: if the working mode switching message indicates that the working mode of the terminal equipment is the first type of working mode, starting the audio acquisition equipment for data acquisition; if the working mode switching message indicates that the working mode of the terminal equipment is the second type of working mode, closing the audio acquisition equipment for data acquisition; the first type of working mode is a duplex mode, and the second type of working mode is a simplex mode.
Further, optionally, encoding the acquired data according to a preset encoding type includes: under the condition that the working mode of the terminal equipment is a first-class working mode, acquiring a corresponding first-class coding type according to the first-class working mode; encoding the acquired data according to the first type of encoding type; or, under the condition that the working mode of the terminal equipment is a second type working mode, acquiring a corresponding second type coding type according to the second type working mode; encoding the acquired data according to the second type of encoding type; the first type of coding type is a voice coding type based on IP, and the second type of coding type is a music coding type.
According to another aspect of the embodiments of the present invention, there is also provided an apparatus for controlling an audio encoding type, including: the judging module is used for judging the working mode of the encoder; the distribution module is used for distributing the corresponding coding type according to the judgment result; and the coding module is used for coding the data to be transmitted according to the coding type.
According to still another aspect of the embodiments of the present invention, there is also provided an apparatus for controlling an audio encoding type, including: the receiving module is used for receiving the working mode switching message sent by the server; the acquisition module is used for controlling the audio acquisition equipment to acquire data according to the working mode switching message; and the coding module is used for coding the acquired data according to a preset coding type.
According to an aspect of another embodiment of the present invention, there is also provided a system for controlling audio coding types, including: the server is used for acquiring data to be transmitted in the application program according to the first type of coding type corresponding to the first type of working mode matching under the condition of the first type of working mode; coding data to be transmitted according to the first type of coding type, and sending the coded data to terminal equipment; before matching the corresponding first type coding type according to the first type working mode, sending a working mode switching message to the terminal equipment for indicating the terminal equipment to switch the working mode to the first type working mode; the terminal equipment is used for receiving the working mode switching message and switching the working mode to a first type of working mode according to the working mode switching message; receiving encoded data sent by a server, decoding the encoded data according to a first type of decoding type, and playing the decoded data; starting the audio acquisition equipment to acquire data according to the first type of working mode, encoding the data according to the first type of encoding type, and returning the encoded data to the server; or, the server is used for acquiring the data to be transmitted in the application program according to the second type of coding type corresponding to the second type of working mode matching under the condition of the second type of working mode; coding data to be transmitted according to the second type of coding type, and sending the coded data to the terminal equipment; before the corresponding second type coding type is matched according to the second type working mode, a working mode switching message is sent to the terminal equipment and used for indicating the terminal equipment to switch the working mode to the second type working mode; the terminal equipment is used for receiving the working mode switching message and switching the working mode to a second type of working mode according to the working mode switching message; receiving the encoded data sent by the server, decoding the encoded data according to the second type of decoding type, and playing the decoded data; closing the audio acquisition equipment to acquire data according to the second type of working mode, encoding the data according to the second type of encoding type, and returning the encoded data to the server; the first type of working mode is a duplex mode, and the second type of working mode is a simplex mode; the first type of coding type is a voice coding type based on IP, and the second type of coding type is a music coding type; the first type of decoding type is an IP-based voice decoding type, and the second type of decoding type is a music decoding type.
According to an aspect of another embodiment of the present invention, there is also provided a storage medium, where the storage medium includes a stored program, and where the program is executed to control a device in which the storage medium is located to execute the above method for controlling audio encoding type.
According to an aspect of another embodiment of the present invention, there is also provided a processor, wherein the processor is configured to execute a program, and wherein the program executes the method for controlling the audio coding type.
In the embodiment of the invention, the working mode of the encoder is judged; distributing corresponding coding types according to the judgment result; the data to be transmitted are encoded according to the encoding type, the purpose of distributing corresponding computing resources according to the corresponding audio service is achieved, the technical effect of saving the computing resources is achieved, and the technical problem of resource waste caused by the fact that an audio acquisition device and a corresponding encoding and decoding device are always in a working state when a computer performs audio processing is solved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the invention and together with the description serve to explain the invention without limiting the invention. In the drawings:
fig. 1 is a flowchart illustrating a method for controlling an audio encoding type in a server according to an embodiment of the present invention;
fig. 2 is a flowchart illustrating a method of controlling an audio encoding type in a terminal according to an embodiment of the present invention;
fig. 3 is a schematic diagram of an apparatus for controlling an audio encoding type in a server according to an embodiment of the present invention;
fig. 4 is a schematic diagram of an apparatus for controlling an audio encoding type in a terminal according to an embodiment of the present invention;
FIG. 5 is a schematic diagram of a system for controlling audio coding types according to an embodiment of the present invention;
fig. 6 is a schematic diagram of a single-duplex flow in a system for controlling audio coding types according to an embodiment of the present invention;
fig. 7 is a schematic diagram of a single-duplex flow in another system for controlling audio coding types according to an embodiment of the present invention.
Detailed Description
In order to make the technical solutions of the present invention better understood, 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 only a part of the embodiments of the present invention, and not all of the embodiments. 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.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are capable of operation in sequences other than those illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Example one
In accordance with an embodiment of the present invention, there is provided a method embodiment of a method of controlling an audio encoding type, it being noted that the steps illustrated in the flowchart of the figure may be performed in a computer system such as a set of computer-executable instructions and that, although a logical order is illustrated in the flowchart, in some cases the steps illustrated or described may be performed in an order different than here.
Fig. 1 is a flowchart illustrating a method for controlling audio coding type according to an embodiment of the present invention, applied to a server side, as shown in fig. 1, the method includes the following steps:
step S102, judging the working mode of the encoder;
step S104, distributing corresponding coding types according to the judgment result;
and step S106, encoding the data to be transmitted according to the encoding type.
In the embodiment of the invention, the working mode of the encoder is judged; distributing corresponding coding types according to the judgment result; the data to be transmitted are encoded according to the encoding type, the purpose of distributing corresponding computing resources according to the corresponding audio service is achieved, the technical effect of saving the computing resources is achieved, and the technical problem of resource waste caused by the fact that an audio acquisition device and a corresponding encoding and decoding device are always in a working state when a computer performs audio processing is solved.
Optionally, the determining the working mode of the encoder in step S102 includes: judging whether an application request message of the audio acquisition equipment exists or not; determining the working mode of the encoder as a first type of working mode under the condition that the judgment result is yes; under the condition that the judgment result is negative, determining that the working mode of the encoder is a second type working mode; the first type of working mode is a duplex mode, and the second type of working mode is a simplex mode.
Optionally, the step S104 of allocating the corresponding coding type according to the determination result includes: under the condition that the working mode of the encoder is a first-class working mode, matching a corresponding first-class encoding type according to the first-class working mode; under the condition that the working mode of the encoder is a second type working mode, matching a corresponding second type encoding type according to the second type working mode; the first type of coding type is a voice coding type based on IP, and the second type of coding type is a music coding type.
Further, optionally, the encoding the data to be transmitted according to the encoding type in step S106 includes: collecting data to be transmitted in an application program; if the coding type is a first type coding type, coding the data to be transmitted according to the first type coding type; and if the coding type is the second type coding type, coding the data to be transmitted according to the second type coding type.
Optionally, after the determining the working mode of the encoder in step S102, the method for controlling the audio encoding type provided in the embodiment of the present application further includes: and sending a working mode switching message to the terminal equipment, wherein the working mode switching message is used for indicating the terminal equipment to switch the first type of working mode into the second type of working mode, or switching the second type of working mode into the first type of working mode.
Example two
According to another aspect of the embodiments of the present invention, there is also provided a method for controlling an audio coding type, and fig. 2 is a flowchart illustrating the method for controlling an audio coding type according to the embodiments of the present invention, and is applied to a terminal side, as shown in fig. 2, including:
step S202, receiving a working mode switching message sent by a server;
step S204, controlling the audio acquisition equipment to acquire data according to the working mode switching message;
and step S206, encoding the acquired data according to a preset encoding type.
In the embodiment of the invention, the working mode switching message sent by the server is received; controlling the audio acquisition equipment to acquire data according to the working mode switching message; the acquired data is encoded according to the preset encoding type, the purpose of distributing corresponding computing resources according to the corresponding audio service is achieved, the technical effect of saving the computing resources is achieved, and the technical problem of resource waste caused by the fact that an audio acquisition device and a corresponding encoding and decoding device are always in a working state when a computer carries out audio processing is solved.
Optionally, the step S204 of controlling the audio collecting device to collect data according to the working mode switching message includes: if the working mode switching message indicates that the working mode of the terminal equipment is the first type of working mode, starting the audio acquisition equipment for data acquisition; if the working mode switching message indicates that the working mode of the terminal equipment is the second type of working mode, closing the audio acquisition equipment for data acquisition; the first type of working mode is a duplex mode, and the second type of working mode is a simplex mode.
Further, optionally, the encoding the acquired data according to the preset encoding type in step S206 includes: under the condition that the working mode of the terminal equipment is a first-class working mode, acquiring a corresponding first-class coding type according to the first-class working mode; encoding the acquired data according to the first type of encoding type; or, under the condition that the working mode of the terminal equipment is a second type working mode, acquiring a corresponding second type coding type according to the second type working mode; encoding the acquired data according to the second type of encoding type; the first type of coding type is a voice coding type based on IP, and the second type of coding type is a music coding type.
EXAMPLE III
According to another aspect of the embodiments of the present invention, there is also provided an apparatus for controlling an audio coding type, and fig. 3 is a schematic diagram of the apparatus for controlling an audio coding type according to the embodiments of the present invention, and is applied to a service end side, as shown in fig. 3, including: a judging module 32, configured to judge a working mode of the encoder; the distribution module 34 is used for distributing the corresponding coding type according to the judgment result; and the encoding module 36 is configured to encode data to be transmitted according to the encoding type.
Example four
According to still another aspect of the embodiments of the present invention, there is further provided an apparatus for controlling an audio coding type, and fig. 4 is a schematic diagram of the apparatus for controlling an audio coding type according to the embodiments of the present invention, and is applied to a terminal side, as shown in fig. 4, including: a receiving module 42, configured to receive a working mode switching message sent by a server; the acquisition module 44 is used for controlling the audio acquisition equipment to acquire data according to the working mode switching message; and the encoding module 46 is configured to encode the acquired data according to a preset encoding type.
EXAMPLE five
According to an aspect of another embodiment of the present invention, there is also provided a system for controlling audio coding types, including: the server is used for acquiring data to be transmitted in the application program according to the first type of coding type corresponding to the first type of working mode matching under the condition of the first type of working mode; coding data to be transmitted according to the first type of coding type, and sending the coded data to terminal equipment; before matching the corresponding first type coding type according to the first type working mode, sending a working mode switching message to the terminal equipment for indicating the terminal equipment to switch the working mode to the first type working mode; the terminal equipment is used for receiving the working mode switching message and switching the working mode to a first type of working mode according to the working mode switching message; receiving encoded data sent by a server, decoding the encoded data according to a first type of decoding type, and playing the decoded data; starting the audio acquisition equipment to acquire data according to the first type of working mode, encoding the data according to the first type of encoding type, and returning the encoded data to the server; or, the server is used for acquiring the data to be transmitted in the application program according to the second type of coding type corresponding to the second type of working mode matching under the condition of the second type of working mode; coding data to be transmitted according to the second type of coding type, and sending the coded data to the terminal equipment; before the corresponding second type coding type is matched according to the second type working mode, a working mode switching message is sent to the terminal equipment and used for indicating the terminal equipment to switch the working mode to the second type working mode; the terminal equipment is used for receiving the working mode switching message and switching the working mode to a second type of working mode according to the working mode switching message; receiving the encoded data sent by the server, decoding the encoded data according to the second type of decoding type, and playing the decoded data; closing the audio acquisition equipment to acquire data according to the second type of working mode, encoding the data according to the second type of encoding type, and returning the encoded data to the server; the first type of working mode is a duplex mode, and the second type of working mode is a simplex mode; the first type of coding type is a voice coding type based on IP, and the second type of coding type is a music coding type; the first type of decoding type is an IP-based voice decoding type, and the second type of decoding type is a music decoding type.
In summary, the system for controlling the audio encoding type according to the embodiment of the present application is composed of a server and a terminal. The server side further comprises: audio data acquisition, audio data coding and decoding and audio data injection; the terminal includes: the method comprises three parts of audio data coding and decoding, audio data playing and microphone data acquisition. The specific structure is shown in fig. 5.
In the system for controlling the audio coding type according to the embodiment of the present application, the audio data is mainly divided into two types, data with real-time call is abbreviated as VOIP data (duplex mode), and audio data without real-time call is collectively referred to as MUSIC data (simplex mode); in the case of VOIP data, there may be MUSIC data at the same time, but the priority of VOIP data is higher, and the encoder processes the VOIP data uniformly. However, many existing audio codecs support two modes, namely VOIP and MUSIC, and some audio codecs also have an automatic mode to dynamically judge the data type for encoding, so that the CPU occupation is slightly higher, and the system for controlling the audio encoding type in the embodiment of the present application is not considered for the moment; in addition, the decoder does not need to set the data type, and the working mode of the decoder is determined by the encoder.
The data that the server encoder may process includes VOIP data and MUSIC data, and therefore, the working mode of the server encoder needs to be set according to the actual situation. The data to be processed by the terminal encoder is only the VOIP data, so the terminal encoder always encodes in the VOIP data encoding mode.
When an application needs to use the microphone, the data use permission of the microphone is applied to the operating system, that is, the application needs to acquire the input data of the microphone. The system for controlling the audio coding type, which is adopted by the embodiment of the application, utilizes the characteristic that when the application applies for the data use right of the microphone, the current microphone needs to work, at the moment, the audio data stream possibly contains VOIP data, so that an encoder of a server side adopts a VOIP data coding mode for coding, and simultaneously, the server side and the two sides of a terminal are both in a duplex mode; in other cases, when the microphone is not used, the server and the terminal are both in simplex mode.
The working flows of the server and the terminal in the simplex mode and the duplex mode are described below.
When the simplex mode works, the server generates audio data, the audio data is coded and then sent to the terminal, and the terminal only needs to play the audio data through audio playing equipment. The method mainly comprises the following steps:
1. the server judges the working mode of the current encoder, if the VOIP encoding mode is adopted, the MUSIC encoding mode is switched, and then the server works formally;
2. the server side collects audio data played by the application;
3. the server-side encoder encodes the audio data and then sends out the encoded audio data;
4. the terminal receives and decodes the data after the audio coding;
5. and the terminal sends the decoded audio data to the playing equipment for playing.
Data always flows from the server to the terminal, and the flow chart is shown in fig. 6.
When the duplex mode works, the server and the terminal can generate audio data, and the audio data of the server comes from data collected in applications, such as communication software, games and the like. And the audio data of the terminal originates from the microphone. This type of data is collectively referred to herein as VOIP data. Both sides need to encode data while decoding the received audio data. The server needs to inject data into the operating system through the driver (the operating system will transfer the data to the application applying for the microphone use authority), and the terminal needs to send the data to the playing device. The specific process is as follows:
the data flows from the server to the terminal, and the flow chart is shown in fig. 6, and mainly includes the following steps:
1. the server side judges the working mode and duplex mode of the current encoder, the encoder is set to be in a VOIP encoding mode, and then the encoder works formally;
2. the server side collects audio data played by the application;
3. the server-side encoder encodes the audio data and then sends out the encoded audio data;
4. the terminal receives and decodes the data after the audio coding;
5. and the terminal sends the decoded audio data to the playing equipment for playing.
The data flows from the terminal to the server, and the flow chart is shown in fig. 7, which mainly includes the following steps:
1. the server side judges a working mode, a server side audio injection program starts to work in a duplex mode, and meanwhile, the server side informs the terminal of mode switching;
2. the terminal receives the mode information sent by the server, if the mode is the MUSIC mode, the microphone collection is not started, and the process is ended; if the mode is the VOIP mode, starting the microphone data acquisition;
3. the terminal encodes the data and then transmits the data;
4. the server side receives the audio data and then decodes the audio data;
5. and the server side gives the decoded audio data to an audio injection program and injects the audio data into an operating system.
In the duplex mode, data streams in two directions exist simultaneously, and the codecs on the two sides of the server and the terminal both work simultaneously.
EXAMPLE six
According to an aspect of another embodiment of the present invention, there is also provided a storage medium, where the storage medium includes a stored program, and where the program is executed to control a device in which the storage medium is located to execute the above method for controlling audio encoding type.
EXAMPLE seven
According to an aspect of another embodiment of the present invention, there is also provided a processor, wherein the processor is configured to execute a program, and wherein the program executes the method for controlling the audio coding type.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
In the above embodiments of the present invention, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
In the embodiments provided in the present application, it should be understood that the disclosed technology can be implemented in other ways. The above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units may be a logical division, and in actual implementation, there may be another division, for example, multiple units or components 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, units or modules, and may be in an electrical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic or optical disk, and other various media capable of storing program codes.
The foregoing is only a preferred embodiment of the present invention, and it should be noted that, for those skilled in the art, various modifications and decorations can be made without departing from the principle of the present invention, and these modifications and decorations should also be regarded as the protection scope of the present invention.

Claims (13)

1. A method for controlling audio coding types, comprising:
judging the working mode of the encoder;
distributing corresponding coding types according to the judgment result;
and coding the data to be transmitted according to the coding type.
2. The method of claim 1, wherein determining the operating mode of the encoder comprises:
judging whether an application request message of the audio acquisition equipment exists or not;
determining the working mode of the encoder to be a first type of working mode under the condition that the judgment result is yes;
under the condition that the judgment result is negative, determining that the working mode of the encoder is a second type working mode;
the first type of working mode is a duplex mode, and the second type of working mode is a simplex mode.
3. The method of claim 1 or 2, wherein assigning the corresponding coding type according to the determination result comprises:
under the condition that the working mode of the encoder is a first-class working mode, matching a corresponding first-class encoding type according to the first-class working mode;
under the condition that the working mode of the encoder is a second type working mode, matching a corresponding second type encoding type according to the second type working mode;
the first type of coding type is an IP-based voice coding type, and the second type of coding type is a music coding type.
4. The method of claim 3, wherein encoding the data to be transmitted according to the encoding type comprises:
collecting data to be transmitted in an application program;
if the coding type is the first type coding type, coding the data to be transmitted according to the first type coding type;
and if the coding type is the second type coding type, coding the data to be transmitted according to the second type coding type.
5. The method of claim 1, wherein after determining the operating mode of the encoder, the method further comprises:
and sending a working mode switching message to the terminal equipment, wherein the working mode switching message is used for indicating the terminal equipment to switch the first type working mode into the second type working mode, or switching the second type working mode into the first type working mode.
6. A method for controlling audio coding types, comprising:
receiving a working mode switching message sent by a server;
controlling audio acquisition equipment to acquire data according to the working mode switching message;
and coding the collected data according to a preset coding type.
7. The method of claim 6, wherein controlling an audio capture device to capture data according to the operating mode switch message comprises:
if the working mode switching message indicates that the working mode of the terminal equipment is a first type of working mode, starting the audio acquisition equipment for data acquisition;
if the working mode switching message indicates that the working mode of the terminal equipment is the second type of working mode, the audio acquisition equipment is closed to acquire data;
the first type of working mode is a duplex mode, and the second type of working mode is a simplex mode.
8. The method of claim 7, wherein encoding the collected data according to a predetermined encoding type comprises:
under the condition that the working mode of the terminal equipment is a first-class working mode, acquiring a corresponding first-class coding type according to the first-class working mode; encoding the acquired data according to the first type of encoding type; or the like, or, alternatively,
under the condition that the working mode of the terminal equipment is a second type working mode, acquiring a corresponding second type coding type according to the second type working mode; encoding the acquired data according to the second type of encoding type;
the first type of coding type is an IP-based voice coding type, and the second type of coding type is a music coding type.
9. An apparatus for controlling audio coding types, comprising:
the judging module is used for judging the working mode of the encoder;
the distribution module is used for distributing the corresponding coding type according to the judgment result;
and the coding module is used for coding the data to be transmitted according to the coding type.
10. An apparatus for controlling audio coding types, comprising:
the receiving module is used for receiving the working mode switching message sent by the server;
the acquisition module is used for controlling the audio acquisition equipment to acquire data according to the working mode switching message;
and the coding module is used for coding the acquired data according to a preset coding type.
11. A system for controlling audio coding types, comprising: a server and a terminal device, wherein,
the server is used for acquiring data to be transmitted in the application program according to the first type of working mode matching corresponding first type of coding type under the condition of the first type of working mode; coding the data to be transmitted according to the first type of coding type, and sending the coded data to the terminal equipment; before matching a corresponding first type coding type according to a first type working mode, sending a working mode switching message to the terminal equipment for instructing the terminal equipment to switch the working mode to the first type working mode;
the terminal device is used for receiving the working mode switching message and switching the working mode to the first type of working mode according to the working mode switching message; receiving the encoded data sent by the server, decoding the encoded data according to a first type of decoding type, and playing the decoded data; starting audio acquisition equipment to acquire data according to the first type of working mode, encoding the data according to the first type of encoding type, and returning the encoded data to the server;
or the like, or, alternatively,
the server is used for acquiring data to be transmitted in the application program according to the second type of working mode matching corresponding second type of coding type under the condition of the second type of working mode; coding the data to be transmitted according to the second type of coding type, and sending the coded data to the terminal equipment; before matching a corresponding second type coding type according to a second type working mode, sending a working mode switching message to the terminal equipment for instructing the terminal equipment to switch the working mode to the second type working mode;
the terminal device is used for receiving the working mode switching message and switching the working mode to the second type of working mode according to the working mode switching message; receiving the encoded data sent by the server, decoding the encoded data according to a second type of decoding type, and playing the decoded data; closing audio acquisition equipment to acquire data according to the second type of working mode, encoding the data according to the second type of encoding type, and returning the encoded data to the server;
the first type of working mode is a duplex mode, and the second type of working mode is a simplex mode; the first type of coding type is an IP-based voice coding type, and the second type of coding type is a music coding type; the first type of decoding type is an IP-based voice decoding type, and the second type of decoding type is a music decoding type.
12. A storage medium, wherein the storage medium comprises a stored program, and wherein a device on which the storage medium is located is controlled to perform the method of controlling audio coding type according to any one of claims 1 to 8 when the program is run.
13. A processor, wherein the processor is configured to run a program, wherein the program when running performs the method of controlling audio coding type of any of claims 1 to 8.
CN202010414151.7A 2020-05-15 2020-05-15 Method, device and system for controlling audio coding type Pending CN111554312A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010414151.7A CN111554312A (en) 2020-05-15 2020-05-15 Method, device and system for controlling audio coding type

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010414151.7A CN111554312A (en) 2020-05-15 2020-05-15 Method, device and system for controlling audio coding type

Publications (1)

Publication Number Publication Date
CN111554312A true CN111554312A (en) 2020-08-18

Family

ID=72004789

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010414151.7A Pending CN111554312A (en) 2020-05-15 2020-05-15 Method, device and system for controlling audio coding type

Country Status (1)

Country Link
CN (1) CN111554312A (en)

Citations (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030236674A1 (en) * 2002-06-19 2003-12-25 Henry Raymond C. Methods and systems for compression of stored audio
CN1954367A (en) * 2004-05-19 2007-04-25 诺基亚公司 Supporting a switch between audio coder modes
CN101502089A (en) * 2006-07-28 2009-08-05 西门子公司 Method for carrying out an audio conference, audio conference device, and method for switching between encoders
CN102089814A (en) * 2008-07-11 2011-06-08 弗劳恩霍夫应用研究促进协会 An apparatus and a method for decoding an encoded audio signal
CN102113051A (en) * 2008-07-11 2011-06-29 弗朗霍夫应用科学研究促进协会 Low bitrate audio encoding/decoding scheme having cascaded switches
CN102629471A (en) * 2012-03-07 2012-08-08 深圳市福智软件技术有限公司 Multi-decoder audio system, system signal flow and composed mobile equipment
CN103327014A (en) * 2013-06-06 2013-09-25 腾讯科技(深圳)有限公司 Voice processing method, device and system
US20150154964A1 (en) * 2013-12-03 2015-06-04 Google Inc. Multi-path audio processing
CN105812439A (en) * 2014-12-31 2016-07-27 华为技术有限公司 Audio transmission method and device
US20160227337A1 (en) * 2015-01-30 2016-08-04 Dts, Inc. System and method for capturing, encoding, distributing, and decoding immersive audio
CN106453818A (en) * 2015-08-11 2017-02-22 三星电子株式会社 Adaptive Processing of Sound Data
CN106796800A (en) * 2014-07-28 2017-05-31 弗劳恩霍夫应用研究促进协会 The audio coder and decoder of the cross processing device using frequency domain processor, Time Domain Processing device and for continuous initialization
US20170200454A1 (en) * 2016-01-07 2017-07-13 Microsoft Technology Licensing, Llc Encoding an Audio Stream
WO2017142112A1 (en) * 2016-02-19 2017-08-24 주식회사 트리니티랩 Audible frequency band audio signal reception method for low power
CN107408383A (en) * 2015-04-05 2017-11-28 高通股份有限公司 Encoder selects
CN110010139A (en) * 2019-03-28 2019-07-12 南昌黑鲨科技有限公司 Audio input output method, system and computer readable storage medium
CN110180166A (en) * 2019-07-16 2019-08-30 南昌黑鲨科技有限公司 Control system and method based on cloud game scene
CN110557670A (en) * 2019-09-17 2019-12-10 广州华多网络科技有限公司 Method, device, terminal and storage medium for playing video in webpage

Patent Citations (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030236674A1 (en) * 2002-06-19 2003-12-25 Henry Raymond C. Methods and systems for compression of stored audio
CN1954367A (en) * 2004-05-19 2007-04-25 诺基亚公司 Supporting a switch between audio coder modes
CN101502089A (en) * 2006-07-28 2009-08-05 西门子公司 Method for carrying out an audio conference, audio conference device, and method for switching between encoders
CN102089814A (en) * 2008-07-11 2011-06-08 弗劳恩霍夫应用研究促进协会 An apparatus and a method for decoding an encoded audio signal
CN102113051A (en) * 2008-07-11 2011-06-29 弗朗霍夫应用科学研究促进协会 Low bitrate audio encoding/decoding scheme having cascaded switches
CN102629471A (en) * 2012-03-07 2012-08-08 深圳市福智软件技术有限公司 Multi-decoder audio system, system signal flow and composed mobile equipment
CN103327014A (en) * 2013-06-06 2013-09-25 腾讯科技(深圳)有限公司 Voice processing method, device and system
US20150154964A1 (en) * 2013-12-03 2015-06-04 Google Inc. Multi-path audio processing
CN106796800A (en) * 2014-07-28 2017-05-31 弗劳恩霍夫应用研究促进协会 The audio coder and decoder of the cross processing device using frequency domain processor, Time Domain Processing device and for continuous initialization
CN105812439A (en) * 2014-12-31 2016-07-27 华为技术有限公司 Audio transmission method and device
US20160227337A1 (en) * 2015-01-30 2016-08-04 Dts, Inc. System and method for capturing, encoding, distributing, and decoding immersive audio
CN107408383A (en) * 2015-04-05 2017-11-28 高通股份有限公司 Encoder selects
CN106453818A (en) * 2015-08-11 2017-02-22 三星电子株式会社 Adaptive Processing of Sound Data
US20170200454A1 (en) * 2016-01-07 2017-07-13 Microsoft Technology Licensing, Llc Encoding an Audio Stream
WO2017142112A1 (en) * 2016-02-19 2017-08-24 주식회사 트리니티랩 Audible frequency band audio signal reception method for low power
CN110010139A (en) * 2019-03-28 2019-07-12 南昌黑鲨科技有限公司 Audio input output method, system and computer readable storage medium
CN110180166A (en) * 2019-07-16 2019-08-30 南昌黑鲨科技有限公司 Control system and method based on cloud game scene
CN110557670A (en) * 2019-09-17 2019-12-10 广州华多网络科技有限公司 Method, device, terminal and storage medium for playing video in webpage

Similar Documents

Publication Publication Date Title
JP5320406B2 (en) Audio processing method, system, and control server
CN103179431B (en) Under VDI environment, audio frequency and video are redirected and turn code separation method
KR20180031547A (en) Method and apparatus for adaptively providing multiple bit rate stream media in server
CN111432158B (en) Load balancing method and device for media nodes, storage medium and electronic device
CN106227492B (en) Combination and mobile intelligent terminal interconnected method and device
CN102131090A (en) Method, system and media resource server for playing video files
CN111954028A (en) Screen projection method, device and equipment of audio data and storage medium
US9560096B2 (en) Local media rendering
CN106303682A (en) The method and device of channel switch
CN102413309A (en) Method and device for joining video conference
CN111163335B (en) Video processing method and device for distributed server
CN103716681A (en) Code stream switching method and electronic equipment
CN103139202A (en) Thin client, communication method and device thereof
EP4472195A1 (en) Encoding method and apparatus, real-time communication method and apparatus, device, and storage medium
CN114157919A (en) Data processing method and system, cloud terminal, server and computing equipment
CN102624743A (en) Resource allocation method of media server
CN103929682A (en) Method and device for setting key frames in video live broadcast system
CN113259621B (en) Cloud conference step-by-step recording method and system
CN106210036A (en) Video display accelerated method in virtual desktop display device
CN117768448B (en) Streaming parameter adaptation-based audio and video streaming transmission method and system and cloud server
CN110868610B (en) Streaming media transmission method, device, server and storage medium
CN111554312A (en) Method, device and system for controlling audio coding type
CN103686208A (en) Video cloud computing transmitting method
CN102572364A (en) Decoding method and device for video communication data
CN113612956B (en) Video storage and playback system and method based on WebRTC

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20200818