Method and device for adjusting audio signal in multiple scenes, medium and equipment
By adjusting the audio signal to adapt to the scene requirements of the multi-channel sound playback system, the problem of mono or dual-channel audio signals being difficult to map to multi-channel is solved, improving the sound effect and user experience.
Patent Information
- Application Number
- CN202510072106.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-16
- Publication Date
- 2025-04-25
AI Technical Summary
In a multi-channel sound playback system, the mono or two-channel audio signals to be played are difficult to effectively map to the multi-channel sound player, resulting in the inability to achieve the desired sound effects.
By determining the audio source position corresponding to the audio signal in the first scene and the position information of the sound player in the second scene, adjusting the audio signal to adapt to the sound effect requirements of the second scene, and improving the playback effect of the sound player.
It realizes the effective mapping of mono or two-channel audio signals to multi-channel sound players, improving the playback sound effect and user auditory experience in the second scene.
Smart Images

Figure CN119893392A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to signal processing technology, and in particular to a method, device, medium and equipment for adjusting audio signals in multiple scenarios. Background Art
[0002] When a multi-channel sound playback system (hereinafter referred to as the system) is used in a mobile terminal space, a home space, or other environment, if the number of channels of the audio signal to be played is less than the number of channels of the multi-channel sound playback system, for example, the audio signal to be played is a mono or dual-channel signal, it is usually necessary to map the audio signal to be played to multiple channels for playback. How to map the audio signal to be played to a sound player placed in the actual space for playback to achieve the desired sound effect has become a technical problem that needs to be solved urgently. Summary of the invention
[0003] The embodiments of the present disclosure provide a method, apparatus, medium and device for adjusting audio signals in multiple scenarios, which can map the audio signal to be played to any second scene and a sound player in any placement, obtain the audio signal corresponding to the sound player in the second scene, and improve the playback sound effect in the second scene.
[0004] A first aspect of an embodiment of the present disclosure provides a method for adjusting audio signals in multiple scenarios, including: determining first position information of a sound source corresponding to a first audio signal of a first channel in a first scenario in a second scenario; determining second position information of sound players of a second channel in the second scenario; determining second audio signals of a second channel based on the first audio signal of the first channel; determining adjustment parameters corresponding to the second audio signals of the second channel based on the second position information and the first position information; adjusting the second audio signals of the second channel based on the adjustment parameters corresponding to the second audio signals of the second channel to obtain third audio signals corresponding to the sound players of the second channel.
[0005] According to a second aspect of an embodiment of the present disclosure, there is provided an apparatus for adjusting audio signals in multiple scenarios, including: a first processing module for determining first position information of a sound source corresponding to a first audio signal of a first channel in a first scenario in a second scenario; a second processing module for determining second position information of sound players of a second channel in the second scenario in the second scenario; a third processing module for determining second audio signals of a second channel based on the first audio signal of the first channel; a fourth processing module for determining adjustment parameters corresponding to the second audio signals of the second channel based on the second position information and the first position information; and a fifth processing module for adjusting the second audio signals of the second channel based on the adjustment parameters corresponding to the second audio signals of the second channel, so as to obtain third audio signals corresponding to the sound players of the second channel.
[0006] According to a third aspect of the embodiments of the present disclosure, a computer-readable storage medium is provided, wherein the storage medium stores a computer program, and the computer program is used to execute the method for adjusting audio signals in multiple scenarios described in any one of the above embodiments of the present disclosure.
[0007] According to a fourth aspect of an embodiment of the present disclosure, an electronic device is provided, comprising: a processor; a memory for storing executable instructions of the processor; the processor is used to read the executable instructions from the memory and execute the instructions to implement the method for adjusting audio signals in multiple scenarios described in any one of the above embodiments of the present disclosure.
[0008] A fifth aspect of the embodiments of the present disclosure provides a computer program product. When instructions in the computer program product are executed by a processor, the method for adjusting audio signals in multiple scenarios provided in any one of the above embodiments of the present disclosure is performed.
[0009] Based on the method, device, medium and equipment for adjusting audio signals in multiple scenes provided by the above-mentioned embodiments of the present disclosure, when a first audio signal with a first number of channels in a certain scene (first scene) has been obtained and needs to be played in a second scene with a sound player placed in a different way from the first scene, the second audio signal obtained by mapping the first audio signal in the first scene can be adjusted in combination with the position of the sound player and the position of the sound source in the second scene, so that the adjusted third audio signal is more adapted to the placement of the sound player in the second scene, thereby improving the sound playback effect in the second scene and enhancing the user's auditory experience in the second scene. Moreover, when an audio signal in a first scene (for example, a standard placement scene of a sound player) is obtained, the method of the embodiments of the present disclosure can be used to obtain an audio signal of a sound player in any second scene with a placement different from the first scene, thereby improving the scene adaptability of the audio signal in the first scene while ensuring the sound effect of the second scene. BRIEF DESCRIPTION OF THE DRAWINGS
[0010] Figure 1 This is an exemplary application scenario of the method for adjusting audio signals in multiple scenarios provided by the present disclosure;
[0011] Figure 2 is a flowchart of a method for adjusting audio signals in multiple scenarios provided by an exemplary embodiment of the present disclosure;
[0012] Figure 3 is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0013] Figure 4 is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0014] Figure 5 is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0015] Figure 6 is a flowchart of determining adjustment parameters provided by an exemplary embodiment of the present disclosure;
[0016] Figure 7 is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0017] Figure 8 is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0018] Fig. 9is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0019] Fig.10 is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0020] Fig.11 is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0021] Fig.12 is a flowchart of a method for adjusting audio signals in multiple scenarios provided by an exemplary embodiment of the present disclosure;
[0022] Fig.13 is a schematic diagram of the principle of determining adjustment parameters provided by an exemplary embodiment of the present disclosure;
[0023] Fig.14 is a structural schematic diagram of a device for adjusting audio signals in multiple scenarios provided by an exemplary embodiment of the present disclosure;
[0024] Fig.15 is a structural schematic diagram of an apparatus for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0025] Fig.16 is a structural schematic diagram of an apparatus for adjusting audio signals in multiple scenarios provided by yet another exemplary embodiment of the present disclosure;
[0026] Fig.17 is a structural schematic diagram of an apparatus for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0027] Fig.18 A schematic diagram of a structure of a device for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0028] Fig.19 A schematic diagram of a structure of a device for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure;
[0029] Fig. 20 It is a structural diagram of an electronic device provided by an embodiment of the present disclosure. DETAILED DESCRIPTION
[0030] To explain the present disclosure, example embodiments of the present disclosure will be described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present disclosure, rather than all the embodiments. It should be understood that the present disclosure is not limited to the example embodiments.
[0031] It should be noted that the relative arrangement of components and steps, the numerical expressions and numerical values set forth in these embodiments do not limit the scope of the present disclosure unless specifically stated otherwise.
[0032] SUMMARY OF THE DISCLOSURE
[0033] In the process of implementing the present disclosure, the inventors found that when a multi-channel sound playback system (hereinafter referred to as the system) is used in a mobile terminal space, a home space, and other environments, if the number of channels of the audio signal to be played is lower than the number of channels of the multi-channel sound playback system, for example, the audio signal to be played is a mono or dual-channel signal, it is usually necessary to map the audio signal to be played to a multi-channel for playback. How to map the audio signal to be played to a sound player placed in the actual space for playback to achieve the desired sound effect has become a technical problem that needs to be solved urgently.
[0034] Exemplary Overview
[0035] Figure 1 This is an exemplary application scenario of the method for adjusting audio signals in multiple scenarios provided by the present disclosure. Figure 1As shown, a device 12 for adjusting audio signals in multiple scenes is provided in the second scene 11, which is used to execute the method for adjusting audio signals in multiple scenes of the embodiment of the present disclosure. In addition, multiple sound players 13 are placed in the second scene 11. In the figure, multiple sound players 13 take 8 sound players as an example, including sound player 131, sound player 132, sound player 133, sound player 134, sound player 135, sound player 136, sound player 137 and sound player 138, so as to realize the sound effect of multi-channel playback in the second scene 11, such as realizing 7.1 surround sound. The listening position 14 and the sound source 15 in the second scene 11 are shown in the figure. The listening position 14 can be the middle position of the user area in the second scene or other specified positions. The sound source 15 is a position at a preset distance from the listening position in a preset direction of the listening position (for example, in front of the user at the listening position), for example, the sound source 15 is set 2 meters in front of the user at the listening position. The playback effect of the sound emitted from the sound source 15 is simulated by multiple sound players 13. By using the method for adjusting audio signals in multiple scenes of the embodiment of the present disclosure, the first position information (such as the position information of the sound source 15 in the figure) of the sound source 15 corresponding to the first audio signal of the first channel number (for example, mono or dual channel) in the first scene can be determined; the second position information of the sound players of the second channel number (such as the sound players of 8 channels in the figure) in the second scene 11 can be determined; based on the first audio signal of the first channel number, the second audio signal of the second channel number can be determined; based on the second position information and the first position information, the adjustment parameters corresponding to the second audio signals of the second channel number can be determined; based on the adjustment parameters corresponding to the second audio signals of the second channel number, the second audio signal of the second channel number can be adjusted to obtain the third audio signals corresponding to the sound players 13 of the second channel number, so that the third audio signal can be more adapted to the placement of the sound players in the second scene 11, so as to improve the playback effect of the first audio signal in the second scene 11 and enhance the auditory experience of the user in the second scene 11. The first scene can be a scene where the sound players are placed in a standard manner, and the second scene 11 can be any scene different from the first scene. For example, the placement of at least one audio player in the second scene 11 is different from that in the first scene. The second scene 11 may be, for example, a mobile terminal space (such as a vehicle space), a home space, or other scenes.
[0036] Exemplary Methods
[0037] Figure 2 1 is a flow chart of a method for adjusting audio signals in multiple scenarios provided by an exemplary embodiment of the present disclosure. This embodiment can be applied to electronic devices, such as mobile terminals, signal processing devices for home scenarios, etc. Figure 2As shown, the method of the embodiment of the present disclosure may include the following steps:
[0038] Step 210 : Determine first position information of a sound source corresponding to a first audio signal with a first number of channels in a first scene in a second scene.
[0039] Among them, the first scene can be a scene in which the sound player is placed in a preset placement mode. The preset placement mode can be, for example, a specified standard placement mode or other placement modes. The number of first channels can be mono, dual channels, etc. The first audio signal is an audio signal that has been debugged for the placement mode of the sound player of the first scene in the first scene, and can achieve the desired sound effect by mapping it to each sound player of the first scene through fixed component parameters. For example, the first scene is a scene in which a multi-channel (for example, 5.1 channels, 7.1 channels, 7.1.4 channels, etc.) sound player is placed in a standard manner. The first audio signal is mapped to the multi-channel through fixed component parameters, and the audio signals corresponding to the multi-channel sound players of the first scene are obtained, and the multi-channel sound players of the first scene are played to achieve a multi-channel stereo surround sound effect. The sound source refers to the sound source position simulated by the sound player in a certain scene. For example, the sound source can be a position at a preset distance from the listening position in a preset direction (for example, front, left front, right front, etc.) of a specified listening position (which can be called a preset listening position) in the scene. The first position information of the sound source in the second scene can be determined according to the preset listening position in the second scene.
[0040] Step 220: Determine the second position information of the sound players with a second number of channels in the second scene.
[0041] The second scene may be a scene that is different from the first scene in at least one of the number of sound players, the placement of the sound players, etc. For example, the number of sound players in the second scene is different from that in the first scene, or the placement position of at least one sound player in the second scene is different from that in the first scene. The first position information of the sound source corresponding to the first audio signal in the first scene in the second scene refers to the position coordinates of the sound source of the first scene in the spatial coordinate system of the second scene. The second number of channels may be 1, 2, 3, 4, 5, etc. In order to achieve better sound effects, the second number of channels may be multi-channel. For example, the sound players of the second number of channels may include multi-channel sound players such as 2.1 channels, 5.1 channels, 5.1.2 channels, 7.1 channels, 7.1.4 channels, etc. The second position information of the sound players of the second number of channels in the second scene may include the position coordinates of each sound player of the sound players of the second number of channels in the spatial coordinate system of the second scene. The spatial coordinate system of the second scene may be a coordinate system with a preset position in the second scene as the origin. The preset position may be any position in the second scene. Optionally, the preset position may be a position in the second scene that coincides with the designated listening position. For example, the preset position may be the middle point of the user area in the second scene, and the middle point also serves as the designated listening position.
[0042] In some optional embodiments, the position coordinates of the sound players with the second number of channels in the spatial coordinate system of the second scene can be determined based on the relative relationship between the placement positions of the sound players with the second number of channels in the second scene and the origin of the spatial coordinate system of the second scene, as the second position information of the sound players.
[0043] It should be noted that step 210 and step 220 may be performed in any order.
[0044] Step 230: Determine a second audio signal with a second number of channels based on the first audio signal with a first number of channels.
[0045] The second audio signal of each channel of the second number of channels is used as the initial audio signal (or audio signal to be adjusted) of the channel.
[0046] In some optional embodiments, the first audio signal of the first channel number can be mapped to the second audio signal of the second channel number according to a preset mapping method. The preset mapping method may, for example, include: copying the first audio signal to the second channel number, each copy as the second audio signal of one channel in the second channel number; or, mapping the first audio signal of the first channel number to each channel of the second channel number according to a fixed component parameter to obtain the second audio signal of the second channel number. Exemplarily, if the first channel number is mono, the first audio signal can be copied to the second channel number, each copy as the second audio signal of one channel. If the first channel number is dual-channel, the dual-channel first audio signal can be down-mixed into a mono audio signal according to a fixed component parameter, and the mono audio signal can be used as the second audio signal of each channel in the second channel number.
[0047] In some optional embodiments, if the second number of channels includes a low frequency (Low Frequency Effect, referred to as LFE) channel (which can be called a channel of the second preset type of frequency), for example, .1 of the 5.1 channel and the 7.1 channel is a low frequency channel, then the second audio signal of the low frequency channel can be determined based on the low frequency part of the first audio signal of the first number of channels. For the other channels (which can be called the channels of the first preset type of frequency) except the low frequency channel in the second number of channels, the first audio signal of the first number of channels is mapped to the second audio signal of the other channels according to the corresponding mapping method. Based on the second audio signal of the low frequency channel and the second audio signal of the other channels, the second audio signal of the second number of channels is obtained.
[0048] Step 240: Determine adjustment parameters corresponding to the second audio signals of the second channel number based on the second position information and the first position information.
[0049] The adjustment parameter corresponding to the second audio signal may include at least one of a phase parameter and a gain parameter. The phase parameter is a parameter describing the time relationship between multiple identical audio signals. The gain parameter is a parameter describing the intensity or amplitude of an audio signal. The gain adjustment can be used to control the volume. The adjustment parameter is used to adjust the second audio signal to ensure that each sound player can work better together in the second scenario to achieve better playback sound effects.
[0050] In some optional embodiments, when the second number of channels includes a low-frequency channel, the adjustment parameter corresponding to the second audio signal of the low-frequency channel may be zero, that is, the second audio signal of the low-frequency channel does not participate in the adjustment of phase and gain, and may be directly played as the audio signal (which may be called the third audio signal) of the sound player of the low-frequency channel in the second scene.
[0051] Step 250: Based on the adjustment parameters corresponding to the second audio signals of the second channels, the second audio signals of the second channels are adjusted to obtain third audio signals corresponding to the sound players of the second channels.
[0052] The adjustment of the second audio signal may include phase adjustment and / or gain adjustment. By adjusting the second audio signal of the second channel number, the third audio signals corresponding to the sound players of the second channel number are obtained, so that each third audio signal can be played by the corresponding sound player, and a better playback sound effect is achieved in the second scenario.
[0053] In some optional embodiments, if the second number of channels includes a low-frequency channel, the second audio signal of the low-frequency channel can be directly used as the third audio signal corresponding to the sound player of the low-frequency channel without adjustment. The second audio signals of the other channels except the low-frequency channel are adjusted to obtain the third audio signals corresponding to the sound players of the other channels. Based on the third audio signal of the low-frequency channel and the third audio signals of the other channels, the third audio signals corresponding to the sound players of the second number of channels are obtained. For example, if the second number of channels is 7.1 channels, .1 represents the low-frequency channel, the second audio signal of the low-frequency channel is determined by the low-frequency part of the first audio signal, and the second audio signal of the low-frequency channel is directly used as the third audio signal of the sound player of the low-frequency channel. The second audio signals of the 7 other channels are adjusted to obtain the third audio signals corresponding to the sound players of the 7 other channels, and the third audio signal of the sound player of the low-frequency channel and the third audio signal of the sound player of the 7 other channels constitute the third audio signals corresponding to the sound players of the second number of channels. Each third audio signal can be transmitted to the sound player of the corresponding channel in the second scene for playback, thereby achieving a 7.1-channel stereo surround sound effect in the second scene and improving the auditory experience of the user in the second scene.
[0054] The method for adjusting audio signals in multiple scenarios provided in this embodiment can adjust the second audio signal obtained by mapping the first audio signal in the first scenario in combination with the position of the sound player and the position of the sound source in the second scenario, so that the adjusted third audio signal is more suitable for the placement of the sound player in the second scenario, thereby improving the sound playback effect in the second scenario and enhancing the user's auditory experience in the second scenario. Moreover, in the case of obtaining an audio signal in a first scenario (such as a standard placement scenario for a sound player), the method of the embodiment of the present disclosure can be used to obtain an audio signal of a sound player in any second scenario that is different from the placement of the first scenario, thereby improving the scene adaptability of the audio signal in the first scenario while ensuring the sound effect of the second scene.
[0055] Figure 3 It is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure.
[0056] In some optional embodiments, in the above Figure 2 Based on the embodiment shown, Figure 3 As shown, the step 210 of determining the first position information of the sound source corresponding to the first audio signal with the first number of channels in the first scene in the second scene may include:
[0057] Step 2110, determining a preset listening position for the second scene.
[0058] The preset listening position of the second scene may be specified by the user according to the specific situation of the second scene. For example, the preset listening position may be the middle point or other position of the user's listening area in the second scene, and is not specifically limited.
[0059] Step 2120: Obtain relative position information of the sound source specified by the user relative to the preset listening position.
[0060] The relative position information of the sound source relative to the preset listening position may include the distance and direction of the sound source relative to the preset listening position, or the relative position information may include the relative position coordinates of the sound source relative to the preset listening position. For example, the relative position information is that the distance d from the preset listening position in a first direction of the preset listening position (for example, in front of the user when the user listens at the preset listening position) is d.
[0061] In some optional embodiments, the user may set the relative position information of the sound source in the second scene relative to the preset listening position according to the relative position relationship of the sound source in the first scene relative to the preset listening position.
[0062] Step 2130: Determine first position information of the sound source in the second scene based on the preset listening position and the relative position information.
[0063] In the case where the user presets the sound field, the user can pre-configure the parameters of the sound source relative to the preset listening position (i.e., relative position information). The relative position information represents the relative position relationship between the sound source and the preset listening position, and based on the relative position information of the sound source relative to the preset listening position, the first position information of the sound source in the second scene can be determined.
[0064] In some optional embodiments, the preset listening position has certain position coordinates in the spatial coordinate system of the second scene, and the first position information of the sound source in the spatial coordinate system of the second scene can be determined based on the relative position information of the sound source relative to the preset listening position and the position coordinates of the preset listening position in the second scene.
[0065] In some optional embodiments, in the case where the relative position relationship between the sound source and the preset listening position cannot be obtained from the first audio signal, the first position information of the sound source in the second scene can be determined based on the relative position information of the sound source relative to the preset listening position preset by the user. For example, if the first audio signal of the first channel number is a monophonic audio signal, and the relative position relationship between the sound source and the preset listening position cannot be estimated, the first position information of the sound source in the second scene can be determined based on the relative position information of the sound source relative to the preset listening position. In practical applications, for the first audio signal of dual channels, the first position information of the sound source in the second scene can also be determined based on the relative position information of the sound source specified by the user relative to the preset listening position.
[0066] In the embodiments of the present disclosure, since the relative position information of the sound source relative to the preset listening position can be specified by the user, and the preset listening position has a certain position coordinate in the second scene, the first position information of the sound source in the second scene can be effectively determined based on the relative position information of the sound source relative to the preset listening position, so that the sound source of the first scene can be placed in the second scene, providing an accurate and effective sound source position for the sound playback of the sound player in the second scene.
[0067] Figure 4 It is a flowchart of a method for adjusting audio signals in multiple scenarios provided by yet another exemplary embodiment of the present disclosure.
[0068] In some optional embodiments, in the above Figure 2 Based on the embodiment shown, Figure 4 As shown, the step 210 of determining the first position information of the sound source corresponding to the first audio signal with the first number of channels in the first scene in the second scene may include:
[0069] Step 21a0: determining a left channel signal and a right channel signal based on a first audio signal with a first number of channels.
[0070] In the case that the first channel number is dual channels, the first audio signal includes a left channel signal and a right channel signal. Therefore, the left channel signal and the right channel signal can be determined based on the first audio signal with the first channel number.
[0071] Step 21b0, determining the distance and direction of the sound source relative to the preset listening position based on the left channel signal and the right channel signal.
[0072] Among them, when the first audio signal of the first channel number includes a left channel signal and a right channel signal, the left channel signal and the right channel signal have a certain phase difference and sound pressure difference. The azimuth (i.e., direction) of the sound source relative to the preset listening position can be estimated based on the phase difference, and the distance of the sound source relative to the preset listening position can be estimated based on the sound pressure difference, thereby obtaining the distance and direction of the sound source relative to the preset listening position.
[0073] In some optional embodiments, a DOA (Direction Of Arrival) algorithm may be used to estimate the azimuth of the sound source relative to a preset listening position according to a phase difference between a left channel signal and a right channel signal.
[0074] In some optional embodiments, the distance of the sound source relative to the preset listening position can be estimated based on the sound pressure difference between the left channel signal and the right channel signal in combination with the distance attenuation model. Specifically, it can be assumed that the standard volume of the sound source should be 0dbfs (Decibels Full Scale, a unit representing the level of a digital audio signal), and the actual volume of the sound source is calculated based on the left channel signal and the right channel signal, and then the sound pressure difference between the actual volume and the standard volume is calculated, and substituted into the distance attenuation model to obtain the distance from the sound source to the preset listening position. The distance attenuation model is a mapping function of the sound volume attenuation with distance, which can be used to predict the distance between the sound source and the preset listening position. The closer the distance, the louder the sound heard at the preset listening position should be, and conversely, the farther the distance, the smaller the sound heard at the preset listening position should be.
[0075] Step 21c0: determining first position information of the sound source in the second scene according to the distance and direction of the sound source relative to the preset listening position.
[0076] Among them, when the distance and direction of the sound source relative to the preset listening position are obtained, the specific operation of determining the first position information of the sound source according to the distance and direction of the sound source relative to the preset listening position can be referred to the above embodiment and will not be repeated here.
[0077] In an embodiment of the present disclosure, when the first audio signal of the first channel number includes a left channel signal and a right channel signal, the distance and direction of the sound source relative to a preset listening position can be automatically determined based on the left channel signal and the right channel signal to determine the first position information of the sound source, thereby providing an accurate and effective sound source position for sound playback of the sound player in the second scenario, and can reduce the user's operations of setting the relative position information of the sound source relative to the preset listening position, thereby improving the user experience.
[0078] Figure 5 It is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure.
[0079] In some optional embodiments, based on any of the above embodiments, Figure 5 As shown, step 240 of determining adjustment parameters corresponding to the second audio signals of the second channel number based on the second position information and the first position information may include:
[0080] Step 2410: Determine the distance between the sound source and each sound player according to the second position information and the first position information.
[0081] The second position information may include the position coordinates of each sound player in the second number of sound players in the spatial coordinate system of the second scene, and the first position information may include the position coordinates of the sound source in the spatial coordinate system of the second scene. According to the position coordinates of each sound player and the position coordinates of the sound source, the distance between the sound source and each sound player may be calculated. Specifically, the distance between the sound source and each sound player may be calculated based on a distance calculation formula between two points.
[0082] Step 2420: Determine adjustment parameters corresponding to the second audio signals of the second audio channels according to the distances between the sound sources and the sound players.
[0083] Among them, the distance between the sound source and the sound players of the second channel number can characterize the transmission or reflection path of the sound in the air. Combined with the sound effect expected to be achieved in the second scene and the transmission path of the sound played by each sound player, the phase, gain and other adjustment parameters corresponding to the second audio signals of the second channel number are determined, which are used to adjust the second audio signal so that the adjusted third audio signal can achieve better playback sound effect in the second scene.
[0084] In the embodiments of the present disclosure, since the distances between the sound sources and the sound players of the second number of channels can characterize the transmission or reflection paths of the sounds in the air, the adjustment parameters corresponding to the second audio signals are determined according to the distances between the sound sources and the sound players, so that the adjustment parameters can characterize the difference in sound transmission in the second scene relative to the first scene, thereby improving the accuracy of the adjustment parameters, and then using the adjustment parameters to adjust the second audio signals, so that the third audio signals obtained by the adjustment can achieve better playback sound effects in the second scene, thereby enhancing the auditory experience of the listeners in the second scene.
[0085] In some optional embodiments, step 2420 of determining the adjustment parameters corresponding to the second audio signals of the second channel quantity respectively according to the distances between the sound source and each sound player respectively, may include: determining the adjustment parameters corresponding to the second audio signals of the second channel quantity respectively according to the distances between the sound source and each sound player respectively, and the relative relationship between each sound player and the preset listening position of the second scene respectively.
[0086] Among them, the relative relationship between each sound player and the preset listening position may include the direction of each sound player relative to the preset listening position, and the direction may include a front direction and a non-front direction. The front direction is the front direction relative to the user (i.e., the listener) at the preset listening position, that is, the direction the user is facing. For example, the relative relationship between the left front, center, and right front sound players and the preset listening position in the 5.1-channel sound player are all front directions. The left rear and right rear sound players are in the non-front direction of the preset listening position. In the case where the low-frequency channel is included in the channels of the second number of channels, the sound player of the low-frequency channel may not calculate the adjustment parameter or the adjustment parameter is a preset value (zero), and the distance between the sound player of the low-frequency channel and the sound source and the relative relationship between the sound player of the low-frequency channel and the preset listening position of the second scene may not be considered.
[0087] In some optional embodiments, for each sound player, the sound player with a different relative relationship to the preset listening position has a different way of determining the adjustment parameter. For example, the sound player in the front direction of the preset listening position is used to simulate the transmission of sound from the sound source to the preset listening position. The sound player not in the front direction of the preset listening position is used to simulate the transmission of sound from the sound source to the sound player and then reflected to the preset listening position. The sound transmission paths are different, so the transmission distances used to determine the adjustment parameters are different.
[0088] In the disclosed embodiment, since sound players in different relative relationships need to simulate different sound transmission paths, the adjustment parameters are determined in combination with the distance between the sound source and the sound player in the second scene, and the relative relationship between the sound player and the preset listening position. This can improve the accuracy of the adjustment parameters corresponding to each second audio signal, and further enhance the playback sound effect in the second scene.
[0089] Figure 6 It is a flowchart of determining adjustment parameters provided by an exemplary embodiment of the present disclosure.
[0090] In some optional embodiments, determining the adjustment parameters corresponding to the second audio signals of the second channel number respectively according to the distances between the sound source and each sound player, and the relative relationship between each sound player and the preset listening position of the second scene respectively, may include:
[0091] Step 24210, determining a reference player from among the sound players based on the distances between the sound source and each sound player.
[0092] The reference player may be a sound player that is closest to the sound source among the sound players with the second number of channels.
[0093] Step 24220: Determine adjustment parameters of the second audio signal corresponding to the reference player according to a preset method.
[0094] The preset method may include that the phase of the reference player remains unchanged, the gain of the reference player is determined according to the distance between the reference player and the sound source, the phase of the adjustment parameter of the reference player is zero, that is, the phase of the reference player is not adjusted, and the phases of other sound players are adjusted based on the reference player.
[0095] Step 24230, for any sound player among the sound players except the reference player, in response to the relative relationship between the sound player and the preset listening position satisfying the first condition, based on the first distance between the sound player and the sound source and the second distance between the reference player and the sound source, determine the adjustment parameters of the second audio signal corresponding to the sound player.
[0096] Among them, any sound player except the reference player in the sound players of the second number of channels can be called any other sound player (or the first sound player). The first condition can refer to the front of the sound player at the preset listening position. If the relative relationship between the first sound player and the preset listening position satisfies the first condition, it means that the front direction of the first sound player at the preset listening position, for example, the left front sound player or the right front sound player in the 5.1-channel sound player is located in the front direction of the preset listening position, and the first condition is satisfied, then based on the distance between the first sound player and the sound source (called the first distance) and the distance between the reference player and the sound source (called the second distance), the adjustment parameter of the second audio signal corresponding to the first sound player is determined.
[0097] In some optional embodiments, when the second number of channels includes a low-frequency channel, the reference player is a sound player other than the sound player of the low-frequency channel in the second number of channels. The sound player in the above step 24230 is any first sound player other than the sound player of the low-frequency channel and the reference player.
[0098] In some optional embodiments, for a first sound player whose relative relationship with a preset listening position satisfies a first condition, an adjustment parameter of a second audio signal corresponding to the first sound player can be determined based on a first distance between the first sound player and the sound source and a second distance between a reference player and the sound source.
[0099] Step 24240, for any sound player among the sound players except the reference player, in response to the relative relationship between the sound player and the preset listening position not satisfying the first condition, determine the third distance between the sound player and the preset listening position; based on the first distance between the sound player and the sound source, and the third distance between the sound player and the preset listening position, determine the adjustment parameters of the second audio signal corresponding to the sound player.
[0100] The distance between the first sound player and the preset listening position (called the third distance) can be calculated based on the position coordinates of the sound player (i.e., the first sound player) in the spatial coordinate system of the second scene and the position coordinates of the preset listening position in the spatial coordinate system of the second scene. If the relative relationship between the first sound player and the preset listening position does not meet the first condition, the adjustment parameter of the second audio signal corresponding to the sound player is determined in combination with the first distance between the first sound player and the sound source and the third distance between the first sound player and the preset listening position.
[0101] In the disclosed embodiment, for sound players having different relative relationships with the preset listening position, different methods are used to determine corresponding adjustment parameters, so that different sound players can simulate different sound transmission methods, thereby improving the playback sound effect in the second scenario.
[0102] In some optional embodiments, the adjustment parameter may include at least one of a phase parameter and a gain parameter.
[0103] In some optional embodiments, determining the adjustment parameter of the second audio signal corresponding to the sound player based on the first distance between the sound player and the sound source and the second distance between the reference player and the sound source in step 24230 may include:
[0104] Based on the first distance between the sound player and the sound source and the second distance between the reference player and the sound source, a first distance difference is determined; based on the first distance difference and a first mapping relationship between a preconfigured distance difference and a phase, a phase parameter corresponding to the sound player is determined; and / or, based on the first distance between the sound player and the sound source and a second mapping relationship between a preconfigured distance and a gain, a gain parameter corresponding to the sound player is determined.
[0105] The first mapping relationship between the distance difference and the phase may be a mapping function of the distance difference and the propagation speed of sound in the air. The second mapping relationship between the distance and the gain may be a mapping function of the distance between the sound source and the sound player.
[0106] Exemplarily, the first distance between the sound player and the sound source can be expressed as D1, the second distance between the reference player and the sound source can be expressed as D0, and the first distance difference △d can be expressed as △d=D1-D0. The first mapping relationship can be expressed as: Represents the phase. The second mapping relationship can be expressed as:
[0107]
[0108] Wherein, G (db) represents gain, the unit is db (decibel), and r = D1.
[0109] In the disclosed embodiment, since the sound player in front of the preset listening position is used to simulate the transmission of sound from the sound source to the preset listening position, the first mapping relationship represents a mapping function of the distance difference between a sound player and the sound source relative to a reference player, the sound propagation speed and the phase, and the second mapping relationship represents a mapping function of the distance of a sound player relative to the sound source and the gain. Therefore, for the sound player in front of the preset listening position, the phase parameter and the gain parameter can be accurately calculated through the first mapping relationship and the second mapping relationship, thereby providing accurate and effective adjustment parameters for adjusting the second audio signal.
[0110] In some optional embodiments, determining the adjustment parameter of the second audio signal corresponding to the sound player according to the first distance between the sound player and the sound source and the third distance between the sound player and the preset listening position in step 24240 may include:
[0111] Determine the distance and value of the first distance and the third distance corresponding to the sound player; determine the phase parameter of the second audio signal corresponding to the sound player based on the mapping relationship between the distance and value, the preconfigured distance and value and the phase; and / or determine the gain parameter of the second audio signal corresponding to the sound player based on the mapping relationship between the distance and value, the preconfigured distance and value and the gain.
[0112] Among them, the distance sum value of the first distance and the third distance corresponding to the sound player refers to the sum value obtained by adding the first distance and the third distance. The first distance corresponding to the sound player refers to the first distance between the sound player and the sound source, and the third distance corresponding to the sound player refers to the third distance between the sound player and the preset listening position. The mapping relationship between the preconfigured distance sum value and the phase can be called the third mapping relationship. The third mapping relationship can be a mapping function of the distance sum value and the propagation speed of sound in the air. The mapping relationship between the preconfigured distance sum value and the gain can be called the fourth mapping relationship. The fourth mapping relationship can be a mapping function of the distance sum value.
[0113] Exemplarily, the first distance between the sound player and the sound source is represented by D1, and the third distance between the sound player and the preset listening position is represented by d1, then the distance sum value can be represented by s=d1+D1. The third mapping relationship can be represented as: The fourth mapping relationship can be expressed as:
[0114]
[0115] Among them, G (db) represents gain, and the unit is db (decibel).
[0116] In the embodiment of the present disclosure, since the sound player that is not in the front of the preset listening position is used to simulate the transmission of sound from the sound source to the sound player and then reflected to the preset listening position, the propagation distance of the sound includes a first distance between the sound player and the sound source and a third distance between the sound player and the preset listening position. The third mapping relationship represents a mapping function of the distance and value of the first distance and the third distance and the phase, and the fourth mapping relationship represents a mapping function of the distance and value and the gain. Therefore, for the sound player that is not in the front of the preset listening position, the phase parameter and the gain parameter can be accurately calculated through the third mapping relationship and the fourth mapping relationship, thereby providing accurate and effective adjustment parameters for adjusting the second audio signal.
[0117] Figure 7 It is a flowchart of a method for adjusting audio signals in multiple scenarios provided by yet another exemplary embodiment of the present disclosure.
[0118] In some optional embodiments, based on any of the above embodiments, Figure 7 As shown, step 240 of determining adjustment parameters corresponding to the second audio signals of the second channel number based on the second position information and the first position information may include:
[0119] Step 2401, determining a reference player from among various sound players based on the second position information and the first position information.
[0120] The specific operation of determining the reference player in step 2401 can be found in the aforementioned embodiment and will not be described in detail here.
[0121] Step 2402: determine adjustment parameters of the second audio signal corresponding to the reference player.
[0122] The specific operation of step 2402 can be found in the above-mentioned embodiment and will not be described in detail here.
[0123] Step 2403, for any sound player among the players except the reference player, determine at least one of the phase parameter and gain parameter of the second audio signal corresponding to the sound player based on the first distance between the sound player and the sound source and the relative relationship between the sound player and the preset listening position of the second scene.
[0124] The specific operation of determining the phase parameter and the gain parameter in step 2403 can be referred to the above embodiment and will not be described in detail here.
[0125] Step 2404: Determine an adjustment parameter of a second audio signal corresponding to the sound player according to at least one of a phase parameter and a gain parameter.
[0126] In the embodiments of the present disclosure, a reference player is used as a reference to determine the phase parameters and gain parameters of other sound players as adjustment parameters of the sound player, wherein the phase parameter characterizes the time relationship between audio signals, and the gain parameter characterizes the intensity or amplitude of the audio signal. The second audio signal is adjusted by the phase parameter and the gain parameter, so that the adjusted third audio signal can achieve better playback sound effects in the second scene, thereby improving the adaptability of the audio signal to the second scene.
[0127] In some optional embodiments, determining at least one of a phase parameter and a gain parameter of a second audio signal corresponding to the sound player based on a first distance between the sound player and the sound source and a relative relationship between the sound player and a preset listening position of the second scene in step 2403 may include:
[0128] In response to the relative relationship between the sound player and the preset listening position satisfying a first condition, a phase parameter of a second audio signal corresponding to the sound player is determined based on a first distance between the sound player and the sound source, a second distance between the reference player and the sound source, and a preconfigured first mapping relationship corresponding to the phase; and / or a gain parameter of a second audio signal corresponding to the sound player is determined based on the first distance between the sound player and the sound source, and a preconfigured second mapping relationship corresponding to the gain.
[0129] The specific operation of this step can be found in the aforementioned embodiments, such as the embodiment of step 24230 and its specific operation, which will not be described in detail here.
[0130] In the embodiments of the present disclosure, since the sound player in front of the preset listening position is used to simulate the transmission of sound from the sound source to the preset listening position, the first mapping relationship represents a mapping function of the distance difference between a sound player and the sound source relative to a reference player, the sound propagation speed and the phase, and the second mapping relationship represents a mapping function of the distance of a sound player relative to the sound source and the gain. Therefore, for the sound player in front of the preset listening position, the phase parameter and the gain parameter can be accurately calculated through the first mapping relationship and the second mapping relationship, thereby providing accurate and effective adjustment parameters for the adjustment of the second audio signal.
[0131] In some optional embodiments, step 2403 determines at least one of a phase parameter and a gain parameter of a second audio signal corresponding to the sound player based on a first distance between the sound player and the sound source and a relative relationship between the sound player and a preset listening position of the second scene, including:
[0132] In response to the relative relationship between the sound player and the preset listening position not satisfying the first condition, determine the third distance between the sound player and the preset listening position; determine the distance and value of the first distance and the third distance corresponding to the sound player; based on the third mapping relationship between the distance and value, the preconfigured distance and value and the phase, determine the phase parameter of the second audio signal corresponding to the sound player; and / or, based on the fourth mapping relationship between the distance and value, the preconfigured distance and value and the gain, determine the gain parameter of the second audio signal corresponding to the sound player.
[0133] The specific operation of this step can refer to the aforementioned embodiments, such as the embodiment of step 24240 and its specific operation, which will not be described in detail here.
[0134] In the embodiment of the present disclosure, since the sound player that is not in the front of the preset listening position is used to simulate the transmission of sound from the sound source to the sound player and then reflected to the preset listening position, the propagation distance of the sound includes a first distance between the sound player and the sound source and a third distance between the sound player and the preset listening position. The third mapping relationship represents a mapping function of the distance and value of the first distance and the third distance and the phase, and the fourth mapping relationship represents a mapping function of the distance and value and the gain. Therefore, for the sound player that is not in the front of the preset listening position, the phase parameter and the gain parameter can be accurately calculated through the third mapping relationship and the fourth mapping relationship, thereby providing accurate and effective adjustment parameters for adjusting the second audio signal.
[0135] Figure 8 It is a flowchart of a method for adjusting audio signals in multiple scenarios provided by yet another exemplary embodiment of the present disclosure.
[0136] In some optional embodiments, based on any of the above embodiments, Figure 8As shown, determining the second audio signal with the second number of channels based on the first audio signal with the first number of channels in step 230 may include:
[0137] Step 2310: determine the frequency types of the channels of the second number of channels.
[0138] Among them, the frequency type may include a first preset type and a second preset type. The second preset type may be a low-frequency type, and the first preset type may be a non-low-frequency type. For example, in a 7.1.4 channel, .1 is a low-frequency channel (i.e., the second preset type), and the other 11 channels are non-low-frequency channels (i.e., the first preset type). The channels of the second number of channels may include at least one of the first preset type and the second preset type. For example, the channels of the second number of channels include multiple channels of the first preset type. For another example, the channels of the second number of channels include at least one channel of the first preset type and at least one channel of the second preset type.
[0139] Step 2320: In response to the frequency type including at least one first preset type, based on the first audio signal of the first channel number, generate second audio signals corresponding to the channels of the first preset type in the channels of the second channel number.
[0140] Among them, the second preset type of channel can be a low-frequency channel, and the low-frequency channel refers to a subwoofer channel in a multi-channel. For example, .1 in a multi-channel such as 2.1 channels, 5.1 channels, 7.1 channels, 5.1.2 channels, 7.1.4 channels, etc. represents a subwoofer channel. In the case where the second number of channels includes a low-frequency channel, the second audio signal of the low-frequency channel can be determined by the low-frequency part in the first audio signal. Alternatively, the operation of determining the second audio signal of the low-frequency channel can be avoided, and the third audio signal corresponding to the low-frequency channel can be directly determined according to the low-frequency part in the first audio signal. For the first preset type of channel other than the low-frequency channel, based on the first audio signal of the first channel number, a second audio signal corresponding to the channel of the first preset type is generated. For example, if the first audio signal of the first channel number is a mono signal, the second audio signal corresponding to each channel of the first preset type can be obtained by copying the first audio signal. If the second audio signal with the first number of channels is a dual-channel signal, the dual-channel signal may be down-mixed into a mono signal, and the obtained mono signal is used as the second audio signal corresponding to each channel of the first preset type.
[0141] Correspondingly, step 240 of determining adjustment parameters corresponding to the second audio signals of the second channel number based on the second position information and the first position information includes:
[0142] Step 240a: Determine adjustment parameters corresponding to the second audio signals of the channels of each first preset type based on the second position information and the first position information.
[0143] The specific operation of step 240a can be found in the above-mentioned embodiment and will not be described in detail here.
[0144] Step 250 of adjusting the second audio signals of the second number of channels based on the adjustment parameters respectively corresponding to the second audio signals of the second number of channels to obtain third audio signals respectively corresponding to the sound players of the second number of channels may include:
[0145] Step 250a, based on the adjustment parameters respectively corresponding to the second audio signals of the channels of the first preset type, adjust the second audio signals of the channels of the first preset type to obtain third audio signals respectively corresponding to the sound players of the channels of the first preset type.
[0146] The specific operation of step 250a can be found in the above-mentioned embodiment and will not be described in detail here.
[0147] According to the embodiments of the present disclosure, when the second scene includes a low-frequency channel, since the audio signal of the low-frequency channel does not need to be adjusted, the operation of generating a second audio signal of the low-frequency channel can be avoided, thereby ensuring the validity of the second audio signal and improving processing efficiency.
[0148] In some optional embodiments, the first audio signal with the first number of channels includes a left channel signal and a right channel signal.
[0149] The step 2320 of generating second audio signals respectively corresponding to the channels of the first preset type in the channels of the second channel number based on the first audio signal of the first channel number may include: downmixing the left channel signal and the right channel signal into a mono signal; and generating second audio signals respectively corresponding to the channels of the first preset type based on the mono signal.
[0150] The left channel signal and the right channel signal can be down-mixed into a mono signal according to the fixed component parameters. The mono signal is copied to obtain a second audio signal corresponding to each first preset type of channel as the audio signal to be adjusted (or the initial audio signal) of the first preset type of channel.
[0151] In the embodiment of the present disclosure, by downmixing the first audio signal of the dual channels in the first scene into a mono signal, it is convenient to generate the second audio signals of the other channels except the low-frequency channel in the second number of channels as the audio signals to be adjusted of the other channels, and provide the sound player of the second scene with an effective initial audio signal, and then adjust the parameters to improve the playback sound effect of the audio signal.
[0152] Fig. 9 It is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure.
[0153] In some optional embodiments, based on any of the above embodiments, Fig. 9 As shown, step 250 of adjusting the second audio signals of the second channel number based on the adjustment parameters respectively corresponding to the second audio signals of the second channel number to obtain the third audio signals respectively corresponding to the sound players of the second channel number may include:
[0154] Step 2510: Determine the physical quantity of the adjustment parameter corresponding to the second audio signal.
[0155] For any second audio signal, the physical quantity of the adjustment parameter may include at least one of a gain parameter and a phase parameter. Based on the adjustment parameter corresponding to the second audio signal, at least one of the gain parameter and the phase parameter of the adjustment parameter corresponding to the second audio signal may be obtained.
[0156] Step 2520: Determine a target physical quantity corresponding to the second audio signal based on the physical quantity.
[0157] Among them, the target physical quantity may include a first target physical quantity corresponding to the gain and a second target physical quantity corresponding to the phase. The first target physical quantity is a physical quantity that can be operated with the second audio signal. For example, the gain parameter is a parameter in db (decibel). Based on a preset conversion method, the gain parameter is converted into a first target physical quantity corresponding to the gain. The first target physical quantity corresponding to the gain is multiplied by the second audio signal to adjust the gain. For the phase parameter, physical quantity conversion may not be performed, that is, the second target physical quantity corresponding to the phase parameter is still a phase parameter.
[0158] Step 2530: adjust the second audio signal based on the target physical quantity to obtain a third audio signal.
[0159] Among them, the second audio signal can be adjusted by the first target physical quantity corresponding to the gain and the second target physical quantity corresponding to the phase parameter to obtain the third audio signal. The order of the first target physical quantity and the second target physical quantity is not limited. For example, the second audio signal can be adjusted by the first target physical quantity to obtain an adjusted signal, and then the adjusted signal can be adjusted by the second target physical quantity to obtain the third signal. Alternatively, the second audio signal can be adjusted by the second target physical quantity first, and then adjusted by the first target physical quantity.
[0160] In some optional embodiments, step 250a adjusts the second audio signals of each first preset type of channel based on the adjustment parameters respectively corresponding to the second audio signals of each first preset type of channel to obtain the third audio signals respectively corresponding to the sound players of each first preset type of channel, including the above steps 2510 to 2530. That is, for the first preset type of channel, the second audio signal is adjusted according to the above adjustment process to obtain the third audio signal, and for the second preset type of channel, the above adjustment is not required.
[0161] In some optional embodiments, the adjustment parameter corresponding to the second audio signal may only include gain, that is, the adjustment parameter includes gain but does not include phase. For example, the above-mentioned reference player does not need to adjust the phase, then the adjustment parameter includes gain but does not include phase. Alternatively, the other sound player (which can be called the second sound player) whose distance from the sound source is equal to the distance between the reference player and the sound source has a phase of zero, and it can be considered that the adjustment parameter of the second audio signal corresponding to the sound player includes gain but does not include phase. In the case where the adjustment parameter corresponding to the second audio signal includes gain, the gain can be converted into a first target physical quantity corresponding to the second audio signal, and then the second audio signal is adjusted based on the first target physical quantity to obtain the third audio signal of the channel corresponding to the second audio signal. The first target physical quantity corresponding to the second audio signal is a parameter that can be multiplied by the second audio signal. Since the gain corresponding to the second audio signal is in db (decibel), when processing the second audio signal, the gain cannot directly act on the second audio signal, therefore, it is necessary to convert the gain into a first target physical quantity that can be multiplied by the second audio signal, which is used to adjust the second audio signal and realize the gain control of the second audio signal.
[0162] The embodiment of the present disclosure converts the gain into a first target physical quantity so that the first target physical quantity can perform a specified operation with the second audio signal, thereby effectively controlling the gain of the audio signal.
[0163] Fig.10 It is a flowchart of a method for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure.
[0164] In some optional embodiments, based on any of the above embodiments, Fig.10 As shown, step 250 of adjusting the second audio signals of the second channel number based on the adjustment parameters respectively corresponding to the second audio signals of the second channel number to obtain the third audio signals respectively corresponding to the sound players of the second channel number may include:
[0165] Step 25a0: determining a phase parameter and a gain parameter based on the adjustment parameter corresponding to the second audio signal.
[0166] In the case where the adjustment parameters corresponding to the second audio signal include a gain parameter and a phase parameter, the phase parameter and the gain parameter may be determined based on the adjustment parameters.
[0167] In some optional embodiments, for part of the second audio signal, the phase parameter may be zero, or there may be no phase parameter.
[0168] Step 25b0: Based on the phase parameter, use an all-pass filter to filter the second audio signal to obtain a filtered audio signal.
[0169] Among them, the all-pass filter (APF) is a special filter whose amplitude frequency response is completely flat, but its phase response is nonlinear. This nonlinear phase response enables the all-pass filter to produce a phase shift, thereby changing the phase of the audio signal. The specific working principle of the all-pass filter is not described in detail. The second audio signal is filtered by an all-pass filter, so that the phase of the second audio signal can be changed to obtain a filtered audio signal, so that the phase of the filtered audio signal is changed relative to the second audio signal, which is more in line with the sound effect requirements of the second scene.
[0170] Step 25c0: Based on the gain parameter, adjust the gain of the filtered audio signal to obtain a third audio signal.
[0171] The specific operation of adjusting the gain of the filtered audio signal based on the gain parameter can be referred to the aforementioned embodiment, which will not be described in detail here.
[0172] In the disclosed embodiment, phase adjustment is achieved through an all-pass filter. The all-pass filter can characterize a nonlinear phase response. Combined with gain adjustment, the adjusted third audio signal is made to better meet the sound effect requirements of the second scene, thereby improving the playback sound effect of the sound player of the second scene.
[0173] In some optional embodiments, step 250a adjusts the second audio signals of each first preset type of channel based on the adjustment parameters respectively corresponding to the second audio signals of each first preset type of channel to obtain third audio signals respectively corresponding to the sound players of each first preset type of channel, including the above-mentioned steps 25a0 to 25c0.
[0174] Fig.11 It is a flowchart of a method for adjusting audio signals in multiple scenarios provided by yet another exemplary embodiment of the present disclosure.
[0175] In some optional embodiments, based on any of the above embodiments, Fig.11As shown, step 250 of adjusting the second audio signals of the second channel number based on the adjustment parameters respectively corresponding to the second audio signals of the second channel number to obtain the third audio signals respectively corresponding to the sound players of the second channel number may include:
[0176] Step 2501: Determine a phase parameter and a gain parameter based on an adjustment parameter corresponding to a second audio signal.
[0177] Step 2502: Based on the gain parameter, perform gain adjustment on the second audio signal to obtain an adjusted audio signal.
[0178] Step 2503: Based on the phase parameter, use an all-pass filter to filter the adjusted audio signal to obtain a third audio signal.
[0179] The specific operations of step 2501 to step 2503 can refer to the above embodiment, the difference is that the order of gain and phase adjustment is different, which will not be repeated here.
[0180] In the disclosed embodiment, phase adjustment is achieved through gain adjustment in combination with an all-pass filter. The all-pass filter can characterize a nonlinear phase response, so that the adjusted third audio signal better meets the sound effect requirements of the second scene, thereby improving the playback sound effect of the sound player of the second scene.
[0181] In some optional embodiments, step 250a adjusts the second audio signals of the channels of the first preset type based on the adjustment parameters corresponding to the second audio signals of the channels of the first preset type, and obtains the third audio signals corresponding to the sound players of the channels of the first preset type, including the above steps 2501 to 2503. That is, for the channels of the first preset type, the second audio signals are adjusted through the above process, and for the channels of the second preset type (such as the low-frequency channel), the above phase and gain adjustment operations can be avoided.
[0182] In some optional embodiments, such as Figure 8 As shown, the method of the embodiment of the present disclosure may also include:
[0183] Step 310: In response to the frequency type further comprising a second preset type, a signal of a frequency of a second preset type is determined based on the first audio signal of the first channel number.
[0184] The second preset type refers to a low-frequency type, and the low-frequency signal can be extracted from the first audio signal of the first channel number. The extraction method can be based on a frequency threshold, that is, the part of the first audio signal below the frequency threshold is extracted as the low-frequency signal.
[0185] In some optional embodiments, the first audio signal of the first channel number may be filtered by a low-pass filter to obtain a low-frequency signal.
[0186] Step 250 of adjusting the second audio signals of the second number of channels based on the adjustment parameters respectively corresponding to the second audio signals of the second number of channels to obtain third audio signals respectively corresponding to the sound players of the second number of channels, further includes:
[0187] Step 250b: Determine, based on the signal of the second preset type of frequency, a third audio signal corresponding to the sound player of the second preset type of channel in the second number of channels.
[0188] Among them, after obtaining the low-frequency signal of the first audio signal, the third audio signal corresponding to the sound player of the low-frequency channel in the second scene can be determined according to the low-frequency signal, avoiding determining the second audio signal of the low-frequency channel and adjusting the second audio signal of the low-frequency channel to ensure the effectiveness of the third audio signal of the low-frequency channel.
[0189] In some optional embodiments, when the first audio signal with the first number of channels is a two-channel audio signal (i.e., including a left channel signal and a right channel signal), the low-frequency portion of the left channel signal and the low-frequency portion of the right channel signal can be down-mixed into a mono low-frequency signal according to a fixed component parameter, and the mono low-frequency signal is determined as the third audio signal corresponding to the sound player of the low-frequency channel. When the first audio signal with the first number of channels is a mono audio signal, the low-frequency portion of the first audio signal can be determined as the third audio signal of the low-frequency channel.
[0190] Step 250c, based on the third audio signals corresponding to the sound players of the second preset type of channels and the third audio signals corresponding to the sound players of the first preset type of channels, determine the third audio signals corresponding to the sound players of the second number of channels.
[0191] Among them, the sound player of the low-frequency channel (i.e., the channel of the second preset type) and the sound players of other channels (i.e., the channels of the first preset type) constitute the sound players of the second number of channels. Therefore, the third audio signal corresponding to the sound player of the low-frequency channel and the third audio signals corresponding to the sound players of each first preset type of channel respectively constitute the third audio signals corresponding to the sound players of the second number of channels respectively.
[0192] In some optional embodiments, the third audio signal corresponding to the second preset type of channel can be transmitted to the sound player of the second preset type of channel, and the third audio signal of each first preset type of channel can be transmitted to the corresponding type of sound player, and each player plays its own third audio signal to achieve the desired playback sound effect in the second scene.
[0193] In the embodiment of the present disclosure, when the second scene includes a sound player of a low-frequency channel, the low-frequency signal is determined by the first audio signal of the first channel number, and the third audio signal for determining the sound player of the low-frequency channel can ensure the subwoofer sound effect of the sound player of the low-frequency channel, thereby improving the sound quality in the second scene, strengthening the bass band, creating an atmosphere, and increasing dynamics and passion.
[0194] In some optional embodiments, Fig.12 is a flowchart of a method for adjusting an audio signal in multiple scenarios provided by an exemplary embodiment of the present disclosure. The second preset type is a low-frequency type, and the first preset type is a non-low-frequency type, such as Fig.12 As shown, the process of the method may include the following steps:
[0195] Step 410, establish a spatial coordinate system for the second scene. That is, establish a spatial coordinate system for the second scene according to a preset coordinate system rule, and determine the position information (i.e., second position information) of each speaker (i.e., sound player) in the second scene in the spatial coordinate system. The preset coordinate system rule may be, for example, a left-hand rule or a right-hand rule.
[0196] Step 420: determine the relative position coordinates of the sound source based on the original audio signal. The original audio signal is the first audio signal with the first number of channels in the first scene. The relative position coordinates of the sound source are the relative position coordinates of the sound source relative to the preset listening position.
[0197] Step 430 , extract the low-frequency part from the original audio signal, and determine the target audio signal of the speaker of the low-frequency channel (ie, the third audio signal corresponding to the sound player of the low-frequency channel) according to the low-frequency part.
[0198] Step 440: Place the sound source in the spatial coordinate system of the second scene, that is, determine the first position information of the sound source in the second scene according to the relative position coordinates of the sound source relative to the preset listening position and the position information of the preset listening position in the second scene.
[0199] Step 450: Generate an initial audio signal of a non-low-frequency channel (ie, a second audio signal) according to fixed component parameters of the original audio signal.
[0200] Step 460: Generate adjustment parameters of the non-low-frequency channel according to the position information (second position information) of the speaker of the non-low-frequency channel in the spatial coordinate system and the first position information of the sound source.
[0201] Step 470, adjusting the initial audio signal of the non-low-frequency channel according to the adjustment parameter of the non-low-frequency channel to obtain the target audio signal of the non-low-frequency channel (ie, the third audio signal of the speaker of the non-low-frequency channel).
[0202] Step 480, playing the corresponding target audio signal through each speaker of the second scene, that is, transmitting the target audio signal of the low-frequency channel to the speaker of the low-frequency channel, so that the speaker of the low-frequency channel converts the target audio signal of the low-frequency channel into a sound signal for playing, and transmitting the target audio signal of the non-low-frequency channel to the corresponding speaker of the non-low-frequency channel, so that the speaker of the non-low-frequency channel converts the corresponding target audio signal into a sound signal for playing.
[0203] The method for adjusting audio signals in multiple scenarios provided by the embodiment of the present disclosure can realize effective mapping of the first audio signal to a multi-channel sound player in any second scenario based on the first audio signal in the first scenario, and obtain the third audio signals corresponding to the sound players in the second scenario. Since the third audio signal is an audio signal after the initial audio signal is adjusted in combination with the placement position of the sound player in the second scenario, the position of the sound source, and the preset listening position, the third audio signal is more in line with the sound effect requirements of the second scenario, and the playback sound effect in the second scenario is effectively improved. Using the method of the embodiment of the present disclosure, the first mono or dual-channel audio signal in the debugged standard placement scenario (first scenario) can be mapped to a multi-channel sound player in any non-standard placement scenario (second scenario), and better playback sound effects can also be achieved in non-standard placement scenarios, so that the first audio signal of the first scene can be used in various non-standard placement scenarios, improving the scene adaptability of the first audio signal.
[0204] In some optional embodiments, Fig.13 FIG. 1 is a schematic diagram showing the principle of determining adjustment parameters provided by an exemplary embodiment of the present disclosure. Fig.13As shown, the distance between sound player A and the sound source 15 is D1, the distance between sound player B and the sound source 15 is D2, the distance between sound player C and the sound source 15 is D3, the distance between sound player D and the sound source 15 is D4, ... The distance between sound player D and the preset listening position 14 (i.e., the third distance) is d4. Sound player B is the sound player closest to the sound source 15 in front of the preset listening position 14, so sound player B is used as the reference player. For sound player A in front of the preset listening position 14, the relative relationship between sound player A and the preset listening position 14 satisfies the first condition. Based on the first distance D1 between sound player A and the sound source 15 and the second distance D2 between reference player B and the sound source, the phase of the second audio signal corresponding to sound player A is determined according to the following first mapping relationship and second mapping relationship. and gain G A :
[0205]
[0206] Wherein, 340 represents the propagation speed of sound in air. r1=D1.
[0207] In addition, the relative relationship between the sound player C, the sound player D, the sound player E and the sound player F and the preset listening position 14 does not meet the first condition. Taking the sound player D as an example, the third distance between the sound player D and the preset listening position 14 is d4, and the sound player D is used to simulate the sound effect of the sound of the sound source 15 being reflected from the sound player D to the preset listening position 14. Therefore, according to the first distance between the sound player D and the sound source 15 and the third distance between the sound player D and the preset listening position 14, the phase of the second audio signal corresponding to the sound player D is determined according to the following third mapping relationship and fourth mapping relationship: and gain G D :
[0208]
[0209] Among them, r2=D4+d4.
[0210] For any second audio signal, determining the component corresponding to the second audio signal (ie, the first target physical quantity) based on the gain corresponding to the second audio signal can be achieved through the following conversion relationship:
[0211] G(db)=20*log 10 (y)
[0212] Among them, G (db) represents gain, and y represents component. According to this conversion relationship, the gain G D Convert to component y D, obtain the component of the second audio signal corresponding to the sound player D, adjust the second audio signal based on the component to obtain the adjusted audio signal, and determine the third audio signal corresponding to the sound player D based on the adjusted audio signal.
[0213] The above-mentioned embodiments of the present disclosure may be implemented separately or in any combination without conflict. The specific configuration may be based on actual needs and the present disclosure does not limit this.
[0214] Any method for adjusting audio signals in multiple scenarios provided by the embodiments of the present disclosure can be performed by any appropriate electronic device with data processing capabilities, including but not limited to: electronic devices such as terminal devices and servers. Alternatively, any method for adjusting audio signals in multiple scenarios provided by the embodiments of the present disclosure can be performed by a processor, such as the processor executing any method for adjusting audio signals in multiple scenarios mentioned in the embodiments of the present disclosure by calling corresponding instructions stored in a memory. This will not be described in detail below.
[0215] Exemplary Devices
[0216] Fig.14 FIG. 1 is a schematic diagram of a structure of an apparatus for adjusting audio signals in multiple scenarios provided by an exemplary embodiment of the present disclosure. The apparatus of this embodiment can be used to implement the corresponding method embodiments of the present disclosure, such as Fig.14 The device shown may include: a first processing module 51 , a second processing module 52 , a third processing module 53 , a fourth processing module 54 and a fifth processing module 55 .
[0217] The first processing module 51 is used to determine first position information of a sound source corresponding to a first audio signal with a first number of channels in a first scene in a second scene.
[0218] The second processing module 52 is used to determine second position information of the sound players with a second number of channels in the second scene respectively.
[0219] The third processing module 53 is configured to determine the second audio signals of the second channel number based on the first audio signals of the first channel number.
[0220] The fourth processing module 54 is configured to determine adjustment parameters corresponding to the second audio signals of the second channel number respectively based on the second position information and the first position information.
[0221] The fifth processing module 55 is used to adjust the second audio signals of the second channel number based on the adjustment parameters respectively corresponding to the second audio signals of the second channel number, so as to obtain third audio signals respectively corresponding to the sound players of the second channel number.
[0222] In some optional embodiments, the first processing module 51 may be a module having corresponding processing functions in a signal processor or a signal processing chip.
[0223] In some optional embodiments, the second processing module 52 may be a module having corresponding processing functions in a signal processor or a signal processing chip.
[0224] In some optional embodiments, the third processing module 53 may be a module having corresponding processing functions in a signal processor or a signal processing chip.
[0225] In some optional embodiments, the fourth processing module 54 may be a module having corresponding processing functions in a signal processor or a signal processing chip.
[0226] In some optional embodiments, the fifth processing module 55 may be a module having corresponding processing functions in a signal processor or a signal processing chip.
[0227] Fig.15 It is a structural diagram of an apparatus for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure.
[0228] In some optional embodiments, in the above Fig.14 Based on the embodiment shown, Fig.15 As shown, the first processing module 51 may include: a first determining unit 511 , a second determining unit 512 , and a third determining unit 513 .
[0229] The first determining unit 511 may be configured to determine a preset listening position of the second scene.
[0230] The acquisition unit 512 may be configured to acquire relative position information of a sound source specified by a user relative to a preset listening position.
[0231] The second determining unit 513 may be configured to determine first position information of the sound source in the second scene based on a preset listening position and relative position information.
[0232] In some optional embodiments, in the above Fig.14 Based on the embodiment shown, Fig.15 As shown, the first processing module 51 may include: a first determining unit 511 , a second determining unit 512 , and a third determining unit 513 .
[0233] The first determining unit 511 may be configured to determine a left channel signal and a right channel signal based on a first audio signal with a first number of channels.
[0234] The second determining unit 512 may be configured to determine the distance and direction of the sound source relative to the preset listening position based on the left channel signal and the right channel signal.
[0235] The third determining unit 513 may be configured to determine first position information of the sound source in the second scene according to the distance and direction of the sound source relative to the preset listening position.
[0236] Fig.16 It is a structural diagram of an apparatus for adjusting audio signals in multiple scenarios provided by yet another exemplary embodiment of the present disclosure.
[0237] In some optional embodiments, based on any of the above embodiments, Fig.16 As shown, the fourth processing module 54 may include: a first processing unit 541 and a second processing unit 542 .
[0238] The first processing unit 541 may be configured to determine the distances between the sound sources and the sound players of the second number of sound channels according to the second position information and the first position information of the sound players of the second number of sound channels.
[0239] The second processing unit 542 may be configured to determine adjustment parameters corresponding to the second audio signals of the second audio channels according to the distances between the sound sources and the sound players of the second audio channels.
[0240] In some optional embodiments, the second processing unit 542 can be specifically used to determine the adjustment parameters corresponding to the second audio signals of the second channel number according to the distances between the sound source and each sound player, and the relative relationship between each sound player and the preset listening position of the second scene.
[0241] In some optional embodiments, the second processing unit 542 can be specifically used to: determine a reference player from each sound player according to the distance between the sound source and each sound player respectively; determine the adjustment parameters of the second audio signal corresponding to the reference player according to a preset method; for any sound player except the reference player among the sound players, in response to the relative relationship between the sound player and the preset listening position satisfying the first condition, determine the adjustment parameters of the second audio signal corresponding to the sound player based on the first distance between the sound player and the sound source and the second distance between the reference player and the sound source; in response to the relative relationship between the sound player and the preset listening position not satisfying the first condition, determine the third distance between the sound player and the preset listening position; determine the adjustment parameters of the second audio signal corresponding to the sound player based on the first distance between the sound player and the sound source and the third distance between the sound player and the preset listening position.
[0242] In some optional embodiments, the adjustment parameter may include at least one of phase and gain.
[0243] In some optional embodiments, the second processing unit 542 can be specifically used to: determine a first distance difference based on a first distance between the sound player and the sound source and a second distance between the reference player and the sound source; determine a phase parameter corresponding to the sound player based on the first distance difference and a first mapping relationship between a preconfigured distance difference and a phase; and / or determine a gain parameter corresponding to the sound player based on the first distance between the sound player and the sound source and a second mapping relationship between a preconfigured distance and a gain.
[0244] The second processing unit 542 can be specifically used to: determine the distance and value of the first distance and the third distance corresponding to the sound player; determine the phase parameter of the second audio signal corresponding to the sound player based on the mapping relationship between the distance and value, the preconfigured distance and value and the phase; and / or determine the gain parameter of the second audio signal corresponding to the sound player based on the mapping relationship between the distance and value, the preconfigured distance and value and the gain.
[0245] Fig.17 It is a structural diagram of an apparatus for adjusting audio signals in multiple scenarios provided by another exemplary embodiment of the present disclosure.
[0246] In some optional embodiments, based on any of the above embodiments, Fig.17 As shown, the fourth processing module 54 may include: a fourth determining unit 54a, a fifth determining unit 54b, a sixth determining unit 54c and a seventh determining unit 54d.
[0247] The fourth determining unit 54a may be configured to determine a reference player from among the sound players according to the second position information and the first position information.
[0248] The fifth determining unit 54b may be configured to determine an adjustment parameter of the second audio signal corresponding to the reference player.
[0249] The sixth determination unit 54c can be used to determine at least one of the phase parameter and gain parameter of the second audio signal corresponding to any sound player among the players except the reference player, based on the first distance between the sound player and the sound source and the relative relationship between the sound player and the preset listening position of the second scene.
[0250] The seventh determination unit 54d may be configured to determine an adjustment parameter of the second audio signal corresponding to the sound player according to at least one of the phase parameter and the gain parameter.
[0251] In some optional embodiments, the sixth determination unit 54c can be specifically used to: in response to the relative relationship between the sound player and the preset listening position satisfying the first condition, determine the phase parameter of the second audio signal corresponding to the sound player based on the first distance between the sound player and the sound source, the second distance between the reference player and the sound source, and a preconfigured first mapping relationship corresponding to the phase; and / or, determine the gain parameter of the second audio signal corresponding to the sound player based on the first distance between the sound player and the sound source, and a preconfigured second mapping relationship corresponding to the gain.
[0252] In some optional embodiments, the sixth determination unit 54c can be specifically used to: determine the third distance between the sound player and the preset listening position in response to the relative relationship between the sound player and the preset listening position not satisfying the first condition; determine the distance and value of the first distance and the third distance corresponding to the sound player; determine the phase parameter of the second audio signal corresponding to the sound player based on the third mapping relationship between the distance and value, the preconfigured distance and value and the phase; and / or determine the gain parameter of the second audio signal corresponding to the sound player based on the fourth mapping relationship between the distance and value, the preconfigured distance and value and the gain.
[0253] Fig.18 It is a structural diagram of an apparatus for adjusting audio signals in multiple scenarios provided by yet another exemplary embodiment of the present disclosure.
[0254] In some optional embodiments, based on any of the above embodiments, Fig.18 As shown, the third processing module 53 may include: an eighth determination unit 531 and a third processing unit 532 .
[0255] The eighth determining unit 531 may be configured to determine frequency types of the second number of channels.
[0256] The third processing unit 532 may be configured to generate, in response to the frequency type including at least one first preset type, second audio signals corresponding to the channels of the first preset type in the channels of the second number of channels based on the first audio signals of the first number of channels.
[0257] The fourth processing module 54 may be specifically configured to determine adjustment parameters corresponding to the second audio signals of the channels of each first preset type, based on the second position information and the first position information.
[0258] The fifth processing module 55 can be specifically used to adjust the second audio signals of each first preset type of channel based on the adjustment parameters corresponding to the second audio signals of each first preset type of channel, and obtain the third audio signals corresponding to the sound players of each first preset type of channel.
[0259] In some optional embodiments, the first audio signal with the first number of channels includes a left channel signal and a right channel signal.
[0260] The third processing unit 532 may be specifically configured to: down-mix the left channel signal and the right channel signal into a mono signal; and generate, based on the mono signal, second audio signals corresponding to the channels of each first preset type.
[0261] Fig.19 It is a structural diagram of an apparatus for adjusting audio signals in multiple scenarios provided by yet another exemplary embodiment of the present disclosure.
[0262] In some optional embodiments, based on any of the above embodiments, Fig.19 As shown, the fifth processing module 55 may include: a ninth determining unit 551 , a tenth determining unit 552 and a fourth processing unit 553 .
[0263] The ninth determining unit 551 is configured to determine a physical quantity of an adjustment parameter corresponding to the second audio signal.
[0264] The tenth determining unit 552 is configured to determine a target physical quantity corresponding to the second audio signal based on the physical quantity.
[0265] The fourth processing unit 553 may be configured to adjust the second audio signal based on the target physical quantity to obtain a third audio signal.
[0266] In some optional embodiments, based on any of the above embodiments, Fig.19 As shown, the fifth processing module 55 may include: a ninth determining unit 551 , a tenth determining unit 552 and a fourth processing unit 553 .
[0267] The ninth determining unit 551 is configured to determine a phase parameter and a gain parameter based on the adjustment parameter corresponding to the second audio signal.
[0268] The tenth determining unit 552 is configured to filter the second audio signal using an all-pass filter based on the phase parameter to obtain a filtered audio signal.
[0269] The fourth processing unit 553 is configured to perform gain adjustment on the filtered audio signal based on the gain parameter to obtain a third audio signal.
[0270] In some optional embodiments, the tenth determining unit 552 is used to adjust the gain of the second audio signal based on the gain parameter to obtain an adjusted audio signal. The fourth processing unit 553 is used to filter the adjusted audio signal using an all-pass filter based on the phase parameter to obtain a third audio signal.
[0271] In some optional embodiments, such as Fig.18 As shown, the third processing module 53 may further include: a fifth processing unit 533 .
[0272] The fifth processing unit 533 may be configured to determine a signal of a frequency of a second preset type based on the first audio signal of the first channel number in response to the frequency type further comprising the second preset type.
[0273] The fifth processing module 55 can also be used to: determine the third audio signal corresponding to the sound player of the second preset type of channel among the channels of the second number of channels based on the signal of the second preset type of frequency; determine the third audio signals corresponding to the sound players of the second number of channels based on the third audio signal corresponding to the sound player of the second preset type of channel and the third audio signals corresponding to the sound players of each first preset type of channel.
[0274] The modules and / or units in any of the above embodiments may be modules and / or units with corresponding functions in a signal processing chip.
[0275] The above embodiments of the present disclosure may be implemented separately or in any combination without conflict. The embodiments may be configured according to actual needs and are not limited in the present disclosure.
[0276] The beneficial technical effects corresponding to the exemplary embodiment of the present device can be found in the corresponding beneficial technical effects of the above exemplary method section, which will not be repeated here.
[0277] Exemplary Electronic Devices
[0278] Fig. 20 It is a structural diagram of an electronic device provided by an embodiment of the present disclosure, including at least one processor 91 and a memory 92.
[0279] The processor 91 may be a central processing unit (CPU) or other forms of processing units having data processing capabilities and / or instruction execution capabilities, and may control other components in the electronic device 90 to perform desired functions.
[0280] The memory 92 may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. Volatile memory may include, for example, random access memory (RAM) and / or cache memory (cache), etc. Non-volatile memory may include, for example, read-only memory (ROM), hard disk, flash memory, etc. One or more computer program instructions may be stored on the computer-readable storage medium, and the processor 91 may execute one or more computer program instructions to implement the methods and / or other desired functions of the various embodiments of the present disclosure described above.
[0281] In one example, the electronic device 90 may further include: an input device 93 and an output device 94 , and these components are interconnected via a bus system and / or other forms of connection mechanisms (not shown).
[0282] The input device 93 may also include, for example, a keyboard, a mouse, a touch screen, a microphone, various sensors, and the like. Sensors may include, for example, image sensors (such as cameras, cameras, etc.), laser radars, millimeter-wave radars, ultrasonic radars, positioning sensors, pressure sensors, air quality sensors, temperature sensors, and the like. Image sensors, laser radars, millimeter-wave radars, ultrasonic radars, and the like may be used to sense the surrounding environment, i.e., to detect dynamic and static objects in the surrounding environment. Dynamic and static objects may include, for example, static objects such as lane lines, curbs, arrows, signs, trees, and buildings, as well as dynamic objects such as surrounding vehicles, pedestrians, and cyclists. Positioning sensors are used to realize the positioning of movable devices (such as self-vehicles, robots, etc.) where electronic devices are located. Positioning sensors may include, for example, inertial measurement units (Inertial Measurement Unit, referred to as: IMU), global positioning systems (Global Positioning System, referred to as: GPS), and the like. Pressure sensors may be used to detect seat pressure. Temperature sensors may be used to detect the temperature in the vehicle cabin. Air quality sensors may be used to detect the air quality in the vehicle cabin.
[0283] The output device 94 can output various information to the outside, and may include, for example, a display, a speaker, a printer, a communication network and its connected remote output devices, etc.
[0284] Of course, to simplify, Fig. 20 Only some of the components related to the present disclosure in the electronic device 90 are shown, and components such as a bus, an input / output interface, etc. are omitted. In addition, according to specific application situations, the electronic device 90 may also include any other appropriate components.
[0285] Exemplary computer program products and computer-readable storage media
[0286] In addition to the above methods and devices, embodiments of the present disclosure may also provide a computer program product, including computer program instructions, which, when executed by a processor, enable the processor to execute the steps of the methods of various embodiments of the present disclosure described in the above “Exemplary Methods” section.
[0287] The computer program product may be written in any combination of one or more programming languages to write program code for performing the operations of the disclosed embodiments, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server.
[0288] In addition, an embodiment of the present disclosure may also be a computer-readable storage medium having computer program instructions stored thereon. When the computer program instructions are executed by a processor, the processor executes the steps in the method of various embodiments of the present disclosure described in the above “Exemplary Method” section.
[0289] Computer readable storage media can adopt any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium is, for example, but not limited to, a system, device or device including electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0290] The basic principles of the present disclosure are described above in conjunction with specific embodiments. However, the advantages, strengths, effects, etc. mentioned in the present disclosure are only examples and not limitations, and cannot be considered as necessary for each embodiment of the present disclosure. In addition, the specific details disclosed above are only for the purpose of illustration and ease of understanding, rather than limitation, and the above details do not limit the present disclosure to being implemented by adopting the above specific details.
[0291] Those skilled in the art may make various changes and modifications to the present disclosure without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the present disclosure claims and their equivalents, the present disclosure is also intended to include these modifications and variations.
Claims
1. A method for adjusting an audio signal in multiple scenarios, comprising: Determine first position information of a sound source corresponding to a first audio signal with a first number of channels in a first scene in a second scene; Determine second position information of the sound players of the second channel number in the second scene respectively in the second scene; Determine, based on the first audio signal of the first channel number, the second audio signal of the second channel number; Determine, based on the second position information and the first position information, adjustment parameters corresponding to the second audio signals of the second channel number respectively; Based on the adjustment parameters respectively corresponding to the second audio signals of the second channel number, the second audio signals of the second channel number are adjusted to obtain the third audio signals respectively corresponding to the sound players of the second channel number.
2. The method according to claim 1, wherein: The determining, based on the second position information and the first position information, adjustment parameters respectively corresponding to the second audio signals of the second channel number includes: Determine the distance between the sound source and each of the sound players according to the second position information and the first position information; According to the distances between the sound source and each of the sound players, adjustment parameters corresponding to the second audio signals of the second channel number are determined.
3. The method according to claim 2, wherein: The step of determining adjustment parameters corresponding to the second audio signals of the second audio channels according to the distances between the sound sources and the sound players includes: According to the distances between the sound source and each of the sound players, and the relative relationships between each of the sound players and the preset listening positions of the second scene, the adjustment parameters corresponding to the second audio signals of the second channel number are determined.
4. The method according to claim 3, wherein: The step of determining the adjustment parameters corresponding to the second audio signals of the second channel number according to the distances between the sound source and each of the sound players and the relative relationships between each of the sound players and the preset listening positions of the second scene includes: Determining a reference player from among the sound players according to the distances between the sound source and each of the sound players; Determining, according to a preset method, an adjustment parameter of the second audio signal corresponding to the reference player; For any of the sound players except the reference player, in response to the relative relationship between the sound player and the preset listening position satisfying the first condition, based on the first distance between the sound player and the sound source and the second distance between the reference player and the sound source, determining an adjustment parameter of the second audio signal corresponding to the sound player; or In response to the relative relationship between the sound player and the preset listening position not satisfying the first condition, a third distance between the sound player and the preset listening position is determined; based on the first distance between the sound player and the sound source, and the third distance between the sound player and the preset listening position, an adjustment parameter of the second audio signal corresponding to the sound player is determined.
5. The method according to claim 1, wherein: Determining adjustment parameters corresponding to the second audio signals of the second channel number based on the second position information and the first position information includes: Determine a reference player from among the sound players according to the second position information and the first position information; Determining an adjustment parameter of a second audio signal corresponding to the reference player; For any sound player among the players except the reference player, based on a first distance between the sound player and the sound source and a relative relationship between the sound player and a preset listening position of the second scene, determining at least one of a phase parameter and a gain parameter of a second audio signal corresponding to the sound player; An adjustment parameter of a second audio signal corresponding to the sound player is determined according to at least one of the phase parameter and the gain parameter.
6. The method according to claim 5, wherein: The determining, based on a first distance between the sound player and the sound source and a relative relationship between the sound player and a preset listening position of the second scene, at least one of a phase parameter and a gain parameter of a second audio signal corresponding to the sound player comprises: In response to the relative relationship between the sound player and the preset listening position satisfying a first condition, determining a phase parameter of a second audio signal corresponding to the sound player based on a first distance between the sound player and the sound source, a second distance between the reference player and the sound source, and a preconfigured first mapping relationship corresponding to the phase; and / or, Based on the first distance between the sound player and the sound source and a preconfigured second mapping relationship corresponding to the gain, a gain parameter of a second audio signal corresponding to the sound player is determined.
7. The method according to claim 5, wherein: The determining, based on a first distance between the sound player and the sound source and a relative relationship between the sound player and a preset listening position of the second scene, at least one of a phase parameter and a gain parameter of a second audio signal corresponding to the sound player comprises: In response to the relative relationship between the sound player and the preset listening position not satisfying the first condition, determining a third distance between the sound player and the preset listening position; Determine the distance and value of the first distance and the third distance corresponding to the sound player; Determine a phase parameter of a second audio signal corresponding to the sound player based on the distance and value, a preconfigured third mapping relationship between the distance and value and the phase; and / or, Based on the distance and value, a fourth mapping relationship between the preconfigured distance and value and the gain, a gain parameter of the second audio signal corresponding to the sound player is determined.
8. The method according to any one of claims 1 to 7, wherein: The step of determining the first position information of the sound source corresponding to the first audio signal with the first number of channels in the first scene in the second scene includes: determining a preset listening position for a second scene; Acquiring relative position information of the sound source specified by a user relative to the preset listening position; Based on the preset listening position and the relative position information, the first position information of the sound source in the second scene is determined.
9. The method according to any one of claims 1 to 7, wherein: The step of determining the first position information of the sound source corresponding to the first audio signal with the first number of channels in the first scene in the second scene includes: Determine a left channel signal and a right channel signal based on the first audio signal of the first channel number; Determining the distance and direction of the sound source relative to a preset listening position based on the left channel signal and the right channel signal; The first position information of the sound source in the second scene is determined according to the distance and direction of the sound source relative to the preset listening position.
10. The method according to any one of claims 1 to 7, wherein: The determining, based on the first audio signal with the first number of channels, the second audio signal with the second number of channels comprises: determining frequency types of the channels of the second number of channels; In response to the frequency type including at least one first preset type, second audio signals corresponding to the channels of the first preset type in the channels of the second channel number are generated based on the first audio signals of the first channel number.
11. The method according to claim 10, wherein: The first audio signal of the first channel number includes a left channel signal and a right channel signal; The generating, based on the first audio signal of the first number of channels, second audio signals corresponding to the channels of the first preset type in the channels of the second number of channels respectively includes: Down-mixing the left channel signal and the right channel signal into a mono signal; Based on the monophonic signal, second audio signals corresponding to the channels of the first preset type are generated.
12. The method according to claim 10, wherein: The adjusting the second audio signals of the second channel number based on the adjustment parameters respectively corresponding to the second audio signals of the second channel number to obtain the third audio signals respectively corresponding to the sound players of the second channel number include: determining a physical quantity of an adjustment parameter corresponding to the second audio signal; Based on the physical quantity, determining a target physical quantity corresponding to the second audio signal; Based on the target physical quantity, the second audio signal is adjusted to obtain a third audio signal.
13. The method according to claim 10, wherein: The adjusting the second audio signals of the second channel number based on the adjustment parameters respectively corresponding to the second audio signals of the second channel number to obtain the third audio signals respectively corresponding to the sound players of the second channel number include: Determining a phase parameter and a gain parameter based on an adjustment parameter corresponding to the second audio signal; Based on the phase parameter, filtering the second audio signal using an all-pass filter to obtain a filtered audio signal; Based on the gain parameter, the filtered audio signal is gain-adjusted to obtain a third audio signal; or, Based on the gain parameter, performing gain adjustment on the second audio signal to obtain an adjusted audio signal; Based on the phase parameter, an all-pass filter is used to filter the adjusted audio signal to obtain a third audio signal.
14. The method according to claim 10, wherein: The method further comprises: In response to the frequency type further comprising a second preset type, determining a signal of a frequency of the second preset type based on the first audio signal of the first channel number; According to the signal of the frequency of the second preset type, a third audio signal corresponding to the sound player of the channel of the second preset type among the channels of the second number of channels is determined.
15. A device for adjusting an audio signal in multiple scenarios, comprising: A first processing module, used to determine first position information of a sound source corresponding to a first audio signal with a first number of channels in a first scene in a second scene; A second processing module, used to determine second position information of the sound players of the second channel number in the second scene respectively in the second scene; a third processing module, configured to determine, based on the first audio signals of the first channel number, the second audio signals of the second channel number; A fourth processing module, configured to determine adjustment parameters corresponding to the second audio signals of the second channel number respectively based on the second position information and the first position information; The fifth processing module is used to adjust the second audio signals of the second channel number based on the adjustment parameters respectively corresponding to the second audio signals of the second channel number, so as to obtain the third audio signals respectively corresponding to the sound players of the second channel number.
16. A computer-readable storage medium storing a computer program, wherein the computer program is used to execute the method according to any one of claims 1 to 14.
17. An electronic device, comprising: processor; a memory for storing instructions executable by the processor; The processor is used to read the executable instructions from the memory and execute the instructions to implement the method described in any one of claims 1-14.