Dynamic spatial audio processing method based on head posture calculation based on device-side optimization
Through the head attitude solution dynamic spatial audio processing method based on end-side optimization, the problems of complex data acquisition, large computing resource consumption and high delay in traditional audio spatial technology are solved, and the effect of saving computing power resources, reducing delays and improving scene adaptability is achieved.
Patent Information
- Application Number
- CN202510072258.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-17
- Publication Date
- 2025-04-29
- Estimated Expiration
- 2045-01-17
AI Technical Summary
Traditional audio spatialization technology relies on the acquisition and convolution process of head-related impulse response (HRIR), and has problems such as complex data acquisition, large computing resource consumption, high delay, and poor application on resource-limited devices.
The dynamic spatial audio processing method of head attitude solution based on end-side optimization is adopted. By reading the sensor data of the accelerometer and gyroscope, attitude angle calculation and audio spatial filter group parameters are performed to realize audio spatial sound processing.
This method saves computing resources, reduces delays and improves scenario adaptability. It can run smoothly on low-performance hardware, is suitable for a variety of environments, and provides a more realistic auditory experience.
Smart Images

Figure CN119497035B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of spatial audio processing technology, and in particular to a head posture solving dynamic spatial audio processing method based on end-side optimization. Background Art
[0002] In the field of modern audio technology, the generation and processing of spatial audio has become one of the key technologies to enhance user experience. Spatial audio technology can simulate the sound environment in real life, allowing users to experience a more realistic sound field effect in a virtual environment.
[0003] Traditional audio spatialization technology mainly relies on the acquisition and convolution process of head-related impulse response (HRIR). HRIR simulates the spatial positioning of sound by measuring the acoustic characteristics of sound waves reaching the human ear from all directions. First, the acquisition process of HRIR is complex and demanding. In order to obtain accurate measurement results, it is usually necessary to conduct it in a professional acoustic laboratory and use a human head microphone such as KEMAR. The strict requirements of this method for the environment limit its flexibility and adaptability, making it difficult to effectively apply HRIR in different application scenarios, especially when fast and low-cost deployment is required. Traditional acquisition methods are not practical enough. Secondly, convolution operations, especially long convolutions, consume a lot of computing resources and usually require a large computing buffer. The computationally intensive characteristics greatly increase the complexity of the operation. In real-time applications, computational delays may cause asynchronous or slow sound processing, which has a negative impact on the user experience. In addition, due to the high requirements of convolution operations on system computing power, traditional algorithms often perform poorly on resource-limited devices (such as mobile devices or embedded systems). This limits the effective application of HRIR technology on these devices and hinders its popularization in a wider range of practical application scenarios.
[0004] Therefore, it is necessary to improve spatial audio technology to save computing resources, reduce latency and improve scene adaptability. Summary of the invention
[0005] The purpose of the present invention is to provide a head posture solving dynamic spatial audio processing method based on terminal side optimization, which saves computing power resources, reduces latency and improves scene adaptability.
[0006] The present invention is achieved through the following technical solutions:
[0007] The head posture solving dynamic spatial audio processing method based on device-side optimization includes the following steps:
[0008] Perform head posture calculation, including:
[0009] Read the sensor data of the accelerometer and gyroscope and calibrate the sensor data;
[0010] Calculate the attitude angle based on the sensor data;
[0011] Updating parameters of the audio spatialization filter bank based on the attitude angle;
[0012] Perform audio spatialization sound processing, including:
[0013] The input stereo signal is split to obtain a left channel signal L and a right channel signal R, and then copied to obtain a direct sound L1 from the left channel to the left ear, a direct sound R1 from the right channel to the right ear, a crossover sound L2 from the left channel to the right ear, and a crossover sound R2 from the right channel to the left ear;
[0014] Performing environmental sound simulation according to the L1, the L2 and the R1, the R2;
[0015] Perform frequency response gain and delay simulation on the L1, the R1, the L2 and the R2 through the spatialization filter group;
[0016] Perform signal fusion and gain compensation;
[0017] Merge and output signals.
[0018] Preferably, the method for calculating the attitude angle based on the sensor data comprises:
[0019] Use complementary filtering algorithm to calculate the current attitude angle of the device in real time;
[0020] If the three-axis change of the gyroscope is less than a preset threshold, determining whether the device is in a stationary state;
[0021] When the device is in a stationary state, the sensor data of the plurality of gyroscopes and the accelerometers are continuously accumulated to obtain deviations of the gyroscopes and the accelerometers respectively. If the duration of the stationary state exceeds 6 seconds, the attitude angle decays smoothly to 0 within 1 second.
[0022] When the device is in a non-stationary state, the currently calculated attitude angle is directly output.
[0023] Preferably, the method of respectively obtaining the deviations of the gyroscope and the accelerometer comprises:
[0024] The method for obtaining the deviation of the gyroscope is: obtaining the inverse of the average value of the accumulated sensor data collected by the gyroscope;
[0025] The method for obtaining the deviation of the accelerometer is: calculating the accumulated modulus of the sensor data collected by the accelerometer; comparing the modulus with the standard gravity acceleration to obtain a correction factor, normalizing the sensor data of the accelerometer by the correction factor and calculating the acceleration bias.
[0026] Preferably, the method for updating the parameters of the audio spatialization filter bank based on the attitude angle comprises:
[0027] Set the sound speed to , the user's head radius is , the distances from the first sound source and the second sound source to the user are , the azimuth of the first sound source is , the azimuth of the second sound source is , the user's head angle is ;
[0028] The azimuth of the first sound source , the azimuth of the second sound source , the user's head angle Convert to radians respectively , and ;
[0029] Get the right ear angle of the first sound source respectively and left ear angle :
[0030] ;
[0031] ;
[0032] Get the right ear angle of the second sound source respectively and left ear angle :
[0033] ;
[0034] ;
[0035] Use the cosine theorem to calculate the distance from the first sound source to the right ear and the distance to the left ear , and the distance from the second sound source to the right ear and the distance to the left ear :
[0036] ;
[0037] ;
[0038] ;
[0039] ;
[0040] Calculate the time from the first sound source to the right ear and the time to the left ear , and the time from the second sound source to the right ear and the time to the left ear :
[0041] ;
[0042] ;
[0043] ;
[0044] ;
[0045] Obtaining a time difference between when the first sound source reaches the left ear and the right ear, and a time difference between when the second sound source reaches the left ear and the right ear;
[0046] Based on the vector base amplitude translation algorithm, respectively calculate the gains of the left ear and the right ear receiving the first sound source and the second sound source at the current posture angle;
[0047] An audio spatialization filter bank is set and updated based on the time difference and the gain.
[0048] Preferably, the method for performing environmental sound simulation according to the L1, the L2 and the R1, the R2 is:
[0049] The L2 and the R2 are processed by a mutual feed filter.
[0050] Preferably, the method of simulating the frequency response gain and delay of the L1, the R1, the L2 and the R2 by the spatialization filter group is:
[0051] The delay filter is designed with a circular buffer to achieve delay simulation;
[0052] Perform gain simulation.
[0053] Preferably, the method of using a ring buffer to design a delay filter to implement delay simulation is:
[0054] Calculate the maximum number of audio sample points in the ring buffer according to the audio sampling rate and the maximum transmission time from the sound source to the human ear;
[0055] Configure four independent ring buffers, each corresponding to an audio signal channel;
[0056] In the posture solution process, the four-way signal delay parameters of the audio signal channel are first obtained, and the effective length of the corresponding ring buffer is dynamically adjusted according to the delay parameters.
[0057] Preferably, the method for performing gain simulation is:
[0058] Converting the four-way signal gains of the audio signal channel obtained by posture solution from a logarithmic scale to a linear scale;
[0059] According to the real-time change of the head posture, the linear gains of the four-channel audio signals of the audio signal channel are dynamically calculated and adjusted, and the parameters of the parameter equalizer are updated according to the frequency response characteristics measured in the laboratory.
[0060] Preferably, the method for performing signal fusion and gain compensation is:
[0061] Combining the L1 with the R2 to obtain an output left channel signal, and combining the R1 with the L2 to obtain an output right channel signal;
[0062] Gain compensation is performed on the output left channel signal and the output right channel signal to ensure that signal energy is consistent with the input stereo signal.
[0063] Preferably, the method for signal merging and outputting is:
[0064] The output left channel signal and the output right channel signal are combined into a stereo signal.
[0065] The technical solution of the present invention has at least the following advantages and beneficial effects:
[0066] The present invention supports input processing of audio sample points one by one, thereby running efficiently in a low-latency mode, solving the delay problem caused by the traditional audio spatialization algorithm based on convolution HRIR relying on the buffer to store a frame of audio data for processing;
[0067] The present invention has been optimized to reduce the demand for computing power, so that it can run smoothly on relatively low-performance hardware, solving the problem that traditional algorithms have high requirements for computing power, which may limit their application on devices with limited resources.
[0068] The present invention simplifies and optimizes the data collection process, making it easier to flexibly adjust and apply in a variety of environments, thereby having a strong scene adaptability, and solving the problem that the data collection process of traditional algorithms is complex and difficult, requiring high-precision customized settings and thus poor adjustment. BRIEF DESCRIPTION OF THE DRAWINGS
[0069] Figure 1A flowchart of an example of a head posture solving dynamic spatial audio processing method based on terminal-side optimization provided in Example 1 of the present invention. DETAILED DESCRIPTION
[0070] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Generally, the components of the embodiments of the present invention described and shown in the drawings here can be arranged and designed in various different configurations.
[0071] Example 1
[0072] This embodiment provides a head posture solution-based dynamic spatial audio processing method based on device-side optimization, including the following steps:
[0073] Perform head posture calculation, including:
[0074] Read the sensor data of the accelerometer and gyroscope and calibrate the sensor data;
[0075] Calculate the attitude angle based on the sensor data;
[0076] Updating parameters of the audio spatialization filter bank based on the attitude angle;
[0077] Perform audio spatialization sound processing, including:
[0078] The input stereo signal is split to obtain a left channel signal L and a right channel signal R, and then copied to obtain a direct sound L1 from the left channel to the left ear, a direct sound R1 from the right channel to the right ear, a crossover sound L2 from the left channel to the right ear, and a crossover sound R2 from the right channel to the left ear;
[0079] Performing environmental sound simulation according to the L1, the L2 and the R1, the R2;
[0080] Perform frequency response gain and delay simulation on the L1, the R1, the L2 and the R2 through the spatialization filter group;
[0081] Perform signal fusion and gain compensation;
[0082] Merge and output signals.
[0083] In this embodiment, the method for calculating the attitude angle based on the sensor data includes:
[0084] Use complementary filtering algorithm to calculate the current attitude angle of the device in real time;
[0085] If the three-axis change of the gyroscope is less than a preset threshold, determining whether the device is in a stationary state;
[0086] When the device is in a stationary state, the sensor data of the plurality of gyroscopes and the accelerometers are continuously accumulated to obtain deviations of the gyroscopes and the accelerometers respectively. If the duration of the stationary state exceeds 6 seconds, the attitude angle decays smoothly to 0 within 1 second.
[0087] When the device is in a non-stationary state, the currently calculated attitude angle is directly output.
[0088] Specifically, the method of respectively obtaining the deviations of the gyroscope and the accelerometer includes:
[0089] The method for obtaining the deviation of the gyroscope is: obtaining the inverse of the average value of the accumulated sensor data collected by the gyroscope;
[0090] The method for obtaining the deviation of the accelerometer is: calculating the modulus of the sensor data collected by the accelerometer; comparing the modulus with the standard gravity acceleration, that is, 9.8 m / s², to obtain a correction factor, normalizing the sensor data of the accelerometer by the correction factor and calculating the acceleration bias. This method aims to ensure that the acceleration in a stationary state matches the standard gravity.
[0091] On the other hand, in an actual room environment, the sound signals transmitted by the sound system to the left and right ears of the human body are divided into two direct sounds and two reflected sounds from two sound sources, acting on the left ear and right ear respectively. Based on this principle, the gain and delay of the four sound signals need to be accurately calculated, including: the signal transmitted from the first sound source to the left ear, the signal transmitted from the first sound source to the right ear, the signal transmitted from the second sound source to the left ear, and the signal transmitted from the second sound source to the right ear.
[0092] In order to achieve precise control of the above signals, this embodiment adopts the Vector Base Amplitude Panning (VBAP) algorithm. This method can dynamically calculate the gain distribution of the two sound sources in the left and right ears according to the current spatial posture, thereby achieving the spatial positioning of the sound source and the natural transition of the sound. The VBAP algorithm can ensure the relative intensity and phase relationship of the sound at different positions, so that the listener can experience a real spatial sound effect.
[0093] On this basis, the method for updating the parameters of the audio spatialization filter group based on the attitude angle includes:
[0094] Set the sound speed to , the user's head radius is , the distances from the first sound source and the second sound source to the user are , the azimuth of the first sound source is , the azimuth of the second sound source is , the user's head angle is ;
[0095] The azimuth of the first sound source , the azimuth of the second sound source , the user's head angle Convert to radians respectively , and ;
[0096] Get the right ear angle of the first sound source respectively and left ear angle :
[0097] ;
[0098] ;
[0099] Get the right ear angle of the second sound source respectively and left ear angle :
[0100] ;
[0101] ;
[0102] Use the cosine theorem to calculate the distance from the first sound source to the right ear and the distance to the left ear , and the distance from the second sound source to the right ear and the distance to the left ear :
[0103] ;
[0104] ;
[0105] ;
[0106] ;
[0107] Calculate the time from the first sound source to the right ear and the time to the left ear , and the time from the second sound source to the right ear and the time to the left ear :
[0108] ;
[0109] ;
[0110] ;
[0111] ;
[0112] Based on the above structure, the time difference between the first sound source reaching the left ear and the right ear, and the time difference between the second sound source reaching the left ear and the right ear can be obtained;
[0113] Based on the vector base amplitude translation algorithm, respectively calculate the gains of the left ear and the right ear receiving the first sound source and the second sound source at the current posture angle;
[0114] An audio spatialization filter bank is set and updated based on the time difference and the gain to prepare for subsequent audio effect processing.
[0115] In simple terms, this embodiment calculates the distances from the two sound sources to the left and right ears respectively for the current posture angle, and then uses the cosine theorem to consider the curvature of the head and the position of the sound source. Then, based on the calculated distances between the left and right ears, the time difference for the sound to reach the left and right ears can be calculated based on the speed of sound.
[0116] This embodiment has significant advantages over the method of spatial data acquisition based on head-related transfer function (HRTF). First, this embodiment has low requirements for acquisition equipment and a simple acquisition process, so it can be applied to most practical application scenarios. Secondly, in the audio spatialization algorithm, the Vector Base Amplitude Panning (VBAP) algorithm is a common method that only adjusts the gain of the left and right ears to achieve the spatial positioning of the audio. This method easily leads to deviations in sound positioning and is insufficient in terms of realism and immersion. In order to overcome the limitations of VBAP, this embodiment is improved on its basis, adding a mutual feedback mechanism and delay processing between the sound source and the human ear. Specifically, the mutual feedback mechanism can simulate the reflection and propagation path of sound in space, making the sound source positioning more accurate; the delay processing enhances the spatial depth and sense of distance of the sound by adjusting the transmission time of the signal. These improvement measures not only improve the spatial positioning accuracy of the sound, but also enhance the realism and immersion of the sound effect, so that the listener can better experience the spatial sound effect in a real room.
[0117] In the process of audio spatialization sound effect processing, in the actual room environment, the sound signals transmitted by the sound system to the left and right ears of people, the sounds from the two sound sources are divided into two direct sounds and two reflected sounds, which act on the left and right ears respectively. Specifically, direct sound refers to the sound transmitted directly from the sound source to the listener's ears, while reflected sound refers to the sound transmitted to the ears after being reflected on surfaces such as walls, ceilings and floors in the room. Based on this principle, the stereo audio signal needs to be converted into a four-channel audio signal during the processing process to process the direct sound and reflected sound from the two sound sources separately. Doing so can more accurately control the gain and delay of each sound channel, thereby simulating a real spatial sound field and enhancing the realism and immersion of the auditory experience. The converted four-channel audio will correspond to the direct sound of the first sound source, the reflected sound of the first sound source, the direct sound of the second sound source, and the reflected sound of the second sound source, respectively, providing basic data for subsequent spatialization processing.
[0118] As a preferred solution of this embodiment, the method for performing environmental sound simulation according to L1, L2 and R1, R2 is:
[0119] The L2 and the R2 are processed by a mutual feed filter.
[0120] In the actual test environment, there is a certain difference between the frequency response from the left speaker to the right ear and the frequency response to the left ear. Therefore, the role of the mutual feedback filter is to design a filter based on the frequency response curve measured under experimental conditions. Here, a parametric equalizer (EQ) can be used to process the direct sound and use digital signal processing to achieve the effect of using direct sound to simulate the mutual feedback sound. The processing method from the right speaker to the left ear is the same as above.
[0121] Next, in the actual test environment, when the human head rotates, the frequency response and time of the sound from the left and right speakers to the left and right ears will change. According to the delay calculation and gain calculation methods mentioned in the posture solution algorithm, the delay and frequency response of the direct sound and mutual feedback sound received by the left and right ears when the human head rotates at different angles can be calculated. Adjusting the parameters of the delay filter and the gain filter according to the calculation results can simulate the sound heard by the human head at different angles in the actual environment. The method of simulating the frequency response gain and delay of the L1, R1, L2 and R2 by the spatialization filter group in this embodiment is:
[0122] The delay filter is designed with a circular buffer to achieve delay simulation;
[0123] Perform gain simulation.
[0124] Specifically, the method of using a ring buffer to design a delay filter to implement delay simulation is:
[0125] Calculate the maximum number of audio sample points in the ring buffer according to the audio sampling rate and the maximum transmission time from the sound source to the human ear; such setting can ensure that the buffer can accommodate the longest delay requirement;
[0126] Configure four independent ring buffers, each corresponding to an audio signal channel;
[0127] In the posture solution process, the four-way signal delay parameters of the audio signal channel are first obtained, and the effective length of the corresponding ring buffer is dynamically adjusted according to the delay parameters, so that the change of head posture can be responded to in real time to ensure the accuracy of audio delay.
[0128] The data processing flow based on the above scheme is as follows: when the audio data enters the delay filter, it is first stored in the corresponding ring buffer; then, the audio data is read from the output end of the buffer to achieve the desired delay effect. Since the effective length of the ring buffer will be adjusted in real time with the change of head posture, if the existing data in the buffer is not processed, it may cause the loss or insufficiency of audio data, thereby generating mutation noise. Therefore, while adjusting the effective length of the buffer, the existing audio data in the buffer needs to be interpolated to ensure the continuity and stability of the audio signal.
[0129] Furthermore, the method for performing gain simulation is:
[0130] Convert the four-way signal gains of the audio signal channel obtained by posture solution from a logarithmic scale to a linear scale to facilitate subsequent digital signal processing;
[0131] According to the real-time changes in head posture, the linear gains of the four audio signals of the audio signal channel are dynamically calculated and adjusted, and the parameters of the parametric equalizer are updated according to the frequency response characteristics measured in the laboratory. This ensures that the audio output can accurately reflect the changes in head posture, thereby improving the user's auditory experience.
[0132] Next, the method for performing signal fusion and gain compensation is as follows:
[0133] Combining the L1 with the R2 to obtain an output left channel signal, and combining the R1 with the L2 to obtain an output right channel signal;
[0134] Gain compensation is performed on the output left channel signal and the output right channel signal to ensure that signal energy is consistent with the input stereo signal.
[0135] Finally, the method for signal merging and outputting is:
[0136] The output left channel signal and the output right channel signal are combined into a stereo signal.
[0137] Based on the technical solution of this embodiment, it is possible to achieve spatial processing of audio signals and adjust the sound effects according to changes in head posture to achieve a more realistic auditory experience.
[0138] To sum up, a flowchart of a specific implementation case can be found in Figure 1 , mainly includes two parts: head posture solution and audio spatialization sound effect processing.
[0139] In the head posture solution, the signals of the accelerometer and gyroscope are first read to obtain the sensor data, and then the sensor data is calibrated and updated and the angular velocity meter and gyroscope values are calibrated. Then the posture angle is calculated based on the sensor data to achieve posture solution. The next step is to determine whether the device is stationary. If it is not stationary, the posture angle is directly output. After that, the audio spatialization parameter update step can be used to calculate the audio spatialization filter group parameters and then implement the audio spatial filter parameter setting. When the device is stationary, the deviations of the gyroscope and the accelerometer are respectively obtained according to the method of this embodiment to return to updating and calibrating the angular velocity meter and gyroscope values. If the duration of the stationary state exceeds 6 seconds, the linear reset angle is output, that is, the posture angle of this embodiment smoothly decays to 0 within 1 second.
[0140] In the process of audio spatialization sound effect processing, the input stereo signal is first split into left and right channel signals to obtain a left channel signal L and a right channel signal R, and then the signals are copied to obtain a direct sound L1 from the left channel to the left ear, a direct sound R1 from the right channel to the right ear, a crossover sound L2 from the left channel to the right ear, and a crossover sound R2 from the right channel to the left ear; when simulating the ambient sound, L2 and R2 are processed by a mutual feed filter respectively; then, according to the method of this embodiment, a parameter gain filter and a parameter delay filter as an audio spatialization filter group are used to simulate the frequency response gain and delay of the four signals, that is, the spatialization filter group is used to simulate the L1, the R1, the L2, and the R2; then, signal fusion and gain compensation are performed; finally, the signals are merged and output.
[0141] The above are only preferred embodiments of the present invention and are not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A dynamic spatial audio processing method based on head posture calculation based on device-side optimization, characterized in that: The following steps are involved: Perform head posture calculation, including: Read the sensor data of the accelerometer and gyroscope and calibrate the sensor data; Calculate the attitude angle based on the sensor data; Updating parameters of the audio spatialization filter bank based on the attitude angle; Perform audio spatialization sound processing, including: The input stereo signal is split to obtain a left channel signal L and a right channel signal R, and then copied to obtain a direct sound L1 from the left channel to the left ear, a direct sound R1 from the right channel to the right ear, a crossover sound L2 from the left channel to the right ear, and a crossover sound R2 from the right channel to the left ear; Performing environmental sound simulation according to the L1, the L2 and the R1, the R2; Perform frequency response gain and delay simulation on the L1, the R1, the L2 and the R2 through the spatialization filter group; Perform signal fusion and gain compensation; Merge and output signals; The method of simulating the frequency response gain and delay of the L1, the R1, the L2 and the R2 by the spatialization filter group is: The delay filter is designed with a circular buffer to achieve delay simulation; Perform gain simulation; The method of using a ring buffer to design a delay filter to realize delay simulation is: Calculate the maximum number of audio sample points in the ring buffer according to the audio sampling rate and the maximum transmission time from the sound source to the human ear; Configure four independent ring buffers, each corresponding to an audio signal channel; In the posture solution process, the four-way signal delay parameters of the audio signal channel are first obtained, and the effective length of the corresponding ring buffer is dynamically adjusted according to the delay parameters.
2. The head posture solution-based dynamic spatial audio processing method based on device-side optimization according to claim 1 is characterized in that: The method for calculating the attitude angle based on the sensor data comprises: Use complementary filtering algorithm to calculate the current attitude angle of the device in real time; If the three-axis change of the gyroscope is less than a preset threshold, determining whether the device is in a stationary state; When the device is in a stationary state, the sensor data of the plurality of gyroscopes and the accelerometers are continuously accumulated to obtain deviations of the gyroscopes and the accelerometers respectively. If the duration of the stationary state exceeds 6 seconds, the attitude angle decays smoothly to 0 within 1 second. When the device is in a non-stationary state, the currently calculated attitude angle is directly output.
3. The head posture solution-based dynamic spatial audio processing method based on device-side optimization according to claim 2 is characterized in that: The method of respectively obtaining the deviations of the gyroscope and the accelerometer comprises: The method for obtaining the deviation of the gyroscope is: obtaining the inverse of the average value of the accumulated sensor data collected by the gyroscope; The method for obtaining the deviation of the accelerometer is: calculating the accumulated modulus of the sensor data collected by the accelerometer; comparing the modulus with the standard gravity acceleration to obtain a correction factor, normalizing the sensor data of the accelerometer by the correction factor and calculating the acceleration bias.
4. The head posture solution-based dynamic spatial audio processing method based on device-side optimization according to claim 2, characterized in that: The method for updating the parameters of the audio spatialization filter group based on the attitude angle includes: Set the sound speed to , the user's head radius is , the distances from the first sound source and the second sound source to the user are , the azimuth of the first sound source is , the azimuth of the second sound source is , the user's head angle is ; The azimuth of the first sound source , the azimuth of the second sound source , the user's head angle Convert to radians respectively , and ; Get the right ear angle of the first sound source respectively and left ear angle : ; ; Get the right ear angle of the second sound source respectively and left ear angle : ; ; Use the cosine theorem to calculate the distance from the first sound source to the right ear and the distance to the left ear , and the distance from the second sound source to the right ear and the distance to the left ear : ; ; ; ; Calculate the time from the first sound source to the right ear and the time to the left ear , and the time from the second sound source to the right ear and the time to the left ear : ; ; ; ; Obtaining a time difference between when the first sound source reaches the left ear and the right ear, and a time difference between when the second sound source reaches the left ear and the right ear; Based on the vector base amplitude translation algorithm, respectively calculate the gains of the left ear and the right ear receiving the first sound source and the second sound source at the current posture angle; The audio spatialization filterbank is set and updated based on the time differences and gains.
5. The head posture solution-based dynamic spatial audio processing method based on device-side optimization according to claim 1, characterized in that: The method for performing environmental sound simulation according to the L1, the L2 and the R1, the R2 is: The L2 and the R2 are processed by a mutual feed filter.
6. The head posture solution-based dynamic spatial audio processing method based on device-side optimization according to claim 1, characterized in that: The method for performing gain simulation is: Converting the four-way signal gains of the audio signal channel obtained by posture solution from a logarithmic scale to a linear scale; According to the real-time change of the head posture, the linear gains of the four-channel audio signals of the audio signal channel are dynamically calculated and adjusted, and the parameters of the parameter equalizer are updated according to the frequency response characteristics measured in the laboratory.
7. The head posture solution-based dynamic spatial audio processing method based on device-side optimization according to claim 1, characterized in that: The method for performing signal fusion and gain compensation is: Combining the L1 with the R2 to obtain an output left channel signal, and combining the R1 with the L2 to obtain an output right channel signal; Gain compensation is performed on the output left channel signal and the output right channel signal to ensure that signal energy is consistent with the input stereo signal.
8. The head posture solution-based dynamic spatial audio processing method based on device-side optimization according to claim 7, characterized in that: The method for signal merging and outputting is as follows: The output left channel signal and the output right channel signal are combined into a stereo signal.
Citation Information
Patent Citations
Method and system of improving on-site virtual-reality sound effect experience
CN108279860A
Accurate positioning method for edgewise cleaning by unmanned cleaning vehicle
CN110307836A
Battlefield sound effect simulation system and method applied to real soldier confrontation training
CN114777563A