Audio playback volume adjustment method, device and storage medium
By determining and adjusting the maximum volume level at the frame level for audio data, the problem of nonlinear distortion when amplifying audio data in audio playback equipment is solved, the audio playback effect and echo cancellation effect are improved, and a smooth transition of volume is achieved.
Patent Information
- Application Number
- CN202011000696.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-09-22
- Publication Date
- 2024-09-03
- Estimated Expiration
- 2040-09-22
AI Technical Summary
Existing audio playback equipment is prone to nonlinear distortion after amplifying audio data, resulting in poor echo cancellation and affecting the audio playback effect.
By determining the maximum volume level without distortion for each frame of audio data, and adjusting the playback volume according to the volume level setting value to ensure that the audio data is not distorted when amplifying, the preset volume level interval value is adjusted frame by frame to achieve volume control. Smooth transitions.
It solves the cutoff distortion problem when amplifying the overall audio file, ensuring that the amplified audio data is not distorted, improving the echo cancellation and audio playback effects, and achieving a smooth transition of volume.
Smart Images

Figure CN112185414B
Abstract
Description
Technical Field
[0001] The present application relates to a method, device and storage medium for adjusting audio playback volume, and belongs to the technical field of signal processing. Background Art
[0002] Users usually use audio playback devices to play audio. After the audio is decoded, in order to hear the content clearly, the user will adjust the audio to a suitable volume, for example, by adjusting the volume of the playback device to adjust the audio volume, or by adjusting the volume of the software player to adjust the audio volume.
[0003] The existing method of adjusting the audio playback volume is to amplify the audio data as a whole. For scenarios where the audio played by the audio playback device needs to be re-collected, such as: audio and video conferences, speaking to smart speakers during audio playback, etc., the audio played by the audio playback device needs to be echo-cancelled. That is, the re-collected audio is filtered out through the echo cancellation algorithm to obtain the user voice signal.
[0004] At this time, if the audio data is processed by the signal amplifier of the audio playback device and nonlinear distortion occurs, the pickup device will collect distorted data again, which is different from the original audio reference signal played, and the echo cancellation effect is poor, affecting the audio playback effect. Summary of the invention
[0005] The present application provides a method, device and storage medium for adjusting the volume of audio playback, which can solve the problem of cutoff distortion that easily occurs when the audio file is amplified as a whole. The present application provides the following technical solutions:
[0006] In a first aspect, a method for adjusting audio playback volume is provided, the method comprising:
[0007] For each frame of audio data in the audio file, determining a maximum volume level of the audio data under a non-distortion condition;
[0008] Get the volume level setting value of the audio file;
[0009] When the volume level setting value is greater than the maximum volume level, the playback volume of the audio data is adjusted according to the maximum volume level.
[0010] Optionally, for each frame of audio data in the audio file, determining the maximum volume level of the audio data without distortion includes:
[0011] Obtaining a maximum value of samples in the audio data;
[0012] Obtain the sample threshold under undistorted conditions;
[0013] The volume level maximum value is determined based on the sample maximum value and the sample threshold value.
[0014] Optionally, determining the maximum volume level value based on the sample maximum value and the sample threshold value includes:
[0015] Calculate a first decibel value corresponding to the maximum value of the sample;
[0016] Calculating a second decibel value corresponding to the sample threshold;
[0017] Dividing the difference between the second decibel value and the first decibel value by the decibel interval value to obtain an adjustable volume level value, wherein the decibel interval value refers to the difference between the decibel values corresponding to two adjacent volume levels;
[0018] The sum of a volume level base value corresponding to the original playback volume of the audio data and the volume level adjustable value is determined as the volume level maximum value.
[0019] Optionally, adjusting the playback volume of the audio data according to the maximum volume level includes:
[0020] The preset volume level interval value is adjusted frame by frame based on the volume level usage value of the previous frame of audio data until the volume level usage value is adjusted to the maximum volume level value.
[0021] Optionally, the method further comprises:
[0022] When the volume level setting value is less than or equal to the maximum volume level value, the preset volume level interval value is adjusted frame by frame based on the volume level usage value of the previous frame of audio data until the volume level usage value is adjusted to the volume level setting value.
[0023] Optionally, after obtaining the volume level setting value of the audio file, the method further includes:
[0024] Determining whether the volume level setting value is greater than a volume level base value corresponding to an original playback volume of the audio data;
[0025] When the volume level setting value is greater than the basic level value, the step of adjusting the playback volume of the audio data according to the maximum volume level when the volume level setting value is greater than the maximum volume level is triggered.
[0026] Optionally, the method further comprises:
[0027] When the volume level setting value is less than or equal to the basic level value, the playback volume of the audio data is adjusted according to the volume level setting value.
[0028] Optionally, the method further comprises:
[0029] Get the volume level division method;
[0030] Get the audio quantization range;
[0031] The audio quantization range and the level division method are used to determine a volume level range, and the volume level maximum value and the volume level setting value both belong to the volume level range.
[0032] In a second aspect, a device for adjusting audio playback volume is provided, the device comprising:
[0033] A maximum value determination module, used for determining, for each frame of audio data in the audio file, a maximum volume level of the audio data under a non-distortion condition;
[0034] A setting value acquisition module, used to obtain the volume level setting value of the audio file;
[0035] The volume adjustment module is used to adjust the playback volume of the audio data according to the maximum volume level when the volume level setting value is greater than the maximum volume level.
[0036] In a third aspect, a device for adjusting the audio playback volume is provided, the device comprising a processor and a memory; a program is stored in the memory, and the program is loaded and executed by the processor to implement the audio playback volume adjustment method described in the first aspect.
[0037] In a fourth aspect, a computer-readable storage medium is provided, wherein a program is stored in the storage medium, and the program is loaded and executed by the processor to implement the method for adjusting the audio playback volume described in the first aspect.
[0038] The beneficial effects of the present application are: by determining the maximum volume level of the audio data under non-distortion conditions for each frame of audio data; obtaining the volume level setting value of the audio file; when the volume level setting value is greater than the maximum volume level, adjusting the playback volume of the audio data according to the maximum volume level; the problem of cutoff distortion that is prone to occur when the audio file is amplified as a whole can be solved; since the audio file is processed frame by frame, a frame of audio data that may be distorted is adjusted according to the maximum volume level under non-distortion conditions, it can be ensured that the amplified audio data is not distorted, thereby ensuring the echo cancellation effect and audio playback effect.
[0039] In addition, by adjusting the preset volume level interval value frame by frame when adjusting the audio data, a smooth transition of the audio volume can be achieved.
[0040] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application and implement it according to the contents of the specification, the following is a detailed description of the preferred embodiments of the present application in conjunction with the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 is a flow chart of a method for adjusting audio playback volume provided by an embodiment of the present application;
[0042] Figure 2 is a flow chart of a method for adjusting audio playback volume provided by another embodiment of the present application;
[0043] Figure 3 is a schematic diagram of a waveform of an audio file provided by an embodiment of the present application;
[0044] Figure 4 is a schematic diagram of a waveform of an audio file after being amplified as a whole, provided by an embodiment of the present application;
[0045] Figure 5 is a schematic diagram of a waveform of an audio file after frame-by-frame amplification provided by an embodiment of the present application;
[0046] Figure 6 It is a block diagram of an audio playback volume adjustment device provided by an embodiment of the present application;
[0047] Figure 7 It is a block diagram of an audio playback volume adjustment device provided by an embodiment of the present application. DETAILED DESCRIPTION
[0048] The specific implementation methods of the present application are further described in detail below in conjunction with the accompanying drawings and examples. The following examples are used to illustrate the present application but are not intended to limit the scope of the present application.
[0049] Optionally, the present application uses an electronic device as the execution subject of each embodiment, and the electronic device has an audio volume adjustment function. Schematically, the electronic device executes the audio playback volume adjustment method provided in the present application by calling pre-installed audio playback software (for example, through audio and video conferencing software). Among them, the electronic device can be a video conferencing terminal, a mobile phone, a computer, etc., and this embodiment does not limit the device type of the electronic device.
[0050] Figure 1 This is a flow chart of a method for adjusting the audio playback volume provided by an embodiment of the present application. The method includes at least the following steps:
[0051] Step 101: for each frame of audio data in the audio file, determine the maximum volume level of the audio data under a non-distortion condition.
[0052] After the electronic device obtains the audio file, it decodes the audio file to obtain multiple frames of audio data. For each frame of audio data, the maximum volume level of the audio data without distortion is determined.
[0053] In this embodiment, the volume level range is preset in the electronic device; or, the volume level range is obtained by the electronic device according to the current volume level division method and the audio quantization range. At this time, the electronic device obtains the volume level division method; obtains the audio quantization range; uses the audio quantization range and the level division method to determine the volume level range, and the volume level maximum value and the volume level setting value both belong to the volume level range.
[0054] Among them, the volume level division method is used to indicate the number of volume levels and the lower limit of the volume level range; or, it is used to indicate the number of volume levels and the upper limit of the volume level range; or, the volume level division method is used to indicate the lower limit of the volume level range and the upper limit of the volume level range; this embodiment does not limit the indication method of the volume level division method. For example: the number of volume levels indicated by the volume level division method is 31, and the lower limit of the volume level range is 1, then the obtained levels are the values corresponding to the integers from 1 to 31.
[0055] The audio quantization range is used to indicate the range of the audio volume after quantization. The audio quantization range is related to the number of bits of the audio data encoding. For example, if the audio data is encoded in 16 bits, the audio volume range is [-32768, 32767].
[0056] Determining the volume level range using the audio quantization range and level division method includes: calculating the decibel value range corresponding to the audio volume range; calculating the decibel interval value using the decibel value range and the level, and obtaining the decibel value corresponding to each volume level. The decibel interval value refers to the difference between the decibel values corresponding to two adjacent volume levels.
[0057] Schematically, the conversion relationship between the sample value and decibel value of the audio volume is expressed by the following formula: 20*log10(|SampleVal| / 32768.0). Among them, SampleVal is the sample value of the audio. For example: the range of the audio volume is [-32768, 32767], and the number of volume levels is 31; after converting the volume amplitude into decibel value, it can be obtained that for each increase in level, the volume of the sample increases by 0.8 decibels (dB), that is, the sample amplification is approximately: 1.096478 times. At this time, the sample threshold that can be adjusted is expressed by the following formula:
[0058] THRESHOLD_LIMIT = 32768 / 1.096478 = 29885 (rounded to the nearest decimal point);
[0059] THRESHOLD_LIMIT refers to the value obtained by dividing the maximum value of the sample by the magnification factor of adjusting the volume level. If the maximum value of the sample of a frame of audio data is greater than the sample threshold THRESHOLD_LIMIT that can be adjusted, nonlinear distortion (for example, cutoff distortion) will occur even if it is magnified by one level.
[0060] Based on the above principle, for each frame of audio data in the audio file, the maximum volume level of the audio data under undistorted conditions is determined, including: obtaining the maximum sample value in the audio data; obtaining the sample threshold under undistorted conditions; and determining the maximum volume level based on the sample maximum value and the sample threshold.
[0061] Schematically, the maximum value of the volume level is determined based on the sample maximum value and the sample threshold, including: calculating a first decibel value corresponding to the sample maximum value; calculating a second decibel value corresponding to the sample threshold; dividing the difference between the second decibel value and the first decibel value by a decibel interval value to obtain an adjustable volume level value, wherein the decibel interval value refers to the difference between the decibel values corresponding to two adjacent volume levels; and determining the sum of a volume level base value corresponding to the original playback volume of the audio data and the volume level adjustable value as the maximum value of the volume level.
[0062] The maximum volume level CurFrmMaxUseVolLevel is determined by the following formula:
[0063] CurFrmMaxUseVolLevel = volume level base value + CanAddLev;
[0064] 20log10(dwSampMaxValue / 32768.0)+CanAddLev*x=0
[0065] Among them, CanAddLev is the maximum level that can be increased under the condition of no cutoff distortion;
[0066] dwSampMaxValue is the maximum value of the sample of the current frame of audio data; x is the decibel interval value; the volume level base value is the level value corresponding to the original playback volume, that is, the volume that has not been amplified or reduced. Usually, the volume level base value is the middle value of the volume level upper limit value and the volume level lower limit value. For example: in the volume level from 1 to 31, the 16th level is the volume level base value.
[0067] Step 102: Obtain the volume level setting value of the audio file.
[0068] The volume level setting value may be set by the user, for example, the user adjusts the volume level to level 31.
[0069] Step 103: When the volume level setting value is greater than the maximum volume level, the playback volume of the audio data is adjusted according to the maximum volume level.
[0070] Since the volume level setting value is greater than the maximum volume level, if the playback volume of the audio data is amplified according to the volume level setting value set by the user, the amplified audio data will have a nonlinear distortion problem. Therefore, in this embodiment, by adjusting the playback volume of the audio data according to the maximum volume level, the audio data can be amplified to the maximum extent without distortion, and adaptive amplification of the audio data can be achieved to ensure that the audio data is not distorted after amplification.
[0071] In one example, adjusting the playback volume of audio data according to the maximum volume level includes: adjusting the preset volume level interval value frame by frame based on the volume level usage value of the previous frame of audio data until the volume level usage value is adjusted to the maximum volume level. In this way, the smoothness of the volume adjustment process can be guaranteed.
[0072] Specifically, when the volume level usage value of the previous frame of audio data is greater than the maximum volume level, the volume level interval value is reduced frame by frame based on the volume level usage value of the previous frame of audio data until the volume level usage value is adjusted to the maximum volume level; when the volume level usage value of the previous frame of audio data is less than the maximum volume level, the volume level interval value is increased frame by frame based on the volume level usage value of the previous frame of audio data until the volume level usage value is adjusted to the maximum volume level.
[0073] The volume level interval value may be level 1 or level 2, etc., and this embodiment does not limit the value of the volume level interval value.
[0074] Optionally, the volume level usage value of the first frame of audio data is the same as the volume level setting value.
[0075] For example: the duration of a frame of audio data is 10ms, the volume level usage value of the previous frame of audio data is 18, the maximum volume level is 24, and the volume level interval value is 1. At this time, the electronic device starts to increase by 1 level per frame based on level 18, and after 6 frames, that is, after 60ms, the volume level can be increased to the maximum value.
[0076] Optionally, when the volume level setting value is less than or equal to the maximum volume level, the playback volume of the audio data is adjusted according to the volume level setting value. Specifically, the preset volume level interval value is adjusted frame by frame based on the volume level usage value of the previous frame of audio data until the volume level usage value is adjusted to the volume level setting value.
[0077] Optionally, there is a risk of audio data distortion only when the volume level setting value set by the user exceeds the volume level base value. Therefore, when the volume level setting value does not exceed the volume level base value, the step of adjusting the playback volume of the audio data according to the maximum volume level may not be performed. At this time, after obtaining the volume level setting value of the audio file, it also includes: determining whether the volume level setting value is greater than the volume level base value corresponding to the original playback volume of the audio data; when the volume level setting value is greater than the base level value, executing step 103. When the volume level setting value is less than or equal to the base level value, the playback volume of the audio data is adjusted according to the volume level setting value.
[0078] In order to more clearly understand the method for adjusting the audio playback volume provided by the present application, the method is described below with an example. Figure 2 The process of adjusting the audio playback volume shown in the figure comprises at least steps 21-294;
[0079] Step 21, receiving an audio file, decoding and obtaining multiple frames of audio data, and initializing the volume level of the first frame of audio data to be a volume level setting value;
[0080] Among them, the sample value of multiple frames of audio data refers to Figure 3 As shown;
[0081] Step 22, for each frame of audio data, determine whether the volume level setting value is less than or equal to the volume level base value; if so, execute step 23; if not, execute step 25;
[0082] Step 23, adjusting the playback volume of the current frame of audio data according to the volume level setting value;
[0083] Step 24, playing the adjusted audio data, and executing step 22 again, until all frames of audio data are adjusted, the process ends;
[0084] Step 25, calculating the maximum volume level of the current frame of audio data under the condition of no distortion;
[0085] Step 26, comparing the maximum volume level of the current frame of audio data with the volume level setting value; when the maximum volume level is greater than or equal to the volume level setting value, executing step 27; when the maximum volume level is less than the volume level setting value, executing step 291;
[0086] Step 27, determining whether the volume level usage value of the previous frame of audio data is less than the volume level setting value; if so, executing step 28; if not, executing step 29;
[0087] Step 28, adding a volume level interval value based on the volume level usage value of the previous frame of audio data (for example, taking the volume level interval value as 1 level);
[0088] Step 29, using the current volume level usage value to adjust the playback volume of the current frame of audio data, and executing step 24;
[0089] Step 291, determining whether the volume level usage value of the previous frame of audio data is less than the maximum volume level; if so, executing step 292; if not, executing step 293;
[0090] Step 292, adding the volume level interval value based on the volume level usage value of the previous frame of audio data, and executing step 29;
[0091] Step 293, determining whether the volume level usage value of the previous frame of audio data is greater than the maximum volume level; if so, executing step 294; if not, executing step 29;
[0092] Step 294 , reduce the volume level interval value based on the volume level usage value of the previous frame of audio data, and execute step 29 .
[0093] If you follow the traditional volume adjustment method, Figure 3 The audio data shown is amplified as a whole (for example, amplified by 12dB) to obtain the amplified audio data reference Figure 4 As shown, according to Figure 4 It can be seen that there is a lot of cutoff distortion after the audio data is amplified as a whole. Based on the playback volume adjustment method provided by this application, the amplified audio data obtained is as follows Figure 5 As shown, according to Figure 5 It can be seen that the cutoff distortion is significantly reduced, the small sound is amplified, and the volume is dynamically and smoothly adjusted.
[0094] In summary, the method for adjusting the audio playback volume provided in the present embodiment determines the maximum volume level of the audio data under non-distortion conditions for each frame of audio data; obtains the volume level setting value of the audio file; and when the volume level setting value is greater than the maximum volume level, adjusts the playback volume of the audio data according to the maximum volume level; the problem of cutoff distortion that is prone to occur when the audio file is amplified as a whole can be solved; since the audio file is processed frame by frame, a frame of audio data that may be distorted is adjusted according to the maximum volume level under non-distortion conditions, which can ensure that the amplified audio data is not distorted, thereby ensuring the echo cancellation effect and the audio playback effect.
[0095] In addition, by adjusting the preset volume level interval value frame by frame when adjusting the audio data, a smooth transition of the audio volume can be achieved.
[0096] Figure 6 6 is a block diagram of an audio playback volume adjustment device provided in an embodiment of the present application. The device comprises at least the following modules: a maximum value determination module 610, a setting value acquisition module 620 and a volume adjustment module 630.
[0097] A maximum value determination module 610 is used to determine the maximum volume level of each frame of audio data in the audio file under the condition of no distortion;
[0098] A setting value acquisition module 620, used to acquire a volume level setting value of the audio file;
[0099] The volume adjustment module 630 is configured to adjust the playback volume of the audio data according to the maximum volume level when the volume level setting value is greater than the maximum volume level.
[0100] For relevant details, refer to the above method embodiment.
[0101] It should be noted that: the audio playback volume adjustment device provided in the above embodiment only uses the division of the above functional modules as an example when adjusting the audio playback volume. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the audio playback volume adjustment device is divided into different functional modules to complete all or part of the functions described above. In addition, the audio playback volume adjustment device provided in the above embodiment and the audio playback volume adjustment method embodiment belong to the same concept, and the specific implementation process is detailed in the method embodiment, which will not be repeated here.
[0102] Figure 7 701 is a block diagram of an audio playback volume adjustment device provided in an embodiment of the present application. The device may be: a conference terminal, a smart phone, a tablet computer, a laptop computer, a desktop computer or a server. The audio playback volume adjustment device may also be called a user device, a portable terminal, a laptop terminal, a desktop terminal, a control terminal, etc. This embodiment does not limit the type of the adjustment device. The device includes at least a processor 701 and a memory 702.
[0103] The processor 701 may include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor 701 may be implemented in at least one hardware form of DSP (Digital Signal Processing), FPGA (Field-Programmable Gate Array), and PLA (Programmable Logic Array). The processor 701 may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a CPU (Central Processing Unit); the coprocessor is a low-power processor for processing data in the standby state. In some embodiments, the processor 701 may be integrated with a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, the processor 701 may also include an AI (Artificial Intelligence) processor, which is used to process computing operations related to machine learning.
[0104] The memory 702 may include one or more computer-readable storage media, which may be non-transitory. The memory 702 may also include a high-speed random access memory, and a non-volatile memory, such as one or more disk storage devices, flash memory storage devices. In some embodiments, the non-transitory computer-readable storage medium in the memory 702 is used to store at least one instruction, which is used to be executed by the processor 701 to implement the method for adjusting the audio playback volume provided in the method embodiment of the present application.
[0105] In some embodiments, the audio playback volume adjustment device may also optionally include: a peripheral device interface and at least one peripheral device. The processor 701, the memory 702 and the peripheral device interface may be connected via a bus or a signal line. Each peripheral device may be connected to the peripheral device interface via a bus, a signal line or a circuit board. Schematically, the peripheral devices include but are not limited to: a radio frequency circuit, an audio circuit, and a power supply.
[0106] Of course, the device for adjusting the audio playback volume may also include fewer or more components, which is not limited in this embodiment.
[0107] Optionally, the present application also provides a computer-readable storage medium, in which a program is stored, and the program is loaded and executed by a processor to implement the method for adjusting the audio playback volume of the above method embodiment.
[0108] Optionally, the present application also provides a computer product, which includes a computer-readable storage medium, in which a program is stored, and the program is loaded and executed by a processor to implement the method for adjusting the audio playback volume of the above method embodiment.
[0109] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0110] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.
Claims
1. A method for adjusting audio playback volume, characterized in that: The method comprises: For each frame of audio data in the audio file, determine the maximum volume level of the audio data under the condition of no distortion, the maximum volume level being the sum of the volume level base value corresponding to the original playback volume of the audio data and the volume level adjustable value, the volume level adjustable value being the maximum level that can be increased under the condition of no cutoff distortion; Get the volume level setting value of the audio file; Determine whether the volume level setting value is greater than a volume level base value corresponding to the original playback volume of the audio data, the volume level base value being a level value corresponding to the original playback volume; When the volume level setting value is greater than the volume level base value, the step of adjusting the playback volume of the audio data according to the maximum volume level when the volume level setting value is greater than the volume level maximum value is triggered; when the volume level setting value is greater than the volume level maximum value, adjusting the playback volume of the audio data according to the maximum volume level.
2. The method according to claim 1, characterized in that The step of determining, for each frame of audio data in the audio file, a maximum volume level of the audio data without distortion comprises: Obtaining a maximum value of samples in the audio data; Obtain the sample threshold under undistorted conditions; The volume level maximum value is determined based on the sample maximum value and the sample threshold value.
3. The method according to claim 2, characterized in that The determining the maximum volume level value based on the sample maximum value and the sample threshold value comprises: Calculate a first decibel value corresponding to the maximum value of the sample; Calculating a second decibel value corresponding to the sample threshold; Dividing the difference between the second decibel value and the first decibel value by the decibel interval value to obtain an adjustable volume level value, wherein the decibel interval value refers to the difference between the decibel values corresponding to two adjacent volume levels; The sum of a volume level base value corresponding to the original playback volume of the audio data and the volume level adjustable value is determined as the volume level maximum value.
4. The method according to claim 1, characterized in that: The adjusting the playback volume of the audio data according to the maximum volume level includes: The preset volume level interval value is adjusted frame by frame based on the volume level usage value of the previous frame of audio data until the volume level usage value is adjusted to the maximum volume level value.
5. The method according to claim 1, characterized in that The method further comprises: When the volume level setting value is less than or equal to the maximum volume level value, the preset volume level interval value is adjusted frame by frame based on the volume level usage value of the previous frame of audio data until the volume level usage value is adjusted to the volume level setting value.
6. The method according to claim 1, characterized in that After obtaining the volume level setting value of the audio file, the method further includes: When the volume level setting value is less than or equal to the volume level base value, the playback volume of the audio data is adjusted according to the volume level setting value.
7. The method according to claim 1, characterized in that The method further comprises: Get the volume level division method; Get the audio quantization range; The audio quantization range and the level division method are used to determine a volume level range, and the volume level maximum value and the volume level setting value both belong to the volume level range.
8. A device for adjusting the audio playback volume, characterized in that: The device comprises: A maximum value determination module, for determining, for each frame of audio data in an audio file, a maximum volume level of the audio data under a non-distortion condition, wherein the maximum volume level is the sum of a volume level base value corresponding to the original playback volume of the audio data and an adjustable volume level value, wherein the adjustable volume level value is a maximum level that can be increased under a condition of no cutoff distortion; A setting value acquisition module, used to obtain the volume level setting value of the audio file; A volume adjustment module is used to determine whether the volume level setting value is greater than a volume level base value corresponding to the original playback volume of the audio data, the volume level base value being a level value corresponding to the original playback volume; when the volume level setting value is greater than the volume level base value, trigger the execution of the volume adjustment module's function of adjusting the playback volume of the audio data according to the volume level maximum value when the volume level setting value is greater than the volume level maximum value; and when the volume level setting value is greater than the volume level maximum value, adjust the playback volume of the audio data according to the volume level maximum value.
9. A device for adjusting the volume of audio playback, characterized in that: The device includes a processor and a memory; a program is stored in the memory, and the program is loaded and executed by the processor to implement the method for adjusting the audio playback volume as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: The storage medium stores a program, and when the program is executed by the processor, it is used to implement the method for adjusting the audio playback volume as described in any one of claims 1 to 7.
