CN107506168B - Volume adjusting method and device, terminal equipment and storage medium - Google Patents

Volume adjusting method and device, terminal equipment and storage medium Download PDF

Info

Publication number
CN107506168B
CN107506168B CN201710711363.XA CN201710711363A CN107506168B CN 107506168 B CN107506168 B CN 107506168B CN 201710711363 A CN201710711363 A CN 201710711363A CN 107506168 B CN107506168 B CN 107506168B
Authority
CN
China
Prior art keywords
amplitude
sound source
volume
adjusting
information
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
CN201710711363.XA
Other languages
Chinese (zh)
Other versions
CN107506168A (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.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp 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 Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201710711363.XA priority Critical patent/CN107506168B/en
Publication of CN107506168A publication Critical patent/CN107506168A/en
Application granted granted Critical
Publication of CN107506168B publication Critical patent/CN107506168B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/16Sound input; Sound output
    • G06F3/165Management of the audio stream, e.g. setting of volume, audio stream path
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/26Power supply means, e.g. regulation thereof
    • G06F1/32Means for saving power
    • G06F1/3203Power management, i.e. event-based initiation of a power-saving mode
    • G06F1/3234Power saving characterised by the action undertaken
    • G06F1/325Power saving in peripheral device

Abstract

The embodiment of the invention discloses a volume adjusting method, a volume adjusting device, terminal equipment and a storage medium, wherein the method comprises the steps of acquiring audio information with a preset length of a sound source when the terminal equipment is detected to play the sound source; determining an amplitude difference in the audio information with the preset length; and if the amplitude difference meets a preset condition, adjusting the amplitude of the sound source. According to the scheme, the volume adjusting efficiency is improved, and the power consumption of the terminal equipment is reduced.

Description

Volume adjusting method and device, terminal equipment and storage medium
Technical Field
The embodiment of the invention relates to computer technology, in particular to a volume adjusting method, a volume adjusting device, terminal equipment and a storage medium.
Background
With the increasing popularity of terminal devices, more and more users use the terminal devices to perform various functions to meet their own needs, such as reading text, watching video, listening to music, playing games, etc. When the terminal equipment plays audio and video, the adjustment of the volume has defects and needs to be improved.
Disclosure of Invention
The invention provides a volume adjusting method, a volume adjusting device, terminal equipment and a storage medium, which improve the volume adjusting efficiency and reduce the power consumption of the terminal equipment.
In a first aspect, an embodiment of the present invention provides a volume adjustment method, including:
when detecting that terminal equipment plays a sound source, acquiring audio information of a preset length of the sound source;
determining an amplitude difference in the audio information of the preset length;
and if the amplitude difference meets a preset condition, adjusting the amplitude of the sound source.
In a second aspect, an embodiment of the present invention further provides a volume adjusting apparatus, including:
the acquisition module is used for acquiring audio information with a preset length of a sound source when the terminal equipment is detected to play the sound source;
the amplitude determining module is used for determining the amplitude difference in the audio information with the preset length;
and the adjusting module is used for adjusting the amplitude of the sound source if the amplitude difference meets a preset condition.
In a third aspect, an embodiment of the present invention further provides a terminal device, including: a processor, a memory, and a computer program stored on the memory and executable on the processor, the processor implementing the volume adjustment method according to an embodiment of the present invention when executing the computer program.
In a fourth aspect, an embodiment of the present invention further provides a storage medium containing terminal device executable instructions, where the terminal device executable instructions are used to execute the volume adjustment method according to the embodiment of the present invention when executed by a terminal device processor.
According to the technical scheme provided by the embodiment of the invention, when the terminal equipment is detected to play the sound source, the audio information with the preset length of the sound source is obtained, the amplitude difference in the audio information with the preset length is determined, and if the amplitude difference meets the preset condition, the amplitude of the sound source is adjusted. According to the scheme, the volume adjusting efficiency is improved, and the power consumption of the terminal equipment is reduced.
Drawings
Other features, objects and advantages of the invention will become more apparent upon reading of the detailed description of non-limiting embodiments made with reference to the following drawings:
fig. 1 is a flowchart of a volume adjustment method according to an embodiment of the present invention;
fig. 2 is a flow chart of another volume adjustment method provided by the embodiment of the invention;
fig. 3 is a flow chart of another volume adjustment method provided by the embodiment of the invention;
fig. 4 is a block diagram of a volume adjustment device according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of another terminal device according to an embodiment of the present invention.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings and examples. It is to be understood that the specific embodiments described herein are for purposes of illustration and not limitation. It should be further noted that, for the convenience of description, only some of the structures related to the present invention are shown in the drawings, not all of the structures.
Fig. 1 is a flowchart of a volume adjustment method provided in an embodiment of the present invention, where this embodiment is applicable to a situation where volume adjustment is performed when a sound source is played by a terminal device, and the method may be executed by the terminal device provided in the embodiment of the present invention, and a volume adjustment device of the terminal device may be implemented in a software and/or hardware manner, as shown in fig. 1, a specific solution provided in this embodiment is as follows:
step S101, when detecting that the terminal equipment plays the sound source, acquiring audio information of the sound source with preset length.
The terminal equipment can play the sound source through the installed third-party application program or the audio and video playing software carried by the system. The method mainly comprises the steps of obtaining, decoding, outputting and the like of the sound source file. Illustratively, the obtained sound source file may be a multicast stream received through a network, or may be an audio/video file locally stored by the terminal device; after the sound source file is obtained, loading the sound source file into a memory buffer area; the method comprises the steps of decoding a sound source file loaded into a memory buffer area, before decoding starts, if the sound source file simultaneously contains video data, separating the audio data from the video data, and inputting the separated audio data into an audio decoder, wherein the audio decoder is mainly used for reading the audio data in the memory buffer area to obtain a digital audio signal and converting the digital audio signal into an analog audio signal, and a playing device of a terminal device plays audio according to the analog audio signal. In one embodiment, when it is monitored that a sound source playing event is triggered, it is determined that the terminal device starts playing a sound source, where the triggering event may be that a playing button displayed in a touch screen is pressed, or that a playing device of the terminal device, such as a speaker, starts playing sound, and the terminal device is determined to play the sound source.
And when detecting that the terminal equipment plays the sound source, acquiring audio information of the sound source with the preset length. In one embodiment, the digital audio signal decoded by the audio decoder may be sampled to determine the audio information corresponding to the sound source, where the preset length may be 3s, 5s, 10s, or the like. In another embodiment, an original file of a currently played sound source may also be obtained, and audio information with a preset length corresponding to the sound source may be determined through parsing of the original file. In another embodiment, for example, in an Android system, the audio information of the sound source may be obtained through an Android.
And step S102, determining the amplitude difference in the audio information with the preset length.
The amplitude refers to the maximum distance from the original position in the vibration process of the object, the loudness of the sound heard by human ears is related to the amplitude of the sound source, and the loudness is stronger when the amplitude is larger. In one embodiment, the digital audio signal decoded by the audio decoder may be sampled to obtain amplitude information, wherein the amplitude information may be composed of a plurality of amplitude values, and the amplitude difference may be determined accordingly according to the obtained plurality of amplitude values. For example, taking 3s as an example, in a sound source played within a time length of 3s, the maximum amplitude value and the minimum amplitude value obtained by corresponding to a plurality of amplitude values in the audio information are recorded, and the difference between the maximum amplitude value and the minimum amplitude value is determined as the amplitude difference of the audio information with the preset length.
In one embodiment, the audio information is determined once every predetermined time (e.g., 1s, 3s, or 10s) when the audio source is detected to play, or in real time, the amplitude of each frame of the audio information is determined, and the amplitude difference is determined when the predetermined length is reached. Specifically, the acquiring the audio information of the sound source includes: the acquiring the audio information of the preset length of the sound source comprises: acquiring audio frame information of the sound source with a preset length; correspondingly, the determining the amplitude difference in the audio information with the preset length includes: and determining the amplitude difference in the audio information with the preset length according to the audio frame information. Illustratively, when a sound source playing is detected, the sound source file is analyzed to obtain a sequence of audio frames, and a corresponding amplitude is determined for each frame under the audio information with a preset length, so as to determine an amplitude difference.
And step S103, judging whether the amplitude difference meets a preset condition, if so, executing step S104, and otherwise, executing step S105.
In one embodiment, the amplitude difference satisfying the preset condition includes: the amplitude difference is greater than a preset amplitude difference. An exemplary such preset amplitude difference may be 0.2 db. When the amplitude difference is larger, the difference between the highest volume and the lowest volume of sound is larger when the sound source plays, so that a user can hear the sound with larger fluctuation and more abrupt sound volume.
And step S104, adjusting the amplitude of the sound source.
In one embodiment, said adjusting the amplitude of said audio source comprises: the amplitude of the audio source greater than a first amplitude threshold and less than a second amplitude threshold is adjusted. Wherein the first amplitude threshold is greater than the second amplitude threshold. Illustratively, the magnitude of the first amplitude threshold may be-2 db, and the magnitude of the second preset amplitude may be-30 db.
In one embodiment, the amplitude adjustment may be performed by using a uniform amplitude adjustment coefficient or by specifically assigning different amplitude adjustment coefficients according to the amplitude to adjust the amplitude of the sound source. Optionally, after determining that the sound source meets the adjustment condition, modifying data representing amplitude information in the obtained audio data by analyzing the sound source file, and encapsulating the modified data after the modification is completed, wherein the amplitude of the sound source is correspondingly increased when the corresponding sound source file is buffered and played; in the process of decoding the sound source playing, the obtained digital audio signal is analyzed to obtain amplitude data, and the amplitude data is multiplied by the corresponding adjusting coefficient to change the amplitude, so as to adjust the volume of the sound source. Therefore, the volume of the sound source is adjusted on the premise that the original volume of the terminal equipment system is not changed, the adjustment process can be carried out before the sound source file does not enter the buffer area so as to reduce the playing load, and the adjustment process can also be carried out aiming at the sound source content in the buffer area so as to improve the adjustment efficiency.
In another embodiment, the amplitude of each frame of the audio source is adjusted. Specifically, in the adjustment process, different amplitude adjustment coefficients are allocated for different amplitude sizes of each frame to perform corresponding adjustment, and for example, the specific correspondence relationship may be as shown in the following table:
TABLE 1
Amplitude of vibration Coefficient of regulation
Greater than-3 db or less than-50 db 1
Less than-10 db and greater than-50 db 2
Less than-3 db and greater than-10 db 1.5
As shown in Table 1, when the amplitude of an audio frame is greater than-3 db or less than-50 db, its gain is not adjusted; when the amplitude is less than-10 db and greater than-50 db, the amplitude is a high amplitude region to which a gain coefficient of 1.5 is assigned, and when the amplitude is less than-10 db and greater than-50 db, the amplitude is a medium amplitude region to which an amplitude coefficient of 2 is assigned to significantly increase the amplitude of the portion of the amplitude.
And step S105, ending.
According to the content, when the amplitude difference of the sound source meets the preset condition, the amplitude of the sound source is adjusted, so that the sound is not suddenly loud or loud in the playing process of the sound source, and the consistency of volume output is ensured.
In one possible embodiment, determining the amplitude difference in the preset length of audio information comprises: determining an average amplitude difference in the audio information of the preset length; if the amplitude difference satisfies a preset condition, adjusting the amplitude of the sound source comprises: and if the average amplitude difference meets a preset condition, adjusting the amplitude of the sound source.
Fig. 2 is a flowchart of another volume adjustment method according to an embodiment of the present invention, where optionally, adjusting the amplitude of the sound source includes: the amplitude greater than the first amplitude threshold is adjusted to a first amplitude and the amplitude less than the second amplitude threshold is adjusted to a second amplitude. The adjusting the amplitude less than the second amplitude threshold to the second amplitude comprises: the amplitude less than the second amplitude threshold and greater than the third amplitude threshold is adjusted to a second amplitude. As shown in fig. 2, the scheme is as follows:
step S201, when detecting that the terminal equipment plays the sound source, acquiring audio information with a preset length of the sound source, and determining an amplitude difference in the audio information with the preset length.
Step S202, judging whether the amplitude difference meets a preset condition, and if so, executing step S203.
Step S203, determining whether the amplitude of the sound source is greater than a first preset amplitude threshold, if so, executing step S204, and if not, executing step S205. Illustratively, the first preset amplitude threshold may be-2 db.
Step S204, the amplitude is adjusted to the first amplitude. Illustratively, the first amplitude may be any value from-4 db to-10 db.
Step S205, determining whether the amplitude of the sound source is smaller than a second preset amplitude threshold, if so, executing step S206, and if not, executing step S208. Illustratively, the second preset amplitude threshold may be-30 db.
Step S206, judging whether the amplitude of the sound source is larger than a third preset amplitude threshold value, if so, executing step S207, and if not, executing step S208. Illustratively, the third preset amplitude threshold may be-50 db.
Step S207, the amplitude is adjusted to the second amplitude. Illustratively, the magnitude of the second amplitude may be-20 db.
And step S308, ending.
Therefore, in the process of adjusting the amplitude of the sound source, the amplitude meeting the adjusting condition is adjusted to a fixed amplitude interval, the amplitude adjusting efficiency is improved, meanwhile, the amplitude information corresponding to the noise is not adjusted, and the problem that the noise is synchronously amplified and then the playing quality of the sound source is influenced is solved.
Fig. 3 is a flowchart of another volume adjustment method according to an embodiment of the present invention, and optionally, after adjusting the amplitude, the method further includes: determining corresponding volume adjustment information according to the amplitude of the sound source; and adjusting the current volume of the terminal equipment according to the volume adjustment information. As shown in fig. 3, includes:
step S301, when detecting that the terminal equipment plays the sound source, acquiring audio information of the sound source with the preset length.
And step S302, determining the amplitude difference in the audio information with the preset length.
And step S303, if the amplitude difference meets a preset condition, adjusting the amplitude of the sound source.
Step S304, determining corresponding volume adjustment information according to the amplitude of the sound source, and adjusting the current volume of the terminal equipment according to the volume adjustment information.
In one embodiment, the corresponding volume adjustment information is determined based on the amplitude of the audio source. Illustratively, when the amplitude of the sound source is small (e.g., -40db), the corresponding volume up information is determined, and when the amplitude of the sound source is large (e.g., 0db), the corresponding volume down information is determined. Specifically, in one embodiment, the volume increase or volume decrease information is the corresponding target volume value. Illustratively, the terminal device is divided into 18 adjustable levels from mute to maximum volume, each level corresponds to a volume value, the target volume value corresponding to the volume reduction information may be 3 or 4, the target volume value corresponding to the volume increase information may be 14 or 15, when the determined amplitude of the sound source is smaller, the volume value is correspondingly increased to 14 or 15, and when the determined amplitude of the sound source is larger, the volume value is correspondingly reduced to 3 or 4. In another embodiment, the volume up or volume down information is a corresponding volume change value. Illustratively, the terminal device is divided into 18 adjustable levels from mute to maximum volume, each level corresponds to a volume value, the volume change values corresponding to the volume increasing information and the volume decreasing information are 3, for example, the volume value of the current terminal device is 10, when the volume information needs to be increased, 3 is increased on the basis of the current volume value, that is, 13 th level volume is adopted for sound playing, and when the volume information needs to be decreased, 3 is decreased on the basis of the current volume value, that is, 7 th level volume is adopted for sound playing. Optionally, before adjusting the volume of the terminal device, the method further includes: and determining the playing time of the sound source, and if the playing time is greater than the preset time, adopting a mode of adjusting the current volume value of the terminal equipment according to the volume change value in the volume increasing information or the volume decreasing information, so that the volume adjusting efficiency is further improved, and the energy consumption of the terminal equipment is reduced.
Fig. 4 is a block diagram of a volume adjusting apparatus according to an embodiment of the present invention, where the apparatus is configured to execute the volume adjusting method according to the embodiment of the present invention, and has corresponding functional modules and beneficial effects of the execution method. As shown in fig. 4, the apparatus specifically includes: an acquisition module 101, an amplitude determination module 102 and an adjustment module 103.
The obtaining module 101 is configured to obtain audio information of a preset length of a sound source when it is detected that the terminal device plays the sound source.
The terminal equipment can play the sound source through the installed third-party application program or the audio and video playing software carried by the system. The method mainly comprises the steps of obtaining, decoding, outputting and the like of the sound source file. Illustratively, the obtained sound source file may be a multicast stream received through a network, or may be an audio/video file locally stored by the terminal device; loading the sound source file into a memory buffer area after the sound source file is obtained; the method comprises the steps of decoding a sound source file loaded into a memory buffer area, before decoding starts, if the sound source file simultaneously contains video data, separating the audio data from the video data, and inputting the separated audio data into an audio decoder, wherein the audio decoder is mainly used for reading the audio data in the memory buffer area to obtain a digital audio signal and converting the digital audio signal into an analog audio signal, and a playing device of a terminal device plays audio according to the analog audio signal. In one embodiment, when it is monitored that a sound source playing event is triggered, it is determined that the terminal device starts playing a sound source, where the triggering event may be that a playing button displayed in a touch screen is pressed, or that a playing device of the terminal device, such as a speaker, starts playing sound, and the terminal device is determined to play the sound source.
And when detecting that the terminal equipment plays the sound source, acquiring audio information of the sound source with the preset length. In one embodiment, the digital audio signal decoded by the audio decoder may be sampled to determine the audio information corresponding to the sound source, where the preset length may be 3s, 5s, 10s, or the like. In another embodiment, an original file of a currently played sound source may also be obtained, and audio information with a preset length corresponding to the sound source may be determined through parsing of the original file. In another embodiment, for example, in an Android system, the audio information of the sound source may be obtained through an Android.
An amplitude determining module 102, configured to determine an amplitude difference in the audio information with the preset length.
The amplitude refers to the maximum distance from the original position in the vibration process of the object, the loudness of the sound heard by human ears is related to the amplitude of the sound source, and the loudness is stronger when the amplitude is larger. In one embodiment, the digital audio signal decoded by the audio decoder may be sampled to obtain amplitude information, wherein the amplitude information may be composed of a plurality of amplitude values, and the amplitude difference may be determined accordingly according to the obtained plurality of amplitude values. For example, taking 3s as an example, in a sound source played within a time length of 3s, the maximum amplitude value and the minimum amplitude value obtained by corresponding to a plurality of amplitude values in the audio information are recorded, and the difference between the maximum amplitude value and the minimum amplitude value is determined as the amplitude difference of the audio information with the preset length.
In one embodiment, the audio information is determined once every predetermined time (e.g., 1s, 3s, or 10s) when the audio source is detected to play, or in real time, the amplitude of each frame of the audio information is determined, and the amplitude difference is determined when the predetermined length is reached. Specifically, the acquiring the audio information of the sound source includes: the acquiring the audio information of the preset length of the sound source comprises: acquiring audio frame information of the sound source with a preset length; correspondingly, the determining the amplitude difference in the audio information with the preset length includes: and determining the amplitude difference in the audio information with the preset length according to the audio frame information. Illustratively, when a sound source playing is detected, the sound source file is analyzed to obtain a sequence of audio frames, and a corresponding amplitude is determined for each frame under the audio information with a preset length, so as to determine an amplitude difference.
An adjusting module 103, configured to adjust the amplitude of the sound source if the amplitude difference satisfies a preset condition.
In one embodiment, the amplitude difference satisfying the preset condition includes: the amplitude difference is greater than a preset amplitude difference. An exemplary such preset amplitude difference may be 0.2 db. When the amplitude difference is larger, the difference between the highest volume and the lowest volume of sound is larger when the sound source plays, so that a user can hear the sound with larger fluctuation and more abrupt sound volume. In one embodiment, said adjusting the amplitude of said audio source comprises: the amplitude of the audio source greater than a first amplitude threshold and less than a second amplitude threshold is adjusted. Wherein the first amplitude threshold is greater than the second amplitude threshold. Illustratively, the magnitude of the first amplitude threshold may be-2 db, and the magnitude of the second preset amplitude may be-30 db.
In one embodiment, the amplitude adjustment may be performed by using a uniform amplitude adjustment coefficient or by specifically assigning different amplitude adjustment coefficients according to the amplitude to adjust the amplitude of the sound source. Optionally, after determining that the sound source meets the adjustment condition, modifying data representing amplitude information in the obtained audio data by analyzing the sound source file, and encapsulating the modified data after the modification is completed, wherein the amplitude of the sound source is correspondingly increased when the corresponding sound source file is buffered and played; in the process of decoding the sound source playing, the obtained digital audio signal is analyzed to obtain amplitude data, and the amplitude data is multiplied by the corresponding adjusting coefficient to change the amplitude, so as to adjust the volume of the sound source. Therefore, the volume of the sound source is adjusted on the premise that the original volume of the terminal equipment system is not changed, the adjustment process can be carried out before the sound source file does not enter the buffer area so as to reduce the playing load, and the adjustment process can also be carried out aiming at the sound source content in the buffer area so as to improve the adjustment efficiency.
According to the method, when the terminal equipment is detected to play the sound source, the audio information with the preset length of the sound source is obtained; determining an amplitude difference in the audio information of the preset length; and if the amplitude difference meets a preset condition, adjusting the amplitude of the sound source. According to the scheme, the volume adjusting efficiency is improved, and the power consumption of the terminal equipment is reduced.
In one possible embodiment, the amplitude difference satisfying the preset condition includes:
the amplitude difference is greater than a preset amplitude difference;
the adjusting module 103 is specifically configured to:
the amplitude of the audio source greater than a first amplitude threshold and less than a second amplitude threshold is adjusted.
In a possible embodiment, the obtaining module 101 is specifically configured to:
acquiring audio frame information of the sound source with a preset length;
the amplitude determination module 102 is specifically configured to:
and determining the amplitude difference in the audio information with the preset length according to the audio frame information.
In a possible embodiment, the adjusting module 103 is specifically configured to:
the amplitude of each frame of the audio source is adjusted.
In a possible embodiment, the adjusting module 103 is specifically configured to:
the amplitude greater than the first amplitude threshold is adjusted to a first amplitude and the amplitude less than the second amplitude threshold is adjusted to a second amplitude.
In a possible embodiment, the adjusting module 103 is specifically configured to:
the amplitude less than the second amplitude threshold and greater than the third amplitude threshold is adjusted to a second amplitude.
In one possible embodiment, the adjusting module 103 is further configured to:
after the amplitude is adjusted, determining corresponding volume adjustment information according to the amplitude of the sound source;
and adjusting the current volume of the terminal equipment according to the volume adjustment information.
In this embodiment, a terminal device is provided on the basis of the foregoing embodiments, and fig. 5 is a schematic structural diagram of a terminal device provided in an embodiment of the present invention, as shown in fig. 5, the terminal device 200 includes: memory 201, processor (CPU) 202, peripheral interfaces 203, RF (Radio Frequency) circuitry 205, audio circuitry 206, speaker 211, power management chip 208, input/output (I/O) subsystem 209, touch screen 212, other input/control devices 210, and external port 204, which communicate via one or more communication buses or signal lines 207.
It should be understood that the illustrated terminal device 200 is only one example of a terminal device, and that the terminal device 200 may have more or fewer components than shown in the figures, may combine two or more components, or may have a different configuration of components. The various components shown in the figures may be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and/or application specific integrated circuits.
The following describes in detail the terminal device for rights management of multi-open applications provided in this embodiment, where the terminal device is a smart phone as an example.
A memory 201, the memory 201 being accessible by the CPU202, the peripheral interface 203, and the like, the memory 201 may include high speed random access memory, and may also include non-volatile memory, such as one or more magnetic disk storage devices, flash memory devices, or other volatile solid state storage devices.
A peripherals interface 203, said peripherals interface 203 being able to connect input and output peripherals of the device to the CPU202 and the memory 201.
An I/O subsystem 209, the I/O subsystem 209 may connect input and output peripherals on the device, such as a touch screen 212 and other input/control devices 210, to the peripheral interface 203. The I/O subsystem 209 may include a display controller 2091 and one or more input controllers 2092 for controlling the other input/control devices 210. Where one or more input controllers 2092 receive electrical signals from or transmit electrical signals to other input/control devices 210, the other input/control devices 210 may include physical buttons (push buttons, rocker buttons, etc.), dials, slide switches, joysticks, click wheels. It is noted that the input controller 2092 may be coupled to any one of: a keyboard, an infrared port, a USB interface, and a pointing device such as a mouse.
A touch screen 212, the touch screen 212 being an input interface and an output interface between the user terminal and the user, displaying visual output to the user, which may include graphics, text, icons, video, and the like.
The display controller 2091 within the I/O subsystem 209 receives electrical signals from the touch screen 212 or transmits electrical signals to the touch screen 212. The touch screen 212 detects a contact on the touch screen, and the display controller 2091 converts the detected contact into an interaction with a user interface object displayed on the touch screen 212, i.e., implements a human-computer interaction, and the user interface object displayed on the touch screen 212 may be an icon for running a game, an icon for networking to a corresponding network, etc. It is worth mentioning that the device may also comprise a light mouse, which is a touch sensitive surface that does not show visual output, or an extension of the touch sensitive surface formed by the touch screen.
The RF circuit 205 is mainly used to establish communication between the mobile phone and the wireless network (i.e., network side), and implement data reception and transmission between the mobile phone and the wireless network. Such as sending and receiving short messages, e-mails, etc. In particular, the RF circuitry 205 receives and transmits RF signals, also referred to as electromagnetic signals, through which the RF circuitry 205 converts electrical signals to or from electromagnetic signals and communicates with communication networks and other devices. RF circuitry 205 may include known circuitry for performing these functions including, but not limited to, an antenna system, an RF transceiver, one or more amplifiers, a tuner, one or more oscillators, a digital signal processor, a CODEC (CODEC) chipset, a Subscriber Identity Module (SIM), and so forth.
The audio circuit 206 is mainly used to receive audio data from the peripheral interface 203, convert the audio data into an electric signal, and transmit the electric signal to the speaker 211.
And a speaker 211 for reproducing the voice signal received by the handset from the wireless network through the RF circuit 205 into sound and playing the sound to the user.
And the power management chip 208 is used for supplying power and managing power to the hardware connected with the CPU202, the I/O subsystem and the peripheral interface.
The volume adjusting device of the terminal device and the terminal device provided in the above embodiments can execute the volume adjusting method of the terminal device provided in any embodiment of the present invention, and have corresponding functional modules and beneficial effects for executing the method. For details of the technology not described in detail in the above embodiments, reference may be made to a volume adjustment method of a terminal device provided in any embodiment of the present invention.
An embodiment of the present invention further provides a storage medium containing terminal device executable instructions, where the terminal device executable instructions are executed by a terminal device processor to perform a volume adjustment method, and the method includes:
after the target application program is monitored to be started, calling a view control to display a preset graph in a movable window interface displayed by a touch screen, wherein the target application program comprises an application program which displays characters in the interface;
after the preset graph is selected, controlling the preset graph to move according to the detected sliding operation, and acquiring characters in the area where the preset graph is located when the preset graph is moved;
and inquiring the acquired characters.
In one possible embodiment, the amplitude difference satisfying the preset condition includes:
the amplitude difference is greater than a preset amplitude difference;
correspondingly, the adjusting the amplitude of the sound source comprises:
the amplitude of the audio source is adjusted to be greater than a first amplitude threshold and less than a second amplitude threshold.
In a possible embodiment, the obtaining the audio information of the preset length of the audio source includes:
acquiring audio frame information of the sound source with a preset length;
correspondingly, the determining the amplitude difference in the audio information with the preset length comprises:
and determining the amplitude difference in the audio information with the preset length according to the audio frame information.
In one possible embodiment, the adjusting the amplitude of the audio source comprises:
the amplitude of each frame of the audio source is adjusted.
In one possible embodiment, adjusting the amplitude of the audio source comprises:
the amplitude greater than the first amplitude threshold is adjusted to a first amplitude and the amplitude less than the second amplitude threshold is adjusted to a second amplitude.
In one possible embodiment, the adjusting the amplitude smaller than the second amplitude threshold to the second amplitude includes:
the amplitude less than the second amplitude threshold and greater than the third amplitude threshold is adjusted to a second amplitude.
In a possible embodiment, after adjusting the magnitude of the amplitude, the method further includes:
determining corresponding volume adjustment information according to the amplitude of the sound source;
and adjusting the current volume of the terminal equipment according to the volume adjustment information.
Storage medium-any of various types of memory devices or storage devices. The term "storage medium" is intended to include: mounting media such as CD-ROM, floppy disk, or tape devices; computer system memory or random access memory such as DRAM, DDR RAM, SRAM, EDO RAM, Lanbas (Rambus) RAM, etc.; non-volatile memory such as flash memory, magnetic media (e.g., hard disk or optical storage); registers or other similar types of memory elements, etc. The storage medium may also include other types of memory or combinations thereof. In addition, the storage medium may be located in a first computer system in which the program is executed, or may be located in a different second computer system connected to the first computer system through a network (such as the internet). The second computer system may provide program instructions to the first computer for execution. The term "storage medium" may include two or more storage media that may reside in different locations, such as in different computer systems that are connected by a network. The storage medium may store program instructions (e.g., embodied as a computer program) that are executable by one or more processors.
Of course, the storage medium provided by the embodiment of the present invention contains computer-executable instructions, and the computer-executable instructions are not limited to the operations of the volume adjustment method described above, and may also perform related operations in the volume adjustment method provided by any embodiment of the present invention.
It is to be noted that the foregoing description is only exemplary of the invention and that the principles of the technology may be employed. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, although the present invention has been described in greater detail by the above embodiments, the present invention is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present invention, and the scope of the present invention is determined by the scope of the appended claims.

Claims (7)

1. A method of adjusting volume, comprising:
when detecting that the terminal equipment plays a sound source, acquiring audio frame information with a preset length of the sound source;
determining an amplitude difference in the audio information with the preset length according to the audio frame information, wherein the amplitude difference is the difference between the maximum amplitude value and the minimum amplitude value in the audio information with the preset length;
if the amplitude difference meets a preset condition, adjusting the amplitude of each frame of the sound source so as to adjust the output volume of the sound source; determining corresponding amplitude adjustment coefficients for the amplitude of the sound source according to different areas where the amplitude is located, and adjusting the amplitude adjustment coefficients;
determining corresponding volume adjustment information according to the amplitude of the sound source;
adjusting the current volume of the terminal equipment according to the volume adjustment information;
before adjusting the current volume of the terminal device, the method further comprises the following steps: and determining the playing time of the sound source, and adjusting the current volume value of the terminal equipment by adopting the volume change value according to the volume increasing information or the volume decreasing information when the playing time is greater than the preset time.
2. The method of claim 1, wherein the amplitude difference satisfying a predetermined condition comprises:
the amplitude difference is greater than a preset amplitude difference;
correspondingly, the adjusting the amplitude of the sound source comprises:
the amplitude of the audio source greater than a first amplitude threshold and less than a second amplitude threshold is adjusted.
3. The method of any of claims 1-2, wherein adjusting the amplitude of the audio source comprises:
the amplitude greater than the first amplitude threshold is adjusted to a first amplitude and the amplitude less than the second amplitude threshold is adjusted to a second amplitude.
4. The method of claim 3, wherein adjusting the amplitude less than the second amplitude threshold to the second amplitude comprises:
the amplitude less than the second amplitude threshold and greater than the third amplitude threshold is adjusted to a second amplitude.
5. A volume adjustment device, comprising:
the acquisition module is used for acquiring audio frame information with a preset length of a sound source when the terminal equipment is detected to play the sound source;
an amplitude determining module, configured to determine, according to the audio frame information, an amplitude difference in the audio information of the preset length, where the amplitude difference is a difference between a maximum amplitude value and a minimum amplitude value in the audio information of the preset length;
the adjusting module is used for adjusting the amplitude of each frame of the sound source if the amplitude difference meets a preset condition so as to adjust the output volume of the sound source; determining corresponding amplitude adjustment coefficients for the amplitude of the sound source according to different areas where the amplitude is located, and adjusting the amplitude adjustment coefficients;
the adjustment module is further configured to:
after the amplitude is adjusted, determining corresponding volume adjustment information according to the amplitude of the sound source;
adjusting the current volume of the terminal equipment according to the volume adjustment information;
before adjusting the current volume of the terminal device, the method further comprises the following steps: and determining the playing time of the sound source, and adjusting the current volume value of the terminal equipment by adopting the volume change value according to the volume increasing information or the volume decreasing information when the playing time is greater than the preset time.
6. A terminal device, comprising: processor, memory and computer program stored on the memory and executable on the processor, characterized in that the processor implements the volume adjustment method according to any one of claims 1 to 4 when executing the computer program.
7. A storage medium containing terminal device-executable instructions, which when executed by a terminal device processor, are configured to perform the volume adjustment method of any one of claims 1-4.
CN201710711363.XA 2017-08-18 2017-08-18 Volume adjusting method and device, terminal equipment and storage medium Active CN107506168B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710711363.XA CN107506168B (en) 2017-08-18 2017-08-18 Volume adjusting method and device, terminal equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710711363.XA CN107506168B (en) 2017-08-18 2017-08-18 Volume adjusting method and device, terminal equipment and storage medium

Publications (2)

Publication Number Publication Date
CN107506168A CN107506168A (en) 2017-12-22
CN107506168B true CN107506168B (en) 2022-06-14

Family

ID=60691109

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710711363.XA Active CN107506168B (en) 2017-08-18 2017-08-18 Volume adjusting method and device, terminal equipment and storage medium

Country Status (1)

Country Link
CN (1) CN107506168B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109408025B (en) * 2018-10-25 2021-10-22 北京小米移动软件有限公司 Audio playing method, device and storage medium
CN113986187A (en) * 2018-12-28 2022-01-28 阿波罗智联(北京)科技有限公司 Method and device for acquiring range amplitude, electronic equipment and storage medium
CN110062309B (en) * 2019-04-28 2021-04-27 百度在线网络技术(北京)有限公司 Method and device for controlling intelligent loudspeaker box

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1929298A (en) * 2005-09-07 2007-03-14 鸿富锦精密工业(深圳)有限公司 Audio frequency processing system and method
JP2011015266A (en) * 2009-07-03 2011-01-20 Panasonic Corp Sound-volume adjusting device
CN103746668A (en) * 2013-12-31 2014-04-23 上海斐讯数据通信技术有限公司 Sound volume control method and system
CN104410379A (en) * 2014-10-29 2015-03-11 深圳市金立通信设备有限公司 A volume adjusting method
CN104486668A (en) * 2014-11-20 2015-04-01 深圳市金立通信设备有限公司 Volume adjustment method
WO2016029688A1 (en) * 2014-08-29 2016-03-03 中兴通讯股份有限公司 Automatic volume adjusting method and electronic device thereof

Family Cites Families (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102104822A (en) * 2009-12-18 2011-06-22 新唐科技股份有限公司 Audio frequency adjusting system and method
US20140115468A1 (en) * 2012-10-24 2014-04-24 Benjamin Guerrero Graphical user interface for mixing audio using spatial and temporal organization
CN103929140A (en) * 2014-04-30 2014-07-16 深圳市中兴移动通信有限公司 Method and device for pre-processing voice frequency
FR3030074B1 (en) * 2014-12-16 2017-01-27 Devialet METHOD FOR CONTROLLING AN OPERATING PARAMETER OF AN ACOUSTIC INSTALLATION
CN105262452A (en) * 2015-10-29 2016-01-20 小米科技有限责任公司 Method and apparatus for adjusting volume, and terminal
CN105828254B (en) * 2016-05-09 2019-04-12 青岛海信电器股份有限公司 A kind of voice frequency regulating method and device
CN105812586B (en) * 2016-06-01 2019-05-17 维沃移动通信有限公司 Quickly mute method and mobile terminal
CN106126164B (en) * 2016-06-16 2019-05-17 Oppo广东移动通信有限公司 A kind of sound effect treatment method and terminal device
CN106126170B (en) * 2016-06-16 2020-01-14 Oppo广东移动通信有限公司 Sound effect setting method of terminal and terminal
CN106024007B (en) * 2016-06-21 2019-10-15 维沃移动通信有限公司 A kind of sound processing method and mobile terminal
CN106775563A (en) * 2016-12-13 2017-05-31 珠海市魅族科技有限公司 The method and device of volume adjusting

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1929298A (en) * 2005-09-07 2007-03-14 鸿富锦精密工业(深圳)有限公司 Audio frequency processing system and method
JP2011015266A (en) * 2009-07-03 2011-01-20 Panasonic Corp Sound-volume adjusting device
CN103746668A (en) * 2013-12-31 2014-04-23 上海斐讯数据通信技术有限公司 Sound volume control method and system
WO2016029688A1 (en) * 2014-08-29 2016-03-03 中兴通讯股份有限公司 Automatic volume adjusting method and electronic device thereof
CN104410379A (en) * 2014-10-29 2015-03-11 深圳市金立通信设备有限公司 A volume adjusting method
CN104486668A (en) * 2014-11-20 2015-04-01 深圳市金立通信设备有限公司 Volume adjustment method

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Fedar Severin ; Aryaz Baradarani.Auto-adjustment of image produced by multi-transducer ultrasonic system.《2014 IEEE International Ultrasonics Symposium》.2014,第1944-1947页. *
扬声器谐振频率测量系统的开发;李佳;《中国优秀博硕士学位论文全文数据库(硕士)信息科技辑》;20121015;第I135-448页 *

Also Published As

Publication number Publication date
CN107506168A (en) 2017-12-22

Similar Documents

Publication Publication Date Title
CN107566618B (en) Volume adjusting method and device, terminal equipment and storage medium
US11251763B2 (en) Audio signal adjustment method, storage medium, and terminal
CN107465824B (en) Volume adjusting method and device, mobile terminal and storage medium
CN111033614B (en) Volume adjusting method and device, mobile terminal and storage medium
CN108810749B (en) Player control method, device, terminal equipment and storage medium
US10440464B2 (en) Method and apparatus for adjusting volume, terminal device and storage medium
CN106791067B (en) Call volume adjusting method and device and mobile terminal
CN107526570B (en) Volume adjusting method and device, terminal equipment and storage medium
CN107506168B (en) Volume adjusting method and device, terminal equipment and storage medium
CN106713653B (en) Audio and video playing control method and device and terminal
CN107483734B (en) Volume adjusting method and device, terminal equipment and storage medium
WO2019033941A1 (en) Volume adjustment method and apparatus, terminal device, and storage medium
CN110799936A (en) Volume adjusting method and device, terminal equipment and storage medium
WO2019033942A1 (en) Volume adjustment method and apparatus, terminal device, and storage medium
WO2023131155A1 (en) Wireless earphone control method and apparatus, and electronic device
WO2019033939A1 (en) Volume adjustment method and apparatus, terminal device, and storage medium
CN106293607B (en) Method and system for automatically switching audio output modes
CN110753919A (en) Volume adjusting method and device, storage medium and mobile terminal
CN113660599A (en) Loudspeaker control method and device, mobile terminal and storage medium
CN107506170A (en) volume adjusting method, device, terminal device and storage medium
CN110731087A (en) Volume adjusting method and device, mobile terminal and storage medium
CN107506169A (en) volume adjusting method, device, terminal device and storage medium

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
CB02 Change of applicant information
CB02 Change of applicant information

Address after: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Applicant after: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd.

Address before: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Applicant before: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd.

GR01 Patent grant
GR01 Patent grant