CN118233809A - Audio signal processing method, device, electronic device and storage medium - Google Patents
Audio signal processing method, device, electronic device and storage medium Download PDFInfo
- Publication number
- CN118233809A CN118233809A CN202410627193.7A CN202410627193A CN118233809A CN 118233809 A CN118233809 A CN 118233809A CN 202410627193 A CN202410627193 A CN 202410627193A CN 118233809 A CN118233809 A CN 118233809A
- Authority
- CN
- China
- Prior art keywords
- audio signal
- processing
- channel
- audio signals
- right channels
- 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.)
- Granted
Links
- 230000005236 sound signal Effects 0.000 title claims abstract description 452
- 238000003672 processing method Methods 0.000 title claims abstract description 15
- 238000012545 processing Methods 0.000 claims abstract description 267
- 238000000034 method Methods 0.000 claims abstract description 57
- 230000004807 localization Effects 0.000 claims description 40
- 230000007246 mechanism Effects 0.000 claims description 35
- 230000008569 process Effects 0.000 claims description 14
- 230000004044 response Effects 0.000 claims description 7
- 230000000694 effects Effects 0.000 abstract description 22
- 238000004891 communication Methods 0.000 description 19
- 238000010586 diagram Methods 0.000 description 16
- 238000004590 computer program Methods 0.000 description 12
- 238000005516 engineering process Methods 0.000 description 12
- 230000009466 transformation Effects 0.000 description 12
- 238000001514 detection method Methods 0.000 description 11
- 238000005070 sampling Methods 0.000 description 6
- 238000000844 transformation Methods 0.000 description 6
- 230000008859 change Effects 0.000 description 5
- 230000003287 optical effect Effects 0.000 description 5
- 101100233916 Saccharomyces cerevisiae (strain ATCC 204508 / S288c) KAR5 gene Proteins 0.000 description 4
- 230000009471 action Effects 0.000 description 4
- 238000004364 calculation method Methods 0.000 description 3
- 230000007423 decrease Effects 0.000 description 3
- 238000007726 management method Methods 0.000 description 3
- 238000001228 spectrum Methods 0.000 description 3
- 230000001133 acceleration Effects 0.000 description 2
- 230000003321 amplification Effects 0.000 description 2
- 238000013500 data storage Methods 0.000 description 2
- 238000001914 filtration Methods 0.000 description 2
- 230000006870 function Effects 0.000 description 2
- 230000006872 improvement Effects 0.000 description 2
- 230000003993 interaction Effects 0.000 description 2
- 238000003199 nucleic acid amplification method Methods 0.000 description 2
- 230000002093 peripheral effect Effects 0.000 description 2
- 101000827703 Homo sapiens Polyphosphoinositide phosphatase Proteins 0.000 description 1
- 102100023591 Polyphosphoinositide phosphatase Human genes 0.000 description 1
- 230000006978 adaptation Effects 0.000 description 1
- 238000003491 array Methods 0.000 description 1
- 238000013473 artificial intelligence Methods 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000010276 construction Methods 0.000 description 1
- 230000003247 decreasing effect Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 210000005069 ears Anatomy 0.000 description 1
- 239000000284 extract Substances 0.000 description 1
- 230000005669 field effect Effects 0.000 description 1
- 238000003384 imaging method Methods 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 239000000203 mixture Substances 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012827 research and development Methods 0.000 description 1
- 238000005316 response function Methods 0.000 description 1
- 238000004088 simulation Methods 0.000 description 1
- 230000003068 static effect Effects 0.000 description 1
- 238000012546 transfer Methods 0.000 description 1
- 230000001131 transforming effect Effects 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04R—LOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
- H04R3/00—Circuits for transducers, loudspeakers or microphones
- H04R3/12—Circuits for transducers, loudspeakers or microphones for distributing signals to two or more loudspeakers
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04R—LOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
- H04R2430/00—Signal processing covered by H04R, not provided for in its groups
Landscapes
- Health & Medical Sciences (AREA)
- General Health & Medical Sciences (AREA)
- Otolaryngology (AREA)
- Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Acoustics & Sound (AREA)
- Signal Processing (AREA)
- Stereophonic System (AREA)
Abstract
Description
技术领域Technical Field
本发明涉及信号处理技术,尤其涉及一种音频信号处理方法、装置、电子设备及计算机可读存储介质。The present invention relates to signal processing technology, and in particular to an audio signal processing method, device, electronic device and computer-readable storage medium.
背景技术Background technique
随着汽车工业的迅猛发展和人们的生活水平的不断提高,汽车也逐步成为人们日常生活中不可缺少的交通工具。而随着汽车的品牌也越来越多,消费者对自身消费品质也越来越高,所以,很多车辆企业也开始注重于车内的驾驶体验与舒适感,而车辆舒适度的提升除了车辆本身的硬件配置外,车内的音效也是提升的一大环节。With the rapid development of the automobile industry and the continuous improvement of people's living standards, cars have gradually become an indispensable means of transportation in people's daily lives. With the increasing number of automobile brands, consumers are increasingly demanding on the quality of their own consumption. Therefore, many automobile companies have begun to focus on the driving experience and comfort in the car. In addition to the hardware configuration of the vehicle itself, the sound effect in the car is also a major part of improving the comfort of the vehicle.
相关技术中,为了提高车内音质音效,则需要投入大量的资金来研发或者外购音效算法,这无疑增加了成本。In the related technology, in order to improve the sound quality and sound effects in the car, a large amount of money needs to be invested in the research and development or purchase of sound effect algorithms, which undoubtedly increases the cost.
因此,如何在低成本的前提下,有效提高车内音效,是目前有待解决的技术问题。Therefore, how to effectively improve the sound quality inside the car at a low cost is a technical problem that needs to be solved.
发明内容Summary of the invention
本发明提供一种音频信号处理方法、装置、电子设备及计算机可读存储介质,以至少解决相关技术中由于需要花费大量资金来提高车内音效,导致成本增加的问题。本发明的技术方案如下:The present invention provides an audio signal processing method, device, electronic device and computer-readable storage medium to at least solve the problem of increased costs due to the need to spend a lot of money to improve the sound quality in the car in the related art. The technical solution of the present invention is as follows:
根据本发明实施例的第一方面,提供一种音频信号处理方法,包括;According to a first aspect of an embodiment of the present invention, there is provided an audio signal processing method, comprising:
获取左右声道混合后的音频信号;Get the audio signal after mixing the left and right channels;
基于数字信号处理调整所述音频信号中电平值的大小;Adjusting the level value of the audio signal based on digital signal processing;
基于调整的所述电平值的大小,对所述左右声道对应的音频信号进行动态低音增强处理;Based on the adjusted level value, performing dynamic bass enhancement processing on the audio signals corresponding to the left and right channels;
将处理后的所述左右声道的音频信号分别与对应声道的原音频信号进行叠加处理;Superimposing the processed audio signals of the left and right channels with the original audio signals of the corresponding channels respectively;
输出叠加处理后所述左右声道的音频信号。Output the audio signals of the left and right channels after superposition processing.
可选的,所述基于数字信号处理调整所述音频信号中电平值的大小,包括:Optionally, adjusting the level value of the audio signal based on digital signal processing includes:
基于数字信号处理按照电平的响应时间和释放时间检测所述音频信号中低音量的电平值;Detecting the level value of the bass volume in the audio signal according to the response time and release time of the level based on digital signal processing;
按照不同的系数变换来调整所述电平值的大小。The level value is adjusted according to different coefficient transformations.
可选的,所述按照不同的系数变换来调整所述电平值的大小,包括:Optionally, adjusting the level value according to different coefficient transformations includes:
将所述电平值与设置的不同系数相乘,来调整所述音频信号中低音量的电平值的大小。The level value is multiplied by different set coefficients to adjust the level value of the bass volume in the audio signal.
可选的,所述基于调整的所述电平值的大小,对所述左右声道对应的音频信号进行动态低音增强处理,包括:Optionally, the performing dynamic bass enhancement processing on the audio signals corresponding to the left and right channels based on the adjusted level value includes:
基于调整的所述电平值的大小,调整所述左右声道对应的音频信号的增益;Adjusting the gains of the audio signals corresponding to the left and right channels based on the adjusted level values;
将调整增益后的所述左右声道的音频信号输入对应的滤波器进行不同频段的补偿处理。The audio signals of the left and right channels after gain adjustment are input into corresponding filters for compensation processing of different frequency bands.
可选的,所述基于调整的所述电平值的大小,调整所述左右声道对应的音频信号的增益,包括:基于调整的所述电平值的大小,与动态因子相乘,基于相乘结果调整所述左右声道对应的音频信号中音量调节的动态增益;Optionally, adjusting the gain of the audio signal corresponding to the left and right channels based on the adjusted level value includes: multiplying the adjusted level value by a dynamic factor, and adjusting the dynamic gain of volume adjustment in the audio signal corresponding to the left and right channels based on the multiplication result;
所述将调整增益后的所述左右声道的音频信号输入对应的滤波器进行不同频段的补偿处理,包括:将调整增益后的所述左右声道的音频信号,分别输入到对应的低通滤波器,和/或高通滤波器进行不同频段的补偿处理;或者,将调整增益后的所述左右声道的音频信号输入到对应的一个或多个带通滤波器进行不同频段的多级补偿处理。The step of inputting the gain-adjusted audio signals of the left and right channels into corresponding filters for compensation processing of different frequency bands includes: inputting the gain-adjusted audio signals of the left and right channels into corresponding low-pass filters and/or high-pass filters, respectively, for compensation processing of different frequency bands; or, inputting the gain-adjusted audio signals of the left and right channels into corresponding one or more band-pass filters for multi-stage compensation processing of different frequency bands.
可选的,所述方法还包括:Optionally, the method further includes:
获取叠加处理后设定时间段内左右声道的音频信号;Obtain the audio signals of the left and right channels within a set time period after superposition processing;
对获取的所述左右声道的音频信号分别进行运算处理,得到处理后对应声道的相位差和中置信道信号;Performing calculation processing on the obtained audio signals of the left and right channels respectively to obtain the phase difference and center channel signal of the corresponding channels after processing;
对处理后的所述相位差和中置信道信号分别进行虚拟环绕声处理,得到声像定位后的左声道音频信号和中低频率补偿后的右声道音频信号;Performing virtual surround sound processing on the processed phase difference and center channel signal respectively to obtain a left channel audio signal after sound image localization and a right channel audio signal after mid-low frequency compensation;
将中低频率补偿后的所述右声道音频信号、声像定位后的所述左声道音频信号,与对应的左右声道原音频信号分别进行左右混音处理,输出左混音处理后的左声道音频信号和右混音处理后的右声道音频信号。The right channel audio signal after mid-low frequency compensation, the left channel audio signal after sound image localization, and the corresponding left and right channel original audio signals are respectively mixed, and the left channel audio signal after left mixing processing and the right channel audio signal after right mixing processing are output.
可选的,所述对获取的所述左右声道的音频信号分别进行运算处理,得到处理后对应声道的相位差和中置声道信号,包括:Optionally, performing operation processing on the acquired audio signals of the left and right channels respectively to obtain the phase difference of the corresponding channels and the center channel signal after processing includes:
对获取的所述左右声道的音频信号进行相减,得到所述设定时间段内中音频信号的相位差;Subtracting the acquired audio signals of the left and right channels to obtain a phase difference of the audio signal within the set time period;
对获取的所述左右声道的音频信号进行相加,模拟出所述设定时间段内的中置声道信号。The acquired audio signals of the left and right channels are added to simulate a center channel signal within the set time period.
可选的,所述对处理后的所述相位差和中置信道信号分别进行虚拟环绕声处理,得到声像定位后的左声道音频信号和中低频率补偿后的右声道音频信号,包括:Optionally, the processing of the processed phase difference and center channel signal respectively for virtual surround sound to obtain a left channel audio signal after sound image localization and a right channel audio signal after mid-low frequency compensation includes:
通过听觉空间定位机理的结论对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号;Performing frequency compensation on the phase difference based on the conclusion of auditory spatial localization mechanism to obtain a right channel audio signal after mid-low frequency compensation;
通过中央声控机理对所述中置音频信号进行频率控制,得到声像定位后的左声道音频信号。The center audio signal is frequency controlled by a central sound control mechanism to obtain a left channel audio signal after sound image localization.
可选的,所述通过听觉空间定位机理的结论对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号,包括:Optionally, the frequency compensation of the phase difference is performed based on the conclusion of the auditory space localization mechanism to obtain a right channel audio signal after mid- and low-frequency compensation, including:
通过听觉空间定位机理的结论利用Peaking滤波器对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号。The phase difference is frequency compensated by using a Peaking filter based on the conclusion of the auditory spatial localization mechanism to obtain a right channel audio signal after mid- and low-frequency compensation.
根据本发明实施例的第二方面,提供一种音频信号的处理方法,所述方法包括:According to a second aspect of an embodiment of the present invention, a method for processing an audio signal is provided, the method comprising:
获取设定时间段内左右声道的音频信号,所述音频信号包括:左右声道混合前的左右声道的音频信号;或者是输出叠加处理后的左右声道的音频信号;Acquire audio signals of left and right channels within a set time period, wherein the audio signals include: audio signals of left and right channels before mixing the left and right channels; or audio signals of left and right channels after output superposition processing;
对获取的所述左右声道的音频信号分别进行处理,得到处理后对应声道的相位差和中置信道信号;The obtained audio signals of the left and right channels are processed respectively to obtain the phase difference and center channel signal of the corresponding channels after processing;
对处理后的所述相位差和中置信道信号分别进行虚拟环绕声处理,得到声像定位后的左声道音频信号和中低频率补偿后的右声道音频信号;Performing virtual surround sound processing on the processed phase difference and center channel signal respectively to obtain a left channel audio signal after sound image localization and a right channel audio signal after mid-low frequency compensation;
将中低频率补偿后的所述右声道音频信号、声像定位后的所述左声道音频信号,与对应的左右声道原音频信号分别进行左右混音处理;Perform left-right mixing processing on the right channel audio signal after mid-low frequency compensation, the left channel audio signal after sound image localization, and the corresponding left and right channel original audio signals respectively;
输出左混音处理后的左声道音频信号和右混音处理后的右声道音频信号。Output the left channel audio signal after left mixing processing and the right channel audio signal after right mixing processing.
根据本发明实施例的第三方面,提供一种音频信号的处理装置,所述装置包括:According to a third aspect of an embodiment of the present invention, there is provided an audio signal processing device, the device comprising:
第一获取模块,用于获取左右声道混合后的音频信号;A first acquisition module is used to obtain an audio signal after the left and right channels are mixed;
调整模块,用于基于数字信号处理调整所述音频信号中电平值的大小;An adjustment module, used for adjusting the level value of the audio signal based on digital signal processing;
处理模块,用于基于调整的所述电平值的大小,对所述左右声道对应的音频信号进行动态低音增强的处理;A processing module, configured to perform dynamic bass enhancement processing on the audio signals corresponding to the left and right channels based on the adjusted level value;
叠加模块,用于将处理后的所述左右声道的音频信号分别与对应声道的原音频信号进行叠加处理;A superposition module, used for superimposing the processed audio signals of the left and right channels with the original audio signals of the corresponding channels respectively;
输出模块,用于输出叠加处理后所述左右声道的音频信号。The output module is used to output the audio signals of the left and right channels after superposition processing.
可选的,所述调整模块包括:Optionally, the adjustment module includes:
检测模块,用于基于数字信号处理按照电平的响应时间和释放时间检测所述音频信号中低音量的电平值;A detection module, configured to detect a level value of a bass volume in the audio signal according to a response time and a release time of the level based on digital signal processing;
电平调整模块,用于按照不同的系数变换来调整所述电平值的大小。The level adjustment module is used to adjust the level value according to different coefficient transformations.
可选的,所述电平调整模块,具体用于将所述电平值与设置的不同系数相乘,来调整所述音频信号中低音量的电平值的大小。Optionally, the level adjustment module is specifically configured to multiply the level value by different set coefficients to adjust the level value of the bass volume in the audio signal.
可选的,所述处理模块包括:Optionally, the processing module includes:
增益调整模块,用于基于调整的所述电平值的大小,调整所述左右声道对应的音频信号的增益;A gain adjustment module, used for adjusting the gain of the audio signal corresponding to the left and right channels based on the adjusted level value;
补偿处理模块,用于将调整增益后的所述左右声道的音频信号输入对应的滤波器进行不同频段的补偿处理。The compensation processing module is used to input the audio signals of the left and right channels after gain adjustment into corresponding filters for compensation processing of different frequency bands.
可选的,所述增益调整模块,具体用于基于调整的所述电平值的大小,与动态因子相乘,基于相乘结果调整所述左右声道对应的音频信号中音量调节的动态增益;Optionally, the gain adjustment module is specifically configured to multiply the adjusted level value by a dynamic factor, and adjust the dynamic gain of volume adjustment in the audio signals corresponding to the left and right channels based on the multiplication result;
所述补偿处理模块,具体用于将调整增益后的所述左右声道的音频信号,分别输入到对应的低通滤波器,和/或高通滤波器进行不同频段的补偿处理;或者,将调整增益后的所述左右声道的音频信号输入到对应的一个或多个带通滤波器进行不同频段的多级补偿处理。The compensation processing module is specifically used to input the audio signals of the left and right channels after adjusting the gains into corresponding low-pass filters and/or high-pass filters respectively for compensation processing in different frequency bands; or, input the audio signals of the left and right channels after adjusting the gains into corresponding one or more band-pass filters for multi-stage compensation processing in different frequency bands.
可选的,所述装置还包括:Optionally, the device further comprises:
第二获取模块,用于获取叠加处理后设定时间段内左右声道的音频信号;The second acquisition module is used to acquire the audio signals of the left and right channels within a set time period after superposition processing;
运算处理模块,用于对获取的所述左右声道的音频信号分别进行运算处理,得到处理后对应声道的相位差和中置信道信号;An operation processing module, used to perform operation processing on the acquired audio signals of the left and right channels respectively, to obtain the phase difference and center channel signal of the corresponding channels after processing;
虚拟环绕处理模块,用于对处理后的所述相位差和中置信道信号分别进行虚拟环绕声处理,得到声像定位后的左声道音频信号和中低频率补偿后的右声道音频信号;A virtual surround processing module, used to perform virtual surround sound processing on the processed phase difference and center channel signal respectively, to obtain a left channel audio signal after sound image localization and a right channel audio signal after mid-low frequency compensation;
混音处理模块,用于将中低频率补偿后的所述右声道音频信号、声像定位后的所述左声道音频信号,与对应的左右声道原音频信号分别进行左右混音处理,输出左混音处理后的左声道音频信号和右混音处理后的右声道音频信号。The mixing processing module is used to perform left-right mixing processing on the right channel audio signal after mid-low frequency compensation, the left channel audio signal after sound image localization, and the corresponding left and right channel original audio signals, and output the left channel audio signal after left mixing processing and the right channel audio signal after right mixing processing.
可选的,所述运算处理包括:Optionally, the operation processing includes:
减法处理模块,用于对获取的所述左右声道的音频信号进行相减,得到所述设定时间段内中音频信号的相位差;A subtraction processing module, used to subtract the acquired audio signals of the left and right channels to obtain a phase difference of the audio signal within the set time period;
加法处理模块,用于对获取的所述左右声道的音频信号进行相加,模拟出所述设定时间段内的中置声道信号。The addition processing module is used to add the acquired audio signals of the left and right channels to simulate the center channel signal within the set time period.
可选的,所述虚拟环绕处理模块包括:Optionally, the virtual surround processing module includes:
频率补偿处理模块,用于通过听觉空间定位机理的结论对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号;A frequency compensation processing module, used to perform frequency compensation on the phase difference according to the conclusion of the auditory space positioning mechanism, and obtain a right channel audio signal after mid-low frequency compensation;
频率控制处理模块,用于通过中央声控机理对所述中置音频信号进行频率控制,得到声像定位后的左声道音频信号。The frequency control processing module is used to perform frequency control on the center audio signal through a central sound control mechanism to obtain a left channel audio signal after sound image localization.
可选的,频率补偿处理模块,具体用于通过听觉空间定位机理的结论利用Peaking滤波器对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号。Optionally, the frequency compensation processing module is specifically used to perform frequency compensation on the phase difference using a Peaking filter based on the conclusion of the auditory space localization mechanism to obtain a right channel audio signal after mid- and low-frequency compensation.
根据本发明实施例的第四方面,提供一种音频信号的处理装置,所述装置包括:According to a fourth aspect of an embodiment of the present invention, there is provided an audio signal processing device, the device comprising:
获取模块,用于获取设定时间段内左右声道的音频信号,所述音频信号包括:左右声道混合前的左右声道的音频信号;或者是输出叠加处理后的左右声道的音频信号;An acquisition module, used to acquire audio signals of left and right channels within a set time period, wherein the audio signals include: audio signals of left and right channels before mixing the left and right channels; or audio signals of left and right channels after output superposition processing;
运算处理模块,用于对获取的所述左右声道的音频信号分别进行运算处理,得到处理后对应声道的相位差和中置信道信号;An operation processing module, used to perform operation processing on the acquired audio signals of the left and right channels respectively, to obtain the phase difference and center channel signal of the corresponding channels after processing;
虚拟声处理模块,用于对处理后的所述相位差和中置信道信号分别进行虚拟环绕声处理,得到声像定位后的左声道音频信号和中低频率补偿后的右声道音频信号;A virtual sound processing module, used for performing virtual surround sound processing on the processed phase difference and center channel signals respectively, to obtain a left channel audio signal after sound image localization and a right channel audio signal after mid-low frequency compensation;
混音处理模块,用于将中低频率补偿后的所述右声道音频信号、声像定位后的所述左声道音频信号,与对应的左右声道原音频信号分别进行左右混音处理;A mixing processing module, used for performing left-right mixing processing on the right channel audio signal after mid-low frequency compensation, the left channel audio signal after sound image localization, and the corresponding left and right channel original audio signals respectively;
输出模块,用于输出左混音处理后的左声道音频信号和右混音处理后的右声道音频信号。The output module is used to output the left channel audio signal after the left mixing process and the right channel audio signal after the right mixing process.
可选的,所述运算处理包括:Optionally, the operation processing includes:
减法处理模块,用于对获取的所述左右声道的音频信号进行相减,得到所述设定时间段内中音频信号的相位差;A subtraction processing module, used to subtract the acquired audio signals of the left and right channels to obtain a phase difference of the audio signal within the set time period;
加法处理模块,用于对获取的所述左右声道的音频信号进行相加,模拟出所述设定时间段内的中置声道信号。The addition processing module is used to add the acquired audio signals of the left and right channels to simulate the center channel signal within the set time period.
可选的,所述虚拟环绕处理模块包括:Optionally, the virtual surround processing module includes:
频率补偿处理模块,用于通过听觉空间定位机理的结论对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号;A frequency compensation processing module, used to perform frequency compensation on the phase difference according to the conclusion of the auditory space positioning mechanism, and obtain a right channel audio signal after mid-low frequency compensation;
频率控制处理模块,用于通过中央声控机理对所述中置音频信号进行频率控制,得到声像定位后的左声道音频信号。The frequency control processing module is used to perform frequency control on the center audio signal through a central sound control mechanism to obtain a left channel audio signal after sound image localization.
可选的,频率补偿处理模块,具体用于通过听觉空间定位机理的结论利用Peaking滤波器对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号。Optionally, the frequency compensation processing module is specifically used to perform frequency compensation on the phase difference using a Peaking filter based on the conclusion of the auditory space localization mechanism to obtain a right channel audio signal after mid- and low-frequency compensation.
根据本发明实施例的第五方面,提供一种电子设备,包括:According to a fifth aspect of an embodiment of the present invention, there is provided an electronic device, including:
处理器;processor;
用于存储所述处理器可执行指令的存储器;a memory for storing instructions executable by the processor;
其中,所述处理器被配置为执行所述指令,以实现如上所述的音频信号的处理方法。The processor is configured to execute the instructions to implement the audio signal processing method as described above.
根据本发明实施例的第六方面,提供一种计算机可读存储介质,当所述计算机可读存储介质中的指令由电子设备的处理器执行时,使得电子设备能够执行如上所述的音频信号的处理方法。According to a sixth aspect of an embodiment of the present invention, a computer-readable storage medium is provided. When instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the method for processing an audio signal as described above.
根据本发明实施例的第七方面,提供一种计算机程序产品,包括计算机程序或指令,所述计算机程序或指令被电子设备的处理器执行时实现如上所述的音频信号的处理方法。According to a seventh aspect of an embodiment of the present invention, there is provided a computer program product, comprising a computer program or instructions, wherein when the computer program or instructions are executed by a processor of an electronic device, the method for processing an audio signal as described above is implemented.
本发明的实施例提供的技术方案至少带来以下有益效果:The technical solution provided by the embodiments of the present invention brings at least the following beneficial effects:
本发明实施例中,获取左右声道混合后的音频信号;基于数字信号处理调整所述音频信号中电平值的大小;基于调整的所述电平值的大小,对所述左右声道对应的音频信号进行动态低音增强的处理;将处理后的所述左右声道的音频信号分别与对应声道的原音频信号进行叠加处理;输出叠加处理后所述左右声道的音频信号。也就是说,本发明实施例中,基于数字信号处理对左右声道混合后音频信号的电平值进行调整,并对调整后的左右声道对应的音频信号进行动态低音增强的处理,并将其转化成相应的控制信号去控制引出的两路音频信号的增益,之后,将这两路音频信号再与原来的左右声道的音频信号混合,从而达到对音频信号的多频段动态补偿,实现了低成本的动态低音效果。In an embodiment of the present invention, an audio signal after mixing left and right channels is obtained; the level value in the audio signal is adjusted based on digital signal processing; based on the adjusted level value, the audio signals corresponding to the left and right channels are dynamically enhanced by bass; the processed audio signals of the left and right channels are respectively superimposed with the original audio signals of the corresponding channels; and the audio signals of the left and right channels after superimposition are output. That is to say, in an embodiment of the present invention, the level value of the audio signal after mixing left and right channels is adjusted based on digital signal processing, and the audio signals corresponding to the adjusted left and right channels are dynamically enhanced by bass, and converted into corresponding control signals to control the gain of the two audio signals derived, and then the two audio signals are mixed with the original audio signals of the left and right channels, so as to achieve multi-band dynamic compensation of the audio signal and realize low-cost dynamic bass effect.
应当理解的是,以上的一般描述和后文的细节描述仅是示例性和解释性的,并不能限制本发明。It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the invention.
附图说明BRIEF DESCRIPTION OF THE DRAWINGS
此处的附图被并入说明书中并构成本说明书的一部分,示出了符合本发明的实施例,并与说明书一起用于解释本发明的原理,并不构成对本发明的不当限定。为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作一简单地介绍,显而易见地,下面描述中的附图是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。The drawings herein are incorporated into the specification and constitute a part of the specification, showing embodiments consistent with the present invention, and are used together with the specification to explain the principles of the present invention, and do not constitute an improper limitation of the present invention. In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the drawings required for use in the embodiments or the prior art description will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
图1是本发明实施例提供的一种音频信号的处理方法的流程图。FIG. 1 is a flow chart of a method for processing an audio signal provided by an embodiment of the present invention.
图2是本发明实施例提供的一种音频信号的处理方法的另一流程图。FIG. 2 is another flow chart of a method for processing an audio signal provided by an embodiment of the present invention.
图3是本发明实施例提供的一种音频信号的处理方法的应用实例的示意图。FIG. 3 is a schematic diagram of an application example of a method for processing an audio signal provided by an embodiment of the present invention.
图4是本发明实施例提供的一种音频信号的处理方法的应用实例的另一示意图。FIG. 4 is another schematic diagram of an application example of an audio signal processing method provided by an embodiment of the present invention.
图5为本发明实施例提供的一种频率补偿的示意图。FIG. 5 is a schematic diagram of frequency compensation provided by an embodiment of the present invention.
图6是本发明实施例提供的一种音频信号的处理装置的框图。FIG. 6 is a block diagram of an audio signal processing device provided by an embodiment of the present invention.
图7是本发明实施例提供的一种音频信号的处理装置的另一框图。FIG. 7 is another block diagram of an audio signal processing device provided by an embodiment of the present invention.
图8是本发明实施例提供的一种电子设备装置的框图。FIG8 is a block diagram of an electronic device provided by an embodiment of the present invention.
图9是本发明实施例提供的一种用于音频信号的处理装置的框图。FIG. 9 is a block diagram of a device for processing an audio signal provided by an embodiment of the present invention.
图10是本发明实施例提供的一种电子设备的另一框图。FIG. 10 is another block diagram of an electronic device provided by an embodiment of the present invention.
具体实施方式Detailed ways
为了使本领域普通人员更好地理解本发明的技术方案,下面将结合附图,对本发明实施例中的技术方案进行清楚、完整地描述。In order to enable ordinary persons in the art to better understand the technical solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings.
需要说明的是,本发明的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的本发明的实施例能够以除了在这里图示或描述的那些以外的顺序实施。以下示例性实施例中所描述的实施方式并不代表与本发明相一致的所有实施方式。相反,它们仅是与如所附权利要求书中所详述的、本发明的一些方面相一致的装置和方法的例子。It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Instead, they are merely examples of devices and methods consistent with some aspects of the present invention as detailed in the appended claims.
图1是本发明实施例提供的一种音频信号的处理方法的流程图,如图1所示,该音频信号的处理方法包括以下步骤:FIG. 1 is a flow chart of a method for processing an audio signal provided by an embodiment of the present invention. As shown in FIG. 1 , the method for processing an audio signal includes the following steps:
步骤101:获取左右声道混合后的音频信号;Step 101: Obtaining a mixed audio signal of left and right channels;
步骤102:基于数字信号处理调整所述音频信号中电平值的大小;Step 102: adjusting the level value of the audio signal based on digital signal processing;
步骤103:基于调整的所述电平值的大小,对所述左右声道对应的音频信号进行动态低音增强的处理;Step 103: Based on the adjusted level value, dynamically enhance the audio signals corresponding to the left and right channels with bass enhancement;
步骤104:将处理后的所述左右声道的音频信号分别与对应声道的原音频信号进行叠加处理;Step 104: superimposing the processed audio signals of the left and right channels with the original audio signals of the corresponding channels respectively;
步骤105:输出叠加处理后所述左右声道的音频信号。Step 105: outputting the audio signals of the left and right channels after the superposition processing.
本发明实施例中,获取左右声道混合后的音频信号;基于数字信号处理调整所述音频信号中电平值的大小;基于调整的所述电平值的大小,对所述左右声道对应的音频信号进行动态低音增强的处理;将处理后的所述左右声道的音频信号分别与对应声道的原音频信号进行叠加处理;输出叠加处理后所述左右声道的音频信号。也就是说,本发明实施例,基于数字信号处理对左右声道混合后音频信号的电平值进行调整,并对调整后的左右声道的音频信号进行动态低音增强的处理,将其转化成相应的控制信号去控制引出的两路音频信号的增益,再与原来的左右声道的音频信号混合,从而达到对音频信号的多频段动态补偿,实现了低成本的动态效果。In an embodiment of the present invention, an audio signal after mixing left and right channels is obtained; the level value in the audio signal is adjusted based on digital signal processing; based on the adjusted level value, dynamic bass enhancement is performed on the audio signals corresponding to the left and right channels; the processed audio signals of the left and right channels are respectively superimposed with the original audio signals of the corresponding channels; and the audio signals of the left and right channels after superimposition are output. That is to say, in an embodiment of the present invention, the level value of the audio signal after mixing left and right channels is adjusted based on digital signal processing, and the adjusted audio signals of the left and right channels are dynamically enhanced, which are converted into corresponding control signals to control the gain of the two audio signals derived, and then mixed with the original audio signals of the left and right channels, thereby achieving multi-band dynamic compensation of the audio signal and realizing low-cost dynamic effects.
本发明所述的音频信号的处理方法可以应用于终端、服务器,车端等,在此不作限制,其终端实施设备可以是智能手机,笔记本电脑、平板电脑、台式电脑、个人数字助理(PDA,Personal Digital Assistant)和穿戴式设备等电子设备。车端可以是车载终端,车控平台,工控机等电子设备。服务器可以为独立的服务器,也可以是服务器集群,或者是提供云服务、云数据库、云计算、云函数,云存储,网络服务、云通信、中间服务,域名服务、安全服务、内容分发网络的服务器,或者是大数据和人工智能平台等,在此不作限制。The audio signal processing method described in the present invention can be applied to terminals, servers, vehicle terminals, etc., without limitation. The terminal implementation device can be electronic devices such as smart phones, laptops, tablet computers, desktop computers, personal digital assistants (PDA, Personal Digital Assistant) and wearable devices. The vehicle terminal can be electronic devices such as vehicle terminals, vehicle control platforms, industrial computers, etc. The server can be an independent server, or a server cluster, or a server that provides cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, intermediate services, domain name services, security services, content distribution networks, or big data and artificial intelligence platforms, etc., without limitation.
下面结合图1,对本发明实施例提供的一种音频信号的处理方法的具体实施步骤进行详细说明。1 , specific implementation steps of an audio signal processing method provided by an embodiment of the present invention are described in detail below.
在步骤101中,获取左右声道混合后的音频信号。In step 101, an audio signal after mixing left and right channels is obtained.
该步骤中,电子设备先获取需要播放的左右声道内的音频信号,之后,对获取的该左右音频信号进行混合,得到混合后的音频信号。其混合方式,就是对左右音频信号进行叠加。In this step, the electronic device first obtains the audio signals in the left and right channels to be played, and then mixes the obtained left and right audio signals to obtain a mixed audio signal. The mixing method is to superimpose the left and right audio signals.
在步骤102中,基于数字信号处理调整所述音频信号中电平值的大小。In step 102, the level value of the audio signal is adjusted based on digital signal processing.
该步骤中,基于数字信号处理DSP按照电平的响应时间和释放时间,检测所述音频信号中低音量的电平值,之后,按照不同的系数变换来调整所述电平值的大小。In this step, the digital signal processing DSP detects the level value of the bass volume in the audio signal according to the response time and release time of the level, and then adjusts the level value according to different coefficient transformations.
具体的,该实施例中,基于数字信号处理(DSP,Digital Signal Process)可以只对音频信号中的低频信号的电平值进行监测,通常按照电平的响应时间和释放时间来检测,以便于能够改变信号检测的实时性以及平滑度。通常取信号的正半周的包络信号。需要说明的是,信号中的包络信号是指一个高频调幅信号。它幅度是按低频调制信号变化的。如果把高频调制信号的峰点连接起来,就可以得到一个与低频调制信号相对应的曲线。这条曲线就是包络线。就是两条能够把信号波形包起来的曲线。Specifically, in this embodiment, based on digital signal processing (DSP, Digital Signal Process), only the level value of the low-frequency signal in the audio signal can be monitored, usually according to the response time and release time of the level, so as to change the real-time and smoothness of the signal detection. Usually, the envelope signal of the positive half cycle of the signal is taken. It should be noted that the envelope signal in the signal refers to a high-frequency amplitude modulation signal. Its amplitude changes according to the low-frequency modulation signal. If the peak points of the high-frequency modulation signal are connected, a curve corresponding to the low-frequency modulation signal can be obtained. This curve is the envelope line. It is two curves that can wrap the signal waveform.
其中,所述按照不同的系数变换来调整所述电平值的大小,包括:将所述电平值与设置的不同系数相乘,来调整所述音频信号中低音量的电平值的大小。The adjusting the level value by transforming according to different coefficients includes: multiplying the level value by different set coefficients to adjust the level value of the low volume in the audio signal.
该实施例中,不同的系数是预设设定的,就是将检测到的电平值与设定的不同系数分别进行相乘,得到不同大小的电平值,从而依次此来改变电平值的大小。In this embodiment, different coefficients are preset, that is, the detected level value is multiplied by different preset coefficients respectively to obtain level values of different sizes, thereby changing the size of the level value in turn.
在步骤103中,基于调整的所述电平值的大小,对所述左右声道对应的音频信号进行动态低音增强处理。In step 103, based on the adjusted level value, dynamic bass enhancement processing is performed on the audio signals corresponding to the left and right channels.
该步骤中,基于调整的所述电平值的大小,调整所述左右声道对应的音频信号的增益;将调整增益后的所述左右声道的音频信号输入对应的滤波器进行不同频段的补偿处理。In this step, based on the adjusted level value, the gains of the audio signals corresponding to the left and right channels are adjusted; and the audio signals of the left and right channels after the gains are adjusted are input into corresponding filters for compensation processing of different frequency bands.
其中,所述基于调整的所述电平值的大小,调整所述左右声道对应的音频信号的增益,包括:基于调整的所述电平值的大小,与动态因子相乘,基于相乘结果调整所述左右声道对应的音频信号中音量调节的动态增益;以及Wherein, adjusting the gain of the audio signal corresponding to the left and right channels based on the adjusted level value comprises: multiplying the adjusted level value by a dynamic factor, and adjusting the dynamic gain of the volume adjustment in the audio signal corresponding to the left and right channels based on the multiplication result; and
所述将调整增益后的所述左右声道的音频信号输入对应的滤波器进行不同频段的补偿处理,包括:将调整增益后的所述左右声道的音频信号,分别输入到对应的低通滤波器,和/或高通滤波器进行不同频段的补偿处理;或者,将调整增益后的所述左右声道的音频信号输入到对应的一个或多个带通滤波器进行不同频段的多级补偿处理。The step of inputting the gain-adjusted audio signals of the left and right channels into corresponding filters for compensation processing of different frequency bands includes: inputting the gain-adjusted audio signals of the left and right channels into corresponding low-pass filters and/or high-pass filters, respectively, for compensation processing of different frequency bands; or, inputting the gain-adjusted audio signals of the left and right channels into corresponding one or more band-pass filters for multi-stage compensation processing of different frequency bands.
该实施例中,可以根据检测到电平值的大小来改变后面增益的值,具体通过设置不同频段的系数进行变换。In this embodiment, the value of the subsequent gain can be changed according to the magnitude of the detected level value, specifically by setting coefficients of different frequency bands for the transformation.
具体的,当电平值大于设定阈值时,后面的增益为0,也就是对原音频信号不作处理,直接输出。当电平值小于或者等于该设定阈值时,将所述电平值与不同的动态因子相乘,基于相乘结果调整所述左右声道对应的音频信号中音量调节的动态增益。电平值越小,其增益越大。之后,将调整增益后的所述左右声道的音频信号,分别输入到对应的低通滤波器,和/或高通滤波器进行不同频段的补偿处理;或者,将调整增益后的所述左右声道的音频信号输入到对应的一个或多个带通滤波器进行不同频段的多级补偿处理。Specifically, when the level value is greater than the set threshold, the subsequent gain is 0, that is, the original audio signal is not processed and is directly output. When the level value is less than or equal to the set threshold, the level value is multiplied by different dynamic factors, and the dynamic gain of the volume adjustment in the audio signal corresponding to the left and right channels is adjusted based on the multiplication result. The smaller the level value, the greater its gain. Afterwards, the audio signals of the left and right channels after the gain is adjusted are respectively input into the corresponding low-pass filter and/or high-pass filter for compensation processing of different frequency bands; or, the audio signals of the left and right channels after the gain is adjusted are input into the corresponding one or more band-pass filters for multi-stage compensation processing of different frequency bands.
需要说明的是,对于同一个输入的电平,处于不同频段的系数变换后,得出的增益控制也不一样,比如说,一般低通频段的增益要比高通频段的大,这是由等响度曲线得到的。It should be noted that for the same input level, the gain control obtained after the coefficients in different frequency bands are transformed is also different. For example, the gain of the low-pass band is generally larger than that of the high-pass band, which is obtained from the equal loudness curve.
其中,本实施例中的多级补偿部分是通过一个带通滤波器来实现的,可以根据需要拓展成多个带通滤波器,这样,用户就可以根据需求将不同的频段的音频信号输入到不同频段的滤波器进行滤波处理,从而达到多级补偿的效果。Among them, the multi-stage compensation part in this embodiment is realized by a bandpass filter, which can be expanded into multiple bandpass filters as needed. In this way, users can input audio signals of different frequency bands into filters of different frequency bands for filtering processing as needed, thereby achieving the effect of multi-stage compensation.
在步骤104中,将处理后的所述左右声道的音频信号分别与对应声道的原音频信号进行叠加处理。In step 104, the processed audio signals of the left and right channels are respectively superimposed with the original audio signals of the corresponding channels.
该步骤中,将处理后的左声道的音频信号与对应左声道的原音频信号进行相加,从而得到相加后的左声道音频信号。In this step, the processed audio signal of the left channel is added to the original audio signal of the corresponding left channel, so as to obtain the added left channel audio signal.
同理,将处理后的右声道的音频信号与对应右声道的原音频信号进行相加,从而得到相加后的右声道音频信号。Similarly, the processed audio signal of the right channel is added to the original audio signal of the corresponding right channel to obtain an added right channel audio signal.
该步骤中,就是通过不同的滤波器进行滤波后,在与原来对应声道的音频信号进行混合,从而到达多频段动态补偿的效果。In this step, the audio signals are filtered through different filters and then mixed with the original audio signals of the corresponding channels, thereby achieving the effect of multi-band dynamic compensation.
在步骤105中,输出叠加处理后所述左右声道的音频信号。In step 105, the audio signals of the left and right channels after the superposition processing are output.
该步骤中,通过左声道输出叠加处理后所述左声道的音频信号,以及通过右声道输出叠加处理后所述右声道的音频信号。In this step, the audio signal of the left channel after the superposition processing is output through the left channel, and the audio signal of the right channel after the superposition processing is output through the right channel.
本发明实施例,基于数字信号处理对左右声道混合后音频信号的电平值进行调整,并将其转化成相应的控制信号去控制引出的两路音频信号的增益,对增益后的两路音频信号进行动态低音增强的处理后,再与原来的左右声道的音频信号混合,从而达到对音频信号的多频段动态补偿,实现了低成本的动态低音效果。In the embodiment of the present invention, the level value of the audio signal after the left and right channels are mixed is adjusted based on digital signal processing, and the level value is converted into a corresponding control signal to control the gain of the two-way audio signal. After the two-way audio signal after gain is processed with dynamic bass enhancement, it is mixed with the original left and right channel audio signals, thereby achieving multi-band dynamic compensation of the audio signal and realizing a low-cost dynamic bass effect.
可选的,在另一实施例中,该实施例在上述实施例的基础上,所述方法还可以包括:获取叠加处理后设定时间段内左右声道的音频信号;对获取的所述左右声道的音频信号分别进行运算处理,得到处理后对应声道的相位差和中置信道信号;对处理后的所述相位差和中置信道信号分别进行虚拟环绕声处理,得到声像定位后的左声道音频信号和中低频率补偿后的右声道音频信号;将中低频率补偿后的所述右声道音频信号、声像定位后的所述左声道音频信号,与对应的左右声道原音频信号分别进行左右混音处理,输出左混音处理后的左声道音频信号和右混音处理后的右声道音频信号。Optionally, in another embodiment, based on the above embodiment, the method may also include: obtaining audio signals of left and right channels within a set time period after superposition processing; performing calculation processing on the obtained audio signals of left and right channels respectively to obtain the phase difference and center channel signal of the corresponding channels after processing; performing virtual surround sound processing on the processed phase difference and center channel signal respectively to obtain the left channel audio signal after sound image positioning and the right channel audio signal after mid-low frequency compensation; performing left-right mixing processing on the right channel audio signal after mid-low frequency compensation and the left channel audio signal after sound image positioning with the corresponding original audio signals of left and right channels, and outputting the left channel audio signal after the left mixing processing and the right channel audio signal after the right mixing processing.
本发明实施例中,可以对获取到左右声道的音频信号,在数字信号处理DSP中进行动态低音增强处理,即基于调整的所述电平值的大小,对所述左右声道对应的音频信号进行动态低音增强处理,能够通过实际信号的大小来决定补偿的幅度,从而达到多级补偿效果;之后,对补偿后的音频信号再进行虚拟环绕声处理,即通过听觉空间定位机理,提取中低音频信号中有相位差的部分进行频率补偿,实现了低成本的动态低音效果。In an embodiment of the present invention, the audio signals of the left and right channels can be obtained and subjected to dynamic bass enhancement processing in the digital signal processing DSP, that is, based on the size of the adjusted level value, the audio signals corresponding to the left and right channels are subjected to dynamic bass enhancement processing, and the compensation amplitude can be determined by the size of the actual signal, thereby achieving a multi-level compensation effect; thereafter, the compensated audio signal is subjected to virtual surround sound processing, that is, through the auditory space positioning mechanism, the part with phase difference in the mid-low audio signal is extracted for frequency compensation, thereby achieving a low-cost dynamic bass effect.
可选的,所述对获取的所述左右声道的音频信号分别进行运算处理,得到处理后对应声道的相位差和中置声道信号,包括:对获取的所述左右声道的音频信号进行相减,得到所述设定时间段内中音频信号的相位差;对获取的所述左右声道的音频信号进行相加,模拟出所述设定时间段内的中置声道信号。Optionally, the acquired audio signals of the left and right channels are respectively processed to obtain the phase difference and center channel signal of the corresponding channels after processing, including: subtracting the acquired audio signals of the left and right channels to obtain the phase difference of the center audio signal within the set time period; adding the acquired audio signals of the left and right channels to simulate the center channel signal within the set time period.
可选的,所述对处理后的所述相位差和中置信道信号分别进行虚拟环绕声处理,得到声像定位后的左声道音频信号和中低频率补偿后的右声道音频信号,包括:通过听觉空间定位机理的结论对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号;通过中央声控机理对所述中置音频信号进行频率控制,得到声像定位后的左声道音频信号。Optionally, the processed phase difference and center channel signal are respectively subjected to virtual surround sound processing to obtain a left channel audio signal after sound image positioning and a right channel audio signal after mid- and low-frequency compensation, including: performing frequency compensation on the phase difference according to the conclusion of the auditory space positioning mechanism to obtain a right channel audio signal after mid- and low-frequency compensation; and performing frequency control on the center audio signal through a central sound control mechanism to obtain a left channel audio signal after sound image positioning.
该实施例中,可以通过设置的中央声控制,来改善声像定位和前置声场的效果,以及通过设置的空间声控制,来可改善环绕声的空间感和移动感。In this embodiment, the sound image positioning and the effect of the front sound field can be improved by setting the central sound control, and the spatial sense and movement sense of the surround sound can be improved by setting the spatial sound control.
其中,所述通过听觉空间定位机理的结论对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号,包括:通过听觉空间定位机理的结论利用Peaking滤波器对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号。Among them, the frequency compensation of the phase difference is performed according to the conclusion of the auditory space positioning mechanism to obtain the right channel audio signal after mid-low frequency compensation, including: using the Peaking filter to frequency compensate the phase difference according to the conclusion of the auditory space positioning mechanism to obtain the right channel audio signal after mid-low frequency compensation.
本发明实施例中,在上述实施例的基础上,获取叠加处理后设定时间段内左右声道的音频信号,之后,通过将左右声道的音频信号相减来提取出该设定时间段的相位差,然后,通过听觉空间定位机理的对中低频进行频率补偿,增加中低频的空间定位能力,模拟出虚拟环绕声道,通过改变虚拟环绕声道的电平大小,可以突出环境声以及各种发射声,改善空间感和移动感。以及将左右声道的音频信号相加,并模拟出中置声道,通过改变中置声道的声像定位和前置声场的效果。其具体的实现过程详见下述图2,在此不在赘述。In an embodiment of the present invention, based on the above embodiment, the audio signals of the left and right channels within a set time period after superposition processing are obtained, and then the phase difference of the set time period is extracted by subtracting the audio signals of the left and right channels, and then the frequency compensation of the mid-low frequency is performed through the auditory space positioning mechanism to increase the spatial positioning ability of the mid-low frequency, and simulate the virtual surround channel. By changing the level of the virtual surround channel, the ambient sound and various emitted sounds can be highlighted, and the sense of space and movement can be improved. And the audio signals of the left and right channels are added, and the center channel is simulated, and the sound image positioning and the front sound field effect of the center channel are changed. The specific implementation process is detailed in Figure 2 below, which will not be repeated here.
还请参阅图2,为本发明实施例提供的一种音频信号的处理方法另一流程图,所述方法包括:Please also refer to FIG. 2, which is another flow chart of a method for processing an audio signal provided by an embodiment of the present invention. The method includes:
步骤201:获取设定时间段内左右声道的音频信号;所述音频信号包括:左右声道混合前的左右声道的音频信号;或者是输出叠加处理后的左右声道的音频信号。Step 201: obtaining audio signals of left and right channels within a set time period; the audio signals include: audio signals of left and right channels before mixing; or audio signals of left and right channels after output superposition processing.
该步骤中,获取一段时间内的左右声道的音频信号,具体的,可以是图1实施例中的在左右声道混合前的左右声道的音频信号;也可以是输出叠加处理后的左右声道的音频信号等,本实施例不作限制。In this step, the audio signals of the left and right channels within a period of time are obtained. Specifically, they can be the audio signals of the left and right channels before the left and right channels are mixed in the embodiment of Figure 1; they can also be the audio signals of the left and right channels after the output superposition processing, etc., which is not limited in this embodiment.
步骤202:对获取的所述左右声道的音频信号分别进行运算处理,得到处理后对应声道的相位差和中置信道信号。Step 202: performing calculation processing on the acquired audio signals of the left and right channels respectively to obtain the phase difference and center channel signal of the corresponding channels after processing.
该步骤中,对获取的所述左右声道的音频信号进行相减,得到所述设定时间段内中音频信号的相位差;以及对获取的所述左右声道的音频信号进行相加,模拟出所述设定时间段内的中置声道信号。In this step, the obtained audio signals of the left and right channels are subtracted to obtain the phase difference of the center audio signal within the set time period; and the obtained audio signals of the left and right channels are added to simulate the center channel signal within the set time period.
具体的,将所述右声道的音频信号输入到反相器,得到右声道反向的音频信号,之后,将右声道反向的音频信号与左声道的音频信号进行相加(实际就是相减了),得到所述设定时间段内中音频信号的相位差。以及将获取的左右声道的音频信号直接相加,模拟出所述设定时间段内的中置声道信号。Specifically, the audio signal of the right channel is input into the inverter to obtain an inverted audio signal of the right channel, and then the inverted audio signal of the right channel is added (actually subtracted) with the audio signal of the left channel to obtain the phase difference of the center audio signal within the set time period. And the obtained audio signals of the left and right channels are directly added to simulate the center channel signal within the set time period.
步骤203:对处理后的所述相位差和中置信道信号分别进行虚拟环绕声处理,得到声像定位后的左声道音频信号和中低频率补偿后的右声道音频信号。Step 203: performing virtual surround sound processing on the processed phase difference and center channel signal respectively to obtain a left channel audio signal after sound image localization and a right channel audio signal after mid-low frequency compensation.
该步骤中,可以通过听觉空间定位机理的结论对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号;具体的,可以通过听觉空间定位机理的结论利用Peaking滤波器对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号。以及通过中央声控机理对所述中置音频信号进行频率控制,得到声像定位后的左声道音频信号。In this step, the phase difference can be frequency compensated according to the conclusion of the auditory space localization mechanism to obtain the right channel audio signal after mid-low frequency compensation; specifically, the phase difference can be frequency compensated using a Peaking filter according to the conclusion of the auditory space localization mechanism to obtain the right channel audio signal after mid-low frequency compensation. And the center audio signal can be frequency controlled by the central sound control mechanism to obtain the left channel audio signal after sound image localization.
该步骤中,对进行频率补偿得到中低频率补偿后的右声道音频信号,在输入到反相器进行信号反向处理,以及将得到声像定位后的左声道音频信号输入到放大器进行信号放大处理。In this step, the right channel audio signal after frequency compensation to obtain mid-low frequency compensation is input to the inverter for signal inversion processing, and the left channel audio signal after sound image localization is input to the amplifier for signal amplification processing.
步骤204:将中低频率补偿后的所述右声道音频信号、声像定位后的所述左声道音频信号,与对应的左右声道原音频信号分别进行左右混音处理,输出左混音处理后的左声道音频信号和右混音处理后的右声道音频信号。Step 204: Perform left-right mixing processing on the right channel audio signal after mid-low frequency compensation, the left channel audio signal after sound image localization, and the corresponding left and right channel original audio signals, and output the left channel audio signal after left mixing processing and the right channel audio signal after right mixing processing.
该步骤中,可以通过左混合器对中低频率补偿后的所述右声道音频信号、声像定位后的所述左声道音频信号,以及左声道的原音频信号混音处理,得到左混音处理后的左声道音频信号;同理,可以通过右混合器对中低频率补偿后的所述右声道音频信号、声像定位后的所述左声道音频信号,以及右声道的原音频信号混音处理,得到右混音处理后的右声道音频信号。其左混近器和右混音器的具体混音过程,对于本领域技术人员来说,已是熟知技术,在此不在赘述。In this step, the left mixer can mix the right channel audio signal after mid-low frequency compensation, the left channel audio signal after sound image localization, and the original audio signal of the left channel to obtain the left channel audio signal after left mixing. Similarly, the right channel audio signal after mid-low frequency compensation, the left channel audio signal after sound image localization, and the original audio signal of the right channel can be mixed by the right mixer to obtain the right channel audio signal after right mixing. The specific mixing process of the left mixer and the right mixer is already a well-known technology for those skilled in the art and will not be repeated here.
本发明实施例中,获取设定时间段内左右声道的音频信号,对获取的所述左右声道的音频信号分别进行处理,得到处理后对应声道的相位差和中置信道信号;对处理后的所述相位差和中置信道信号分别进行虚拟环绕声处理,得到声像定位后的左声道音频信号和中低频率补偿后的右声道音频信号;将中低频率补偿后的所述右声道音频信号、声像定位后的所述左声道音频信号,与对应的左右声道原音频信号分别进行左右混音处理;输出左混音处理后的左声道音频信号和右混音处理后的右声道音频信号。也就是说,本发明实施例中,基于数字信号处理对获取的所述左右声道的音频信号先进行处理,之后对处理得到的相位差和中置信道信号分别进行虚拟环绕声处理,即对该相位差通过听觉空间定位机理,提取中低音频信号中有相位差的部分进行频率补偿,增加中低频的空间定位能力,模拟出环绕声道,改善空间感和移动感,以及通过左右声道相加,模拟出中置声道,并改变中置声道的声像定位和前置声场的效果,从而实现了低成本的动态低音效果。In an embodiment of the present invention, audio signals of left and right channels within a set time period are obtained, and the obtained audio signals of left and right channels are processed respectively to obtain phase differences and center channel signals of corresponding channels after processing; virtual surround sound processing is performed on the processed phase differences and center channel signals respectively to obtain left channel audio signals after sound image localization and right channel audio signals after mid-low frequency compensation; left and right mixing processing is performed on the right channel audio signals after mid-low frequency compensation and the left channel audio signals after sound image localization, and the corresponding left and right channel original audio signals respectively; and the left channel audio signals after the left mixing processing and the right channel audio signals after the right mixing processing are output. That is to say, in the embodiment of the present invention, the acquired audio signals of the left and right channels are first processed based on digital signal processing, and then the processed phase difference and center channel signal are respectively subjected to virtual surround sound processing, that is, the phase difference is localized through the auditory space mechanism, and the part with phase difference in the mid-low audio signal is extracted for frequency compensation, the spatial localization capability of the mid-low frequency is increased, the surround channel is simulated, the sense of space and movement is improved, and the center channel is simulated by adding the left and right channels, and the sound image localization of the center channel and the effect of the front sound field are changed, thereby achieving a low-cost dynamic bass effect.
本发明实施例中,是基于数字信号处理DSP的基础上,通过动态低音和虚拟环绕声来对左右声道的音频信号进行补偿处理,以低成本就能实现的虚拟声和动态低音的效果。其中,而动态低音是由原来的等响度曲线改良而来,能够通过实际信号的大小来决定补偿的幅度并且可以拓宽作多级补偿。而虚拟环绕声是通过听觉空间定位机理,提取中音频信号中有相位差的部分进行频率补偿实现的,具体的实现过程详见下述。In the embodiment of the present invention, based on the digital signal processing DSP, the audio signals of the left and right channels are compensated by dynamic bass and virtual surround sound, so that the effects of virtual sound and dynamic bass can be achieved at a low cost. Among them, the dynamic bass is improved from the original equal loudness curve, and the compensation amplitude can be determined by the size of the actual signal and can be expanded to multiple levels of compensation. The virtual surround sound is realized by extracting the part with phase difference in the audio signal through the auditory space positioning mechanism for frequency compensation. The specific implementation process is detailed as follows.
还请参阅图3,为本发明实施例提供的一种音频信号的处理方法的应用实例示意图,所述方法通过动态低音对左右声道的音频信号进行补偿处理。本实施例以获取左声道L和右声道R的音频信号为例。如图3所示,包括:多个加法器,电平检测,多个系数变换,以及与每个系数变换相连的放大器(比如三极管等)和对应的滤波器,比如,低通滤波器(简称低通),高通滤波器(简称高通),以及带通滤波器(简称带通)等,从而实现多级补偿。其中,低通滤波器,用来过滤信号频谱的高频部分;高通,用来过滤信号频谱的低频部分;低通滤波器与高通滤波器的作用是过滤信号不同频率的波段。Please also refer to FIG3, which is a schematic diagram of an application example of an audio signal processing method provided by an embodiment of the present invention, wherein the method performs compensation processing on the audio signals of the left and right channels through dynamic bass. This embodiment takes the acquisition of the audio signals of the left channel L and the right channel R as an example. As shown in FIG3, it includes: multiple adders, level detection, multiple coefficient transformations, and amplifiers (such as triodes, etc.) and corresponding filters connected to each coefficient transformation, such as a low-pass filter (referred to as low-pass), a high-pass filter (referred to as high-pass), and a band-pass filter (referred to as band-pass), etc., so as to achieve multi-stage compensation. Among them, the low-pass filter is used to filter the high-frequency part of the signal spectrum; the high-pass is used to filter the low-frequency part of the signal spectrum; the role of the low-pass filter and the high-pass filter is to filter the bands of different frequencies of the signal.
如图3所示,先获取经过总音量调节之后的左右声道LR的音频信号,对该LR的音频信号进行声道混合处理,之后,对混合后的音频信号进行电平检测,可以通过一个电平检测模块来检测,并将检测的电平值与设置的多个不同的系数进行变换处理,即将该电平值增大到不同的频段,最终,增大后的信号转化成相应的控制信号,去控制放大器引出两路信号的增益,得到增益的信号,将不同的信号通过不同频段的滤波器后进行处理,并将得到的信号再与原来对应的的L或 R声道进行混合,从而输出经过多频段动态补偿后的音频信号,通过数字信号处理不但节省了成本,还能达到多级补偿的效果。As shown in FIG3 , the audio signals of the left and right channels LR after the total volume adjustment are first obtained, and the audio signals of the LR are subjected to channel mixing processing. After that, the mixed audio signals are subjected to level detection, which can be detected by a level detection module, and the detected level value is transformed with a plurality of different coefficients set, that is, the level value is increased to different frequency bands. Finally, the increased signal is converted into a corresponding control signal to control the gain of the two signals led out by the amplifier to obtain a gain signal, and different signals are processed after passing through filters of different frequency bands, and the obtained signal is mixed with the original corresponding L or R channel, so as to output an audio signal after multi-band dynamic compensation. Digital signal processing not only saves costs, but also achieves the effect of multi-level compensation.
该图3中,可以通过改变电平检测的响应时间和释放时间,来改变信号检测的实时性以及平滑度。In FIG. 3 , the real-time performance and smoothness of signal detection can be changed by changing the response time and release time of level detection.
该图3中的系数变换,可以根据检测到电平值的大小来改变后面信号增益的值,具体包括:当电平值小于或者等于设定阈值时,增益起作用,得到的电平值越小,增益越大。另外,对于同一个输入电平,处于不同频段的系数变换模块得出的增益控制也不一样,比如说,一般低通频段的增益要比高通频段的大,这是由等响度曲线得到的。The coefficient transformation in FIG3 can change the value of the subsequent signal gain according to the detected level value, specifically including: when the level value is less than or equal to the set threshold, the gain takes effect, and the smaller the level value is, the greater the gain is. In addition, for the same input level, the gain control obtained by the coefficient transformation module in different frequency bands is also different. For example, the gain of the low-pass frequency band is generally larger than that of the high-pass frequency band, which is obtained by the equal loudness curve.
需要说明的是,图3中的多级补偿部分是一个带通滤波器,可以拓展成多个带通滤波器,以便于用户根据自己的需求对不同的频段进行补偿,从而达到多级补偿的效果。It should be noted that the multi-stage compensation part in FIG. 3 is a bandpass filter, which can be expanded into multiple bandpass filters so that users can compensate for different frequency bands according to their needs, thereby achieving a multi-stage compensation effect.
下面详细说明在DSP中,图3中的电平检测和系数变换的具体实现过程,本实施例以一种代码实现为例来说明。The specific implementation process of the level detection and coefficient transformation in FIG. 3 in the DSP is described in detail below. This embodiment is described by taking a code implementation as an example.
1)电平检测的代码实现过程包括:1) The code implementation process of level detection includes:
其中,电平检测,本实施例需要对小信号进行,因此取信号的包络比较合适,比如可以取其正半周的包络。Among them, the level detection in this embodiment needs to be performed on a small signal, so it is more appropriate to take the envelope of the signal, for example, the envelope of its positive half cycle can be taken.
#defineFS48000#defineFS48000
if(InputDetect>0&&InputDetect>HoldDetect)if(InputDetect>0&&InputDetect>HoldDetect)
{{
IsRelease=0;IsRelease=0;
HoldDetect= InputDetect;HoldDetect = InputDetect;
HoldTime=0;HoldTime=0;
也就是说,一旦输入的音频信号的电平值比保存值要大,就立刻更新保存该电平值值和停止释放状态并重新计时,否则,继续计时。That is to say, once the level value of the input audio signal is greater than the stored value, the level value is immediately updated and stored, the release state is stopped and the timing is restarted, otherwise, the timing continues.
}else HoldTime++;}else HoldTime++;
if(HoldTime>ReleaseTime)if(HoldTime>ReleaseTime)
{{
IsRelease=1;IsRelease=1;
该程序段中,释放时间(ReleaseTime)是一个可调参数,假设此时的采样率48KHZ,那么当ReleaseTime为48000时,系统对电平的保持时间应该为1秒。In this program segment, the release time (ReleaseTime) is an adjustable parameter. Assuming that the sampling rate is 48KHZ at this time, when ReleaseTime is 48000, the system should maintain the level for 1 second.
}}
if(IsRelease)if(IsRelease)
{{
HoldDetect=HoldDetect*ReleaseRate;HoldDetect=HoldDetect*ReleaseRate;
也就是说,释放率(ReleaseRate)是一个介于0和1之间的小数,一旦开始释放,此时由于输入的音频信号比保存的信号值要小,那么信号呈一个自然下降的状态,ReleaseRate就是它每个采样点的下降速率,单位为G/Ts。That is to say, the release rate (ReleaseRate) is a decimal between 0 and 1. Once the release begins, since the input audio signal is smaller than the saved signal value, the signal will naturally decline. The ReleaseRate is the decline rate of each sampling point, and the unit is G/Ts.
}}
OutputDetect= HoldDetect;OutputDetect = HoldDetect;
也就是说,在/没有开启释放时,保存的值不作下降输出,开启时,下降后输出。That is to say, when the release is not turned on, the saved value is not output as a drop, and when it is turned on, it is output after dropping.
2)系数变换的可控增益的代码实现过程包括:2) The code implementation process of the controllable gain of coefficient transformation includes:
InputRadioChange= OutputDetect;InputRadioChange = OutputDetect;
CurrentLevel= 1650*InputRadioChange/(2^23);CurrentLevel= 1650*InputRadioChange/(2^23);
//由于目前采用的是24bit采样精度的DSP,有一bit为符号位,它的中置电压的1650mV,因此,上式中CurrentLevel的单位为mV。//Since the DSP currently uses a 24-bit sampling accuracy, there is one bit for the sign bit, and its center voltage is 1650mV. Therefore, the unit of CurrentLevel in the above formula is mV.
if(CurrentLevel>= ChangeLevel)if(CurrentLevel>=ChangeLevel)
// ChangeLevel是一个可调参数,单位为mV,一旦检测到的信号小于该值,动态增益作用// ChangeLevel is an adjustable parameter in mV. Once the detected signal is less than this value, the dynamic gain will be
{{
DyGainRadio=0;DyGainRadio=0;
// DyGainRadio是一个介于0和1之间的动态因子,与后来的最大收益MaxGain相作用,共同组成动态增益// DyGainRadio is a dynamic factor between 0 and 1, which interacts with the subsequent maximum gain MaxGain to form a dynamic gain
}else}else
{{
DyGainRadio =(ChangeLevel- CurrentLevel)/ ChangeLevel;DyGainRadio = (ChangeLevel - CurrentLevel) / ChangeLevel;
//检测到值越小,动态因子越大//The smaller the detected value, the larger the dynamic factor
}}
DyGain= DyGainRadio*MaxGain;DyGain= DyGainRadio*MaxGain;
//上式中,MaxGain是可调的最大增益,通过与动态因子相乘就能得到最终作用于音量调节的动态增益DyGain。//In the above formula, MaxGain is the maximum adjustable gain. By multiplying it with the dynamic factor, we can get the dynamic gain DyGain that is ultimately used for volume adjustment.
本实施例中,基于DSP检测出音量调节之后的电平值,并通过音量调节之后的电平值来确定低中频的补偿曲线,通过控制输入电平值和DSP内部的增益大小共同影响等响度,并通过不同的滤波器后再与原来的L R声道混合,从而到达多频段动态补偿的效果。In this embodiment, the level value after volume adjustment is detected based on the DSP, and the compensation curve of the low-intermediate frequency is determined by the level value after volume adjustment. The equal loudness is affected by controlling the input level value and the gain size inside the DSP, and then mixed with the original LR channel after passing through different filters, so as to achieve the effect of multi-band dynamic compensation.
比如,某款汽车主机,它的音量一共有43级,在音量40以下,等响度就会起作用。此时,不管是增大还是减少输入音源的音量,只要不改变主机的音量值,等响度都会起作用。增大输入音源音量时,等响度仍起作用,这固然是不对的,而减小输入音源音量时,由于音箱出来的声压级已经减少了,此时仍按原来的等响度曲线作补偿,也是不够的。For example, a certain car head unit has 43 volume levels. When the volume is below 40, equal loudness will work. At this time, whether you increase or decrease the volume of the input sound source, as long as the volume value of the head unit is not changed, equal loudness will work. It is wrong to still use equal loudness when increasing the volume of the input sound source. When decreasing the volume of the input sound source, since the sound pressure level from the speaker has been reduced, it is not enough to compensate according to the original equal loudness curve.
基于此,本实施例中,在传统等响度基础上作了改善,通过DSP内部检测出通过音量调节之后的电平值来确定补偿曲线,此时输入电平值和DSP内部的增益大小可以共同影响等响度,就能解决传统等响度中存在的问题,所谓等响度,假如要对两段频率进行提升,声音越小,提升的幅度就越大。Based on this, in this embodiment, an improvement is made on the basis of the traditional equal loudness. The level value after volume adjustment is detected by the DSP to determine the compensation curve. At this time, the input level value and the gain size inside the DSP can jointly affect the equal loudness, which can solve the problems existing in the traditional equal loudness. The so-called equal loudness means that if two frequency bands are to be enhanced, the smaller the sound, the greater the enhancement.
还请参阅图4,为本发明实施例提供的一种音频信号的处理方法的另一应用实例示意图,所述方法通过虚拟环绕声对左右声道的音频信号进行补偿处理。本实施例以获取左声道L和右声道R的音频信号为例。如图4所示,包括:反相器,加法器,空间声控制器,中央声控制器,频率补偿器,左混音器和右混音器等。虚拟环绕声,也叫虚拟立体声,立体声展宽,虚拟3D声场,SRS,是一种由立体声拓展成多声道的技术。Please also refer to Figure 4, which is a schematic diagram of another application example of a method for processing an audio signal provided by an embodiment of the present invention, wherein the method performs compensation processing on the audio signals of the left and right channels through virtual surround sound. This embodiment takes the acquisition of the audio signals of the left channel L and the right channel R as an example. As shown in Figure 4, it includes: an inverter, an adder, a spatial sound controller, a central sound controller, a frequency compensator, a left mixer and a right mixer, etc. Virtual surround sound, also called virtual stereo, stereo widening, virtual 3D sound field, SRS, is a technology that expands stereo into multi-channel.
本实施例中,为例重现3 D声场,先将记录在普通立体声信号中的环境声信号提取出来, 然后,再根据人耳的频率响应函数, 对提取出的环境声信号频谱做相应的改变。经处理后的信号仍为双声道音频信号, 将其送入功放后, 就可重现3 D声场。In this embodiment, for example, to reproduce the 3D sound field, the ambient sound signal recorded in the ordinary stereo signal is first extracted, and then the spectrum of the extracted ambient sound signal is changed accordingly according to the frequency response function of the human ear. The processed signal is still a two-channel audio signal, and after it is sent to the power amplifier, the 3D sound field can be reproduced.
而本实施例中,虚拟环绕声是通过听觉空间定位机理来实现的,通过对听觉空间定位机理的分析,能得出以下结论:In this embodiment, the virtual surround sound is realized by the auditory space positioning mechanism. By analyzing the auditory space positioning mechanism, the following conclusions can be drawn:
(a)在中低频(约小于1.5KHz)情况下,耳间时间差或相位差是定位的主要因素:(a) In the case of medium and low frequencies (less than about 1.5 kHz), the interaural time difference or phase difference is the main factor in positioning:
(b)在中频(约1.5KHz至4.0KHz)情况下,耳间时间差和强度差对定位共同起作用;(b) In the case of medium frequencies (about 1.5 kHz to 4.0 kHz), the interaural time difference and intensity difference play a role in localization;
(c)在中高频(约4KHz至5KHz)情况下,耳间强度差是定位的主要因素;(c) In the case of mid-high frequencies (about 4 kHz to 5 kHz), the interaural intensity difference is the main factor in localization;
(d)在高频(约大于5KHz至6KHz)情况下,耳廓效应对区分前后镜像位置的声源和中垂面的定位有着重要的作用;(d) At high frequencies (approximately greater than 5 kHz to 6 kHz), the pinna effect plays an important role in distinguishing the sound source at the front and rear mirror positions and the positioning of the median vertical plane;
(e)倾听者的头部的不自觉地微小转动,由此所引起的耳问强度差和时间差的改变,对区分前后镜像位置的声源有重要作用。(e) The changes in intensity and time differences between the ears caused by the listener's involuntary slight rotation of the head play an important role in distinguishing the sound sources in the front and rear mirror positions.
(f)无混响环境中,人耳感受到的声强是声源距离定位的主要因素;在混响环境中,直达声与混响声的声能之比对距离定位起主要作用。(f) In a rectifier environment, the sound intensity perceived by the human ear is the main factor in locating the distance of the sound source; in a reverberant environment, the ratio of the sound energy of the direct sound to that of the reverberant sound plays a major role in distance positioning.
需要说明的是,假如两个麦克风分别放在舞台的左右两侧作为左右声道的录制,当乐器在乐器区的某一点发声时,除非该乐器在两个麦克风的中垂线上,否则其发出的声音在进入两个麦克风之间必然会因为距离的不同的产生了一个时间差(相位差)。It should be noted that if two microphones are placed on the left and right sides of the stage for recording left and right channels, when a musical instrument makes a sound at a certain point in the instrument area, unless the instrument is on the midline of the two microphones, the sound it emits will inevitably produce a time difference (phase difference) when entering the two microphones due to the different distances.
基于此,本实施例通过将音源的左右声道相减来提取出该段的相位差,然后,通过听觉空间定位机理的a结论(比如在中低频(约小于1.5KHz)情况下,耳间时间差或相位差是定位的主要因素)对其进行频率补偿,突出其中低频,增加它的空间定位能力,模拟出环绕声道,通过改变其电平大小,可以突出环境声以及各种发射声,改善空间感和移动感。Based on this, this embodiment extracts the phase difference of this segment by subtracting the left and right channels of the sound source, and then performs frequency compensation based on the conclusion of the auditory spatial positioning mechanism (for example, in the case of mid-low frequencies (approximately less than 1.5KHz), the inter-aural time difference or phase difference is the main factor for positioning), thereby highlighting the mid-low frequencies, increasing its spatial positioning capability, and simulating the surround sound channel. By changing its level, it can highlight the ambient sound and various emitted sounds, and improve the sense of space and movement.
同理,还可以通过将左右声道相加,模拟出中置声道,通过改变其声像定位和前置声场。其中,中置输出一般指音频的一个输出声道,一般来说,2.1声道的只有左右声道和低音输出,6.1声道的有左右声道(前)、左右声道(后)、中置输出、低音输出等。Similarly, you can also simulate the center channel by adding the left and right channels, and change its sound image positioning and front sound field. Among them, the center output generally refers to an output channel of the audio. Generally speaking, 2.1 channels only have left and right channels and bass output, and 6.1 channels have left and right channels (front), left and right channels (rear), center output, bass output, etc.
如图4所示,本实施例中,一方面,将获取的右声道的音频信号,通过反相器,将相反器输出的语音信号与左声道的音频信号进行相加处理,并通过设置的空间声控制对相位差进行频率补偿,得到中低频率补偿后的右声道音频信号;并将频率补偿后的右声道的音频信号一路通过反相器输入到右混音器中,另一路直接输入到左混音器中;As shown in FIG4 , in this embodiment, on the one hand, the acquired audio signal of the right channel is added to the audio signal of the left channel through an inverter, and the phase difference is frequency compensated through the set spatial sound control to obtain the right channel audio signal after mid-low frequency compensation; and the audio signal of the right channel after frequency compensation is input into the right mixer through the inverter in one way, and directly input into the left mixer in the other way;
同时,另一方,将获取的左声道的音频信号,与右声道的音频信号直接进行相加处理,模拟中置音频信号,并通过中央声控制的机理对所述中置音频信号进行频率控制,得到声像定位后的左声道音频信号,将左声道音频信号输入到放大器进行信号放大处理,并将放大处理后的语音信号,一路输入到右混音器,另一路输入到左混音器。At the same time, on the other hand, the acquired left channel audio signal is directly added to the right channel audio signal to simulate the center audio signal, and the frequency of the center audio signal is controlled by the central sound control mechanism to obtain the left channel audio signal after sound image positioning, and the left channel audio signal is input into the amplifier for signal amplification, and the amplified voice signal is input into the right mixer in one way and the left mixer in the other way.
该右混音器对于接收到的该右声道的原音频信号,反相器输入的音频信号,以及左声道输入的音频信号进行右混音处理,从而改善了环绕声的空间感和移动感,以及该左混音器对于接收到的该左声道的原音频信号,放大器输入的音频信号,以及频率补偿后的右声道输入的音频信号进行左混音处理,从而改善了声像定位和前置声场的效果。The right mixer performs right mixing processing on the original audio signal of the right channel, the audio signal input by the inverter, and the audio signal input by the left channel, thereby improving the spatial sense and movement sense of the surround sound, and the left mixer performs left mixing processing on the original audio signal of the left channel, the audio signal input by the amplifier, and the audio signal input by the right channel after frequency compensation, thereby improving the sound image positioning and the effect of the front sound field.
下面详细说明在DSP中,图4中的频率补偿的具体实现过程,本实施例以一种频率补偿的实现代码为例来说明。该图4中其他模块的实现比较简单,对于本领域技术人员来说,已是熟知技术。The specific implementation process of the frequency compensation in Figure 4 in DSP is described in detail below. This embodiment takes a frequency compensation implementation code as an example. The implementation of other modules in Figure 4 is relatively simple and is already a well-known technology for those skilled in the art.
假如,本实施例需要的频率补偿如图5所示,图5为本发明实施例提供的一种频率补偿的示意图。Assume that the frequency compensation required by this embodiment is as shown in FIG. 5 , which is a schematic diagram of a frequency compensation provided by an embodiment of the present invention.
基于在Matlab中大量仿真的结果,可以得出,用三段EQ可以大致模拟出该段曲线,其增益,中心频率,Q值分别为{+10dB200Hz0.41;-2dB3000Hz0.41;+5dB20000Hz0.41}。其具体实现过程包括:Based on the results of a large number of simulations in Matlab, it can be concluded that the three-band EQ can roughly simulate this curve, and its gain, center frequency, and Q value are {+10dB200Hz0.41; -2dB3000Hz0.41; +5dB20000Hz0.41} respectively. The specific implementation process includes:
通常情况下,要实现EQ,本实施例以IIR滤波器中的Peaking滤波器为例来实现。其中,IIR滤波器的一般形式为:Generally, to implement EQ, this embodiment uses the Peaking filter in the IIR filter as an example. The general form of the IIR filter is:
其时域的表达式为:Its time domain expression is:
而Peaking滤波器中各个参数的分别为The parameters of the Peaking filter are
其中,/> Among them,/>
其中,G表示中心频率的增益,单位为倍;fc表示中心频率;fs表示采样频率;Q表示品质因数;a0,a1,a2分别表示前向系数,b0,b1,b2分别表示反馈系数;利用中心频率fc和采样率fs计算出中间变量,/>S,/>C,利用Q值计算出变量/>,利用增益值G计算出变量A。Where G is the gain of the center frequency, in times; fc is the center frequency; fs is the sampling frequency; Q is the quality factor; a 0 , a 1 , a 2 are the forward coefficients, b 0 , b 1 , b 2 are the feedback coefficients; the intermediate variable is calculated using the center frequency fc and the sampling rate fs ,/> S,/> C, use Q value to calculate the variable/> , and use the gain value G to calculate the variable A.
因此,通过上述的公式,可以计算出这三段EQ的各个参数,然后用DSP实现上述时域表达式,即可实现频率补偿。Therefore, through the above formula, the various parameters of the three-band EQ can be calculated, and then the above time domain expression can be implemented by DSP to achieve frequency compensation.
需要说明的是,IIR滤波器的基本工作原理是以指定的时域系数进行卷积运算,并根据滤波器特质设定频域系数,通过采样点传输函数估计原始信号的频域特性,从而获得信号到输出滤波器的频域算式,然后将频域结果反变换回时域,以实现滤波操作,这对本领域技术人员来说,已是熟知技术,在此不在赘述。It should be noted that the basic working principle of the IIR filter is to perform convolution operations with specified time domain coefficients, set frequency domain coefficients according to the filter characteristics, estimate the frequency domain characteristics of the original signal through the sampling point transfer function, and obtain the frequency domain formula of the signal to the output filter, and then transform the frequency domain result back to the time domain to achieve the filtering operation. This is a well-known technology for those skilled in the art and will not be repeated here.
本本发明实施例,利用数字信号处理技术,占用DSP资源少,成本低,效果好,性价比高,实现方式也很简单。The embodiment of the present invention utilizes digital signal processing technology, occupies less DSP resources, has low cost, good effect, high cost performance, and is also very simple to implement.
需要说明的是,对于方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本实施公开并不受所描述的动作顺序的限制,因为依据本发明,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作并不一定是本发明所必须的。It should be noted that, for the method embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should know that this implementation disclosure is not limited by the order of the actions described, because according to the present invention, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily required by the present invention.
图6是本发明实施例提供的一种音频信号的处理装置框图。参照图6,该装置包括:第一获取模块601,调整模块602,处理模块603,叠加模块604和输出模块605,其中,FIG6 is a block diagram of an audio signal processing device provided by an embodiment of the present invention. Referring to FIG6 , the device includes: a first acquisition module 601, an adjustment module 602, a processing module 603, a superposition module 604 and an output module 605, wherein:
第一获取模块601,用于获取左右声道混合后的音频信号;A first acquisition module 601 is used to acquire an audio signal after left and right channels are mixed;
调整模块602,用于基于数字信号处理调整所述音频信号中电平值的大小;An adjustment module 602, configured to adjust the level value of the audio signal based on digital signal processing;
处理模块603,用于基于调整的所述电平值的大小,对所述左右声道对应的音频信号进行动态低音增强的处理;A processing module 603 is used to perform dynamic bass enhancement processing on the audio signals corresponding to the left and right channels based on the adjusted level value;
叠加模块604,用于将处理后的所述左右声道的音频信号分别与对应声道的原音频信号进行叠加处理;A superposition module 604 is used to superimpose the processed audio signals of the left and right channels with the original audio signals of the corresponding channels respectively;
输出模块605,用于输出叠加处理后所述左右声道的音频信号。The output module 605 is used to output the left and right channel audio signals after superposition processing.
可选的,所述调整模块包括:Optionally, the adjustment module includes:
检测模块,用于基于数字信号处理按照电平的响应时间和释放时间检测所述音频信号中低音量的电平值;A detection module, configured to detect a level value of a bass volume in the audio signal according to a response time and a release time of the level based on digital signal processing;
电平调整模块,用于按照不同的系数变换来调整所述电平值的大小。The level adjustment module is used to adjust the level value according to different coefficient transformations.
可选的,所述电平调整模块,具体用于将所述电平值与设置的不同系数相乘,来调整所述音频信号中低音量的电平值的大小。Optionally, the level adjustment module is specifically configured to multiply the level value by different set coefficients to adjust the level value of the bass volume in the audio signal.
可选的,所述处理模块包括:Optionally, the processing module includes:
增益调整模块,用于基于调整的所述电平值的大小,调整所述左右声道对应的音频信号的增益;A gain adjustment module, used for adjusting the gain of the audio signal corresponding to the left and right channels based on the adjusted level value;
补偿处理模块,用于将调整增益后的所述左右声道的音频信号输入对应的滤波器进行不同频段的补偿处理。The compensation processing module is used to input the audio signals of the left and right channels after gain adjustment into corresponding filters for compensation processing of different frequency bands.
可选的,所述增益调整模块,具体用于基于调整的所述电平值的大小,与动态因子相乘,基于相乘结果调整所述左右声道对应的音频信号中音量调节的动态增益;Optionally, the gain adjustment module is specifically configured to multiply the adjusted level value by a dynamic factor, and adjust the dynamic gain of volume adjustment in the audio signals corresponding to the left and right channels based on the multiplication result;
所述补偿处理模块,具体用于将调整增益后的所述左右声道的音频信号,分别输入到对应的低通滤波器,和/或高通滤波器进行不同频段的补偿处理;或者,将调整增益后的所述左右声道的音频信号输入到对应的一个或多个带通滤波器进行不同频段的多级补偿处理。The compensation processing module is specifically used to input the audio signals of the left and right channels after adjusting the gains into corresponding low-pass filters and/or high-pass filters respectively for compensation processing in different frequency bands; or, input the audio signals of the left and right channels after adjusting the gains into corresponding one or more band-pass filters for multi-stage compensation processing in different frequency bands.
可选的,所述装置还包括:Optionally, the device further comprises:
第二获取模块,用于获取叠加处理后设定时间段内左右声道的音频信号;The second acquisition module is used to acquire the audio signals of the left and right channels within a set time period after superposition processing;
运算处理模块,用于对获取的所述左右声道的音频信号分别进行运算处理,得到处理后对应声道的相位差和中置信道信号;An operation processing module, used to perform operation processing on the acquired audio signals of the left and right channels respectively, to obtain the phase difference and center channel signal of the corresponding channels after processing;
虚拟环绕处理模块,用于对处理后的所述相位差和中置信道信号分别进行虚拟环绕声处理,得到声像定位后的左声道音频信号和中低频率补偿后的右声道音频信号;A virtual surround processing module, used to perform virtual surround sound processing on the processed phase difference and center channel signal respectively, to obtain a left channel audio signal after sound image localization and a right channel audio signal after mid-low frequency compensation;
混音处理模块,用于将中低频率补偿后的所述右声道音频信号、声像定位后的所述左声道音频信号,与对应的左右声道原音频信号分别进行左右混音处理,输出左混音处理后的左声道音频信号和右混音处理后的右声道音频信号。The mixing processing module is used to perform left-right mixing processing on the right channel audio signal after mid-low frequency compensation, the left channel audio signal after sound image localization, and the corresponding left and right channel original audio signals, and output the left channel audio signal after left mixing processing and the right channel audio signal after right mixing processing.
可选的,所述运算处理包括:Optionally, the operation processing includes:
减法处理模块,用于对获取的所述左右声道的音频信号进行相减,得到所述设定时间段内中音频信号的相位差;A subtraction processing module, used to subtract the acquired audio signals of the left and right channels to obtain a phase difference of the audio signal within the set time period;
加法处理模块,用于对获取的所述左右声道的音频信号进行相加,模拟出所述设定时间段内的中置声道信号。The addition processing module is used to add the acquired audio signals of the left and right channels to simulate the center channel signal within the set time period.
可选的,所述虚拟环绕处理模块包括:Optionally, the virtual surround processing module includes:
频率补偿处理模块,用于通过听觉空间定位机理的结论对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号;A frequency compensation processing module, used to perform frequency compensation on the phase difference according to the conclusion of the auditory space positioning mechanism, and obtain a right channel audio signal after mid-low frequency compensation;
频率控制处理模块,用于通过中央声控机理对所述中置音频信号进行频率控制,得到声像定位后的左声道音频信号。The frequency control processing module is used to perform frequency control on the center audio signal through a central sound control mechanism to obtain a left channel audio signal after sound image localization.
可选的,频率补偿处理模块,具体用于通过听觉空间定位机理的结论利用Peaking滤波器对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号。Optionally, the frequency compensation processing module is specifically used to perform frequency compensation on the phase difference using a Peaking filter based on the conclusion of the auditory space localization mechanism to obtain a right channel audio signal after mid- and low-frequency compensation.
图7是本发明实施例提供的一种音频信号的处理装置另一框图。所述装置包括:获取模块701,运算处理模块702,虚拟声处理模块703,混音处理模块704和输出模块705,其中,FIG7 is another block diagram of an audio signal processing device provided by an embodiment of the present invention. The device comprises: an acquisition module 701, an operation processing module 702, a virtual sound processing module 703, a mixing processing module 704 and an output module 705, wherein:
获取模块701,用于获取设定时间段内左右声道的音频信号,所述音频信号包括:左右声道混合前的左右声道的音频信号;或者是输出叠加处理后的左右声道的音频信号;The acquisition module 701 is used to acquire the audio signals of the left and right channels within a set time period, wherein the audio signals include: the audio signals of the left and right channels before the left and right channels are mixed; or the audio signals of the left and right channels after the output superposition processing;
运算处理模块702,用于对获取的所述左右声道的音频信号分别进行运算处理,得到处理后对应声道的相位差和中置信道信号;The operation processing module 702 is used to perform operation processing on the obtained audio signals of the left and right channels respectively to obtain the phase difference and center channel signal of the corresponding channels after processing;
虚拟声处理模块703,用于对处理后的所述相位差和中置信道信号分别进行虚拟环绕声处理,得到声像定位后的左声道音频信号和中低频率补偿后的右声道音频信号;A virtual sound processing module 703 is used to perform virtual surround sound processing on the processed phase difference and center channel signal to obtain a left channel audio signal after sound image localization and a right channel audio signal after mid-low frequency compensation;
混音处理模块704,用于将中低频率补偿后的所述右声道音频信号、声像定位后的所述左声道音频信号,与对应的左右声道原音频信号分别进行左右混音处理;A mixing processing module 704 is used to perform left-right mixing processing on the right channel audio signal after mid-low frequency compensation, the left channel audio signal after sound image localization, and the corresponding left and right channel original audio signals respectively;
输出模块705,用于输出左混音处理后的左声道音频信号和右混音处理后的右声道音频信号。The output module 705 is used to output the left channel audio signal after the left mixing process and the right channel audio signal after the right mixing process.
可选的,所述运算处理包括:Optionally, the operation processing includes:
减法处理模块,用于对获取的所述左右声道的音频信号进行相减,得到所述设定时间段内中音频信号的相位差;A subtraction processing module, used to subtract the acquired audio signals of the left and right channels to obtain a phase difference of the audio signal within the set time period;
加法处理模块,用于对获取的所述左右声道的音频信号进行相加,模拟出所述设定时间段内的中置声道信号。The addition processing module is used to add the acquired audio signals of the left and right channels to simulate the center channel signal within the set time period.
可选的,所述虚拟环绕处理模块包括:Optionally, the virtual surround processing module includes:
频率补偿处理模块,用于通过听觉空间定位机理的结论对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号;A frequency compensation processing module, used to perform frequency compensation on the phase difference according to the conclusion of the auditory space positioning mechanism, and obtain a right channel audio signal after mid-low frequency compensation;
频率控制处理模块,用于通过中央声控机理对所述中置音频信号进行频率控制,得到声像定位后的左声道音频信号。The frequency control processing module is used to perform frequency control on the center audio signal through a central sound control mechanism to obtain a left channel audio signal after sound image localization.
可选的,频率补偿处理模块,具体用于通过听觉空间定位机理的结论利用Peaking滤波器对所述相位差进行频率补偿,得到中低频率补偿后的右声道音频信号。Optionally, the frequency compensation processing module is specifically used to perform frequency compensation on the phase difference using a Peaking filter based on the conclusion of the auditory space localization mechanism to obtain a right channel audio signal after mid- and low-frequency compensation.
关于上述实施例中的装置,其中各个模块执行操作的具体方式已经在有关该方法的实施例中进行了详细描述,此处将不做详细阐述说明。Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
以上所描述的装置实施例仅仅是示意性的,其中所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。本领域普通技术人员在不付出创造性的劳动的情况下,即可以理解并实施。The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Those of ordinary skill in the art may understand and implement it without creative work.
图8是本发明实施例提供的一种电子设备800的框图。例如,电子设备800可以为移动终端也可以为服务器,本发明实施例中以电子设备为移动终端为例进行说明。例如,电子设备800可以是移动电话,计算机,数字广播终端,消息收发设备,游戏控制台,平板设备,医疗设备,健身设备,个人数字助理等。FIG8 is a block diagram of an electronic device 800 provided in an embodiment of the present invention. For example, the electronic device 800 may be a mobile terminal or a server, and the electronic device is a mobile terminal as an example for explanation in the embodiment of the present invention. For example, the electronic device 800 may be a mobile phone, a computer, a digital broadcast terminal, a message transceiver device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.
参照图8,电子设备800可以包括以下一个或多个组件:处理组件802,存储器804,电源组件806,多媒体组件808,音频组件810,输入/输出(I/ O)的接口812,传感器组件814,以及通信组件816。8 , electronic device 800 may include one or more of the following components: a processing component 802 , a memory 804 , a power component 806 , a multimedia component 808 , an audio component 810 , an input/output (I/O) interface 812 , a sensor component 814 , and a communication component 816 .
处理组件802通常控制电子设备800的整体操作,诸如与显示,电话呼叫,数据通信,相机操作和记录操作相关联的操作。处理组件802可以包括一个或多个处理器820来执行指令,以完成上述的方法的全部或部分步骤。此外,处理组件802可以包括一个或多个模块,便于处理组件802和其他组件之间的交互。例如,处理组件802可以包括多媒体模块,以方便多媒体组件808和处理组件802之间的交互。The processing component 802 generally controls the overall operation of the electronic device 800, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the above-mentioned method. In addition, the processing component 802 may include one or more modules to facilitate the interaction between the processing component 802 and other components. For example, the processing component 802 may include a multimedia module to facilitate the interaction between the multimedia component 808 and the processing component 802.
存储器804被配置为存储各种类型的数据以支持在设备800的操作。这些数据的示例包括用于在电子设备800上操作的任何应用程序或方法的指令,联系人数据,电话簿数据,消息,图片,视频等。存储器804可以由任何类型的易失性或非易失性存储设备或者它们的组合实现,如静态随机存取存储器(SRAM),电可擦除可编程只读存储器(EEPROM),可擦除可编程只读存储器(EPROM),可编程只读存储器(PROM),只读存储器(ROM),磁存储器,快闪存储器,磁盘或光盘。The memory 804 is configured to store various types of data to support operations on the device 800. Examples of such data include instructions for any application or method operating on the electronic device 800, contact data, phone book data, messages, pictures, videos, etc. The memory 804 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.
电源组件806为电子设备800的各种组件提供电力。电源组件806可以包括电源管理系统,一个或多个电源,及其他与为电子设备800生成、管理和分配电力相关联的组件。The power supply component 806 provides power to the various components of the electronic device 800. The power supply component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the electronic device 800.
多媒体组件808包括在所述电子设备800和用户之间的提供一个输出接口的屏幕。在一些实施例中,屏幕可以包括液晶显示器(LCD)和触摸面板(TP)。如果屏幕包括触摸面板,屏幕可以被实现为触摸屏,以接收来自用户的输入信号。触摸面板包括一个或多个触摸传感器以感测触摸、滑动和触摸面板上的手势。所述触摸传感器可以不仅感测触摸或滑动动作的边界,而且还检测与所述触摸或滑动操作相关的持续时间和压力。在一些实施例中,多媒体组件808包括一个前置摄像头和/或后置摄像头。当设备800处于操作模式,如拍摄模式或视频模式时,前置摄像头和/或后置摄像头可以接收外部的多媒体数据。每个前置摄像头和后置摄像头可以是一个固定的光学透镜系统或具有焦距和光学变焦能力。The multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 808 includes a front camera and/or a rear camera. When the device 800 is in an operating mode, such as a shooting mode or a video mode, the front camera and/or the rear camera may receive external multimedia data. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
音频组件810被配置为输出和/或输入音频信号。例如,音频组件810包括一个麦克风(MIC),当电子设备800处于操作模式,如呼叫模式、记录模式和语音识别模式时,麦克风被配置为接收外部音频信号。所接收的音频信号可以被进一步存储在存储器804或经由通信组件816发送。在一些实施例中,音频组件810还包括一个扬声器,用于输出音频信号。The audio component 810 is configured to output and/or input audio signals. For example, the audio component 810 includes a microphone (MIC), and when the electronic device 800 is in an operation mode, such as a call mode, a recording mode, and a voice recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 804 or sent via the communication component 816. In some embodiments, the audio component 810 also includes a speaker for outputting audio signals.
I/ O接口812为处理组件802和外围接口模块之间提供接口,上述外围接口模块可以是键盘,点击轮,按钮等。这些按钮可包括但不限于:主页按钮、音量按钮、启动按钮和锁定按钮。I/O interface 812 provides an interface between processing component 802 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to, home buttons, volume buttons, start buttons, and lock buttons.
传感器组件814包括一个或多个传感器,用于为电子设备800提供各个方面的状态评估。例如,传感器组件814可以检测到设备800的打开/关闭状态,组件的相对定位,例如所述组件为电子设备800的显示器和小键盘,传感器组件814还可以检测电子设备800或电子设备800一个组件的位置改变,用户与电子设备800接触的存在或不存在,电子设备800方位或加速/减速和电子设备800的温度变化。传感器组件814可以包括接近传感器,被配置用来在没有任何的物理接触时检测附近物体的存在。传感器组件814还可以包括光传感器,如CMOS或CCD图像传感器,用于在成像应用中使用。在一些实施例中,该传感器组件814还可以包括加速度传感器,陀螺仪传感器,磁传感器,压力传感器或温度传感器。The sensor assembly 814 includes one or more sensors for providing various aspects of status assessment for the electronic device 800. For example, the sensor assembly 814 can detect the open/closed state of the device 800, the relative positioning of components, such as the display and keypad of the electronic device 800, and the sensor assembly 814 can also detect the position change of the electronic device 800 or a component of the electronic device 800, the presence or absence of user contact with the electronic device 800, the orientation or acceleration/deceleration of the electronic device 800, and the temperature change of the electronic device 800. The sensor assembly 814 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 814 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 814 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
通信组件816被配置为便于电子设备800和其他设备之间有线或无线方式的通信。电子设备800可以接入基于通信标准的无线网络,如WiFi,运营商网络(如2G、3G、4G或5G),或它们的组合。在一个示例性实施例中,通信组件816经由广播信道接收来自外部广播管理系统的广播信号或广播相关信息。在一个示例性实施例中,所述通信组件816还包括近场通信(NFC)模块,以促进短程通信。例如,在NFC模块可基于射频识别(RFID)技术,红外数据协会(IrDA)技术,超宽带(UWB)技术,蓝牙(BT)技术和其他技术来实现。The communication component 816 is configured to facilitate wired or wireless communication between the electronic device 800 and other devices. The electronic device 800 can access a wireless network based on a communication standard, such as WiFi, a carrier network (such as 2G, 3G, 4G or 5G), or a combination thereof. In an exemplary embodiment, the communication component 816 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 816 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.
在实施例中,电子设备800可以被一个或多个应用专用集成电路(ASIC)、数字信号处理器(DSP)、数字信号处理设备(DSPD)、可编程逻辑器件(PLD)、现场可编程门阵列(FPGA)、控制器、微控制器、微处理器或其他电子元件实现,用于执行上述所示的音频信号的处理方法。In an embodiment, the electronic device 800 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to execute the audio signal processing method shown above.
在实施例中,还提供了一种计算机可读存储介质,当所述计算机可读存储介质中的指令由电子设备的处理器执行时,使得电子设备800能够执行上述所示的音频信号的处理方法。例如,所述计算机可读存储介质可以是ROM、随机存取存储器(RAM)、CD-ROM、磁带、软盘和光数据存储设备等。In an embodiment, a computer-readable storage medium is also provided, and when the instructions in the computer-readable storage medium are executed by the processor of the electronic device, the electronic device 800 can perform the above-mentioned audio signal processing method. For example, the computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.
在实施例中,还提供了一种计算机程序产品,包括计算机程序或指令,当计算机程序或指令由电子设备800的处理器820执行时,使得电子设备800执行上述所述音频信号的处理方法。In an embodiment, a computer program product is further provided, including a computer program or instructions. When the computer program or instructions are executed by the processor 820 of the electronic device 800, the electronic device 800 executes the above-mentioned audio signal processing method.
图9是本发明实施例提供的一种用于音频信号的处理的装置900的框图。例如,装置900可以被提供为一服务器。参照图9,装置900包括处理组件922,其进一步包括一个或多个处理器,以及由存储器932所代表的存储器资源,用于存储可由处理组件922的执行的指令,例如应用程序。存储器932中存储的应用程序可以包括一个或一个以上的每一个对应于一组指令的模块。此外,处理组件922被配置为执行指令,以执行上述方法。FIG9 is a block diagram of a device 900 for processing an audio signal provided by an embodiment of the present invention. For example, the device 900 can be provided as a server. Referring to FIG9 , the device 900 includes a processing component 922, which further includes one or more processors, and a memory resource represented by a memory 932, for storing instructions that can be executed by the processing component 922, such as an application. The application stored in the memory 932 can include one or more modules each corresponding to a set of instructions. In addition, the processing component 922 is configured to execute instructions to perform the above method.
装置900还可以包括一个电源组件926被配置为执行装置900的电源管理,一个有线或无线网络接口950被配置为将装置900连接到网络,和一个输入输出(I/O)接口958。装置900可以操作基于存储在存储器932的操作系统,例如Windows ServerTM,Mac OS XTM,UnixTM, LinuxTM,FreeBSDTM或类似。The device 900 may also include a power supply component 926 configured to perform power management of the device 900, a wired or wireless network interface 950 configured to connect the device 900 to a network, and an input/output (I/O) interface 958. The device 900 may operate based on an operating system stored in the memory 932, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, or the like.
图10是本发明实施例提供的一种电子设备的框图。如图所示,包括处理器1001、通信接口1002、存储器1003和通信总线1004,其中,处理器1001,通信接口1002,存储器1003通过通信总线1004完成相互间的通信;FIG10 is a block diagram of an electronic device provided by an embodiment of the present invention. As shown in the figure, it includes a processor 1001, a communication interface 1002, a memory 1003 and a communication bus 1004, wherein the processor 1001, the communication interface 1002, and the memory 1003 communicate with each other through the communication bus 1004;
存储器1003,用于存储所述处理器可执行指令;Memory 1003, used to store the processor executable instructions;
处理器1001,用于执行存储器1003上可执行指令时,实现如上所述的方法。The processor 1001 is used to implement the above method when executing the executable instructions in the memory 1003.
其中,该实施例中的通信总线可以是外设部件互连标准(PCI,PeripheralComponent Interconnect)总线或扩展工业标准结构(EISA,Extended Industry StandardArchitecture)总线等。该通信总线可以分为地址总线、数据总线、控制总线等。为便于表示,图中仅用一条粗线表示,但并不表示仅有一根总线或一种类型的总线。The communication bus in this embodiment may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.
通信接口用于上述电子设备与其他设备之间的通信。The communication interface is used for communication between the above electronic device and other devices.
存储器可以包括随机存取存储器(Random Access Memory,简称RAM),也可以包括非易失性存储器(non-volatile memory),例如至少一个磁盘存储器。可选的,存储器还可以是至少一个位于远离前述处理器的存储装置。The memory may include a random access memory (RAM) or a non-volatile memory, such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.
上述的处理器可以是通用处理器,包括中央处理器(CPU,Central ProcessingUnit)、网络处理器(NP,Network Processor)等;还可以是数字信号处理器(DSP,DigitalSignal Processing)、专用集成电路(ASIC,Application Specific IntegratedCircuit)、现场可编程门阵列(FPGA,Field-Programmable Gate Array)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件。The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
在本发明提供的又一实施例中,还提供了一种计算机可读存储介质,当所述计算机可读存储介质中的指令由电子设备的处理器执行时,使得电子设备能够执行如上所述方法。In another embodiment of the present invention, a computer-readable storage medium is provided. When instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the method described above.
在本发明提供的又一实施例中,还提供了一种包括计算机程序或指令的计算机程序产品,所述计算机程序或指令被电子设备的处理器执行时实现如上所述音频信号的处理方法。In another embodiment of the present invention, a computer program product including a computer program or instructions is provided. When the computer program or instructions are executed by a processor of an electronic device, the method for processing an audio signal as described above is implemented.
在实施例中,还提供了一种计算机可读存储介质,当所述计算机可读存储介质中的指令由电子设备的处理器执行时,使得电子设备能够执行上述所示的音频信号的处理方法。例如,所述计算机可读存储介质可以是ROM、随机存取存储器(RAM)、CD-ROM、磁带、软盘和光数据存储设备等。In an embodiment, a computer-readable storage medium is also provided, and when the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device can perform the above-mentioned audio signal processing method. For example, the computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.
在实施例中,还提供了一种计算机程序产品,包括计算机程序或指令,当计算机程序或指令由电子设备的处理器1001执行时,使得电子设备执行上述所述的音频信号的处理方法。In an embodiment, a computer program product is further provided, including a computer program or instructions. When the computer program or instructions are executed by the processor 1001 of the electronic device, the electronic device executes the above-mentioned method for processing audio signals.
本领域技术人员在考虑说明书及实践这里公开的发明后,将容易想到本发明的其它实施方案。本申请旨在涵盖本发明的任何变型、用途或者适应性变化,这些变型、用途或者适应性变化遵循本发明的一般性原理并包括本发明未公开的本技术领域中的公知常识或惯用技术手段。说明书和实施例仅被视为示例性的,本发明的真正范围和精神由下面的权利要求指出。Those skilled in the art will readily appreciate other embodiments of the present invention after considering the specification and practicing the invention disclosed herein. This application is intended to cover any variations, uses or adaptations of the present invention that follow the general principles of the present invention and include common knowledge or customary techniques in the art that are not disclosed by the present invention. The specification and examples are to be considered exemplary only, and the true scope and spirit of the present invention are indicated by the following claims.
应当理解的是,本发明并不局限于上面已经描述并在附图中示出的精确结构,并且可以在不脱离其范围进行各种修改和改变。本发明的范围仅由所附的权利要求来限制。It should be understood that the present invention is not limited to the exact construction that has been described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present invention is limited only by the appended claims.
Claims (14)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202410627193.7A CN118233809B (en) | 2024-05-20 | 2024-05-20 | Audio signal processing method and device, electronic equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202410627193.7A CN118233809B (en) | 2024-05-20 | 2024-05-20 | Audio signal processing method and device, electronic equipment and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN118233809A true CN118233809A (en) | 2024-06-21 |
CN118233809B CN118233809B (en) | 2024-08-16 |
Family
ID=91504329
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202410627193.7A Active CN118233809B (en) | 2024-05-20 | 2024-05-20 | Audio signal processing method and device, electronic equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN118233809B (en) |
Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6285767B1 (en) * | 1998-09-04 | 2001-09-04 | Srs Labs, Inc. | Low-frequency audio enhancement system |
CN1402956A (en) * | 1999-10-04 | 2003-03-12 | Srs实验室公司 | Acoustic correction apparatus |
US20070133831A1 (en) * | 2005-09-22 | 2007-06-14 | Samsung Electronics Co., Ltd. | Apparatus and method of reproducing virtual sound of two channels |
CN103501165A (en) * | 2010-01-07 | 2014-01-08 | 塔特公司 | Compressor based dynamic bass enhancement with EQ |
CN104010264A (en) * | 2013-02-21 | 2014-08-27 | 中兴通讯股份有限公司 | Method and apparatus for processing double-track audio signals |
US10382857B1 (en) * | 2018-03-28 | 2019-08-13 | Apple Inc. | Automatic level control for psychoacoustic bass enhancement |
CN111508510A (en) * | 2020-04-23 | 2020-08-07 | 惠州Tcl移动通信有限公司 | Audio processing method and device, storage medium and electronic equipment |
CN114143698A (en) * | 2021-10-29 | 2022-03-04 | 北京奇艺世纪科技有限公司 | Audio signal processing method and device and computer readable storage medium |
CN117376778A (en) * | 2023-11-07 | 2024-01-09 | 深圳市中科蓝讯科技股份有限公司 | Low-frequency loudness compensation method, electronic device and storage medium |
US20240031765A1 (en) * | 2022-07-25 | 2024-01-25 | Qualcomm Incorporated | Audio signal enhancement |
WO2024021682A1 (en) * | 2022-07-29 | 2024-02-01 | 荣耀终端有限公司 | Audio processing method, virtual bass enhancement system, device, and storage medium |
-
2024
- 2024-05-20 CN CN202410627193.7A patent/CN118233809B/en active Active
Patent Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6285767B1 (en) * | 1998-09-04 | 2001-09-04 | Srs Labs, Inc. | Low-frequency audio enhancement system |
CN1402956A (en) * | 1999-10-04 | 2003-03-12 | Srs实验室公司 | Acoustic correction apparatus |
US20070133831A1 (en) * | 2005-09-22 | 2007-06-14 | Samsung Electronics Co., Ltd. | Apparatus and method of reproducing virtual sound of two channels |
CN103501165A (en) * | 2010-01-07 | 2014-01-08 | 塔特公司 | Compressor based dynamic bass enhancement with EQ |
CN104010264A (en) * | 2013-02-21 | 2014-08-27 | 中兴通讯股份有限公司 | Method and apparatus for processing double-track audio signals |
US10382857B1 (en) * | 2018-03-28 | 2019-08-13 | Apple Inc. | Automatic level control for psychoacoustic bass enhancement |
CN111508510A (en) * | 2020-04-23 | 2020-08-07 | 惠州Tcl移动通信有限公司 | Audio processing method and device, storage medium and electronic equipment |
CN114143698A (en) * | 2021-10-29 | 2022-03-04 | 北京奇艺世纪科技有限公司 | Audio signal processing method and device and computer readable storage medium |
US20240031765A1 (en) * | 2022-07-25 | 2024-01-25 | Qualcomm Incorporated | Audio signal enhancement |
WO2024021682A1 (en) * | 2022-07-29 | 2024-02-01 | 荣耀终端有限公司 | Audio processing method, virtual bass enhancement system, device, and storage medium |
CN117376778A (en) * | 2023-11-07 | 2024-01-09 | 深圳市中科蓝讯科技股份有限公司 | Low-frequency loudness compensation method, electronic device and storage medium |
Non-Patent Citations (4)
Title |
---|
刘荣彬: "AV功放原理与维修讲座(7)――第七讲 频谱均衡控制及显示", 电子世界, no. 08, 31 August 2000 (2000-08-31) * |
吴继伟;: "双声道混合音频系统的设计与实现", 电子科技, no. 07, 31 July 2013 (2013-07-31) * |
周荣冠;: "心理声学低音增强技术的研究", 电声技术, no. 07, 17 July 2010 (2010-07-17) * |
徐立军;: "各种环绕声系统的工作原理(六)", 家电检修技术, no. 09, 1 May 2012 (2012-05-01) * |
Also Published As
Publication number | Publication date |
---|---|
CN118233809B (en) | 2024-08-16 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11304020B2 (en) | Immersive audio reproduction systems | |
EP3624463B1 (en) | Audio signal processing method and device, terminal and storage medium | |
KR101827032B1 (en) | Stereo image widening system | |
JP5955862B2 (en) | Immersive audio rendering system | |
JP7481116B2 (en) | Customized voice processing based on user-specific voice information and hardware-specific voice information | |
TWI431613B (en) | Upstream quality enhancement signal processing for resource constrained client devices | |
JP5485693B2 (en) | Apparatus and method for processing audio signals | |
US10812031B2 (en) | Electronic device and method for adjusting gain of digital audio signal based on hearing recognition characteristics | |
WO2020228404A1 (en) | Instant messaging sound quality optimization method, apparatus and device | |
CN111508510A (en) | Audio processing method and device, storage medium and electronic equipment | |
US11272304B2 (en) | Method and terminal for playing audio data, and storage medium thereof | |
CN114449391A (en) | Recording method and device and electronic equipment | |
CN111883164A (en) | Model training method and device, electronic equipment and storage medium | |
CN111698593B (en) | Active noise reduction method and device, and terminal | |
WO2023240467A1 (en) | Audio playback method and apparatus, and storage medium | |
CN118233809B (en) | Audio signal processing method and device, electronic equipment and storage medium | |
CN113689890B (en) | Method, device and storage medium for converting multichannel signal | |
CN108966110A (en) | Audio signal processing method, apparatus and system, terminal and storage medium | |
JP2021164109A (en) | Sound field correction method, sound field correction program and sound field correction system | |
US6999590B2 (en) | Stereo sound circuit device for providing three-dimensional surrounding effect | |
CN104519454B (en) | A kind of audio frequency signal output and device | |
JP2013162510A (en) | Information processing terminal and arrangement method of microphone | |
CN120358434A (en) | Audio processing method, device, electronic equipment and storage medium | |
CN116094479A (en) | Filter design method, device, electronic equipment and readable storage medium | |
CN114979889A (en) | Method and device for reducing occlusion effect of earphone, earphone 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 | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
PP01 | Preservation of patent right | ||
PP01 | Preservation of patent right |
Effective date of registration: 20250121 Granted publication date: 20240816 |