banner
KiWi

KiWi的博客

这里是一个搞技术的音频er的网站
wechat
email

Vehicle Engine Sound Synthesis System

Vehicle Engine Sound Synthesis System#

Product Demonstration#

This is a simulation demonstration of a straight 4-cylinder engine, first showing the engine at idle, followed by acceleration and deceleration performance.

I4 Engine.wav
I4 Engine.wav

Introduction#

In the field of game sound effects, the sound of vehicle engines has always been an important part.

The current mainstream methods often combine live recordings with real-time control using audio middleware to achieve a realistic engine sound. More advanced techniques can use particle synthesizers for better effects or control, such as the REV plugin commonly used on the Wwise platform, but fundamentally, it still requires sampling the sounds of various engine components.

This method clearly has various limitations.

This system will perform physical modeling based on the working principles of the engine. By simulating the operation of the internal combustion engine, it can synthesize the final sound, achieving low latency and high-quality engine sound effects while providing real-time feedback.

Project Structure#

PS: Here we borrow the system structure diagram organized by @Lu Minhui 💕

image

The overall process of the system operation is:

First, determine the vehicle parameters, including: engine model, maximum RPM, number of cylinders, etc.

Next, through user real-time operations such as starting ignition, turning off, changing gears, and throttle position, influence important parameters like engine RPM and throttle opening to change the state of the engine simulator.

In a loop, the simulator will begin to perform physical simulation calculations of the engine under vehicle operating conditions based on the real-time state of the engine. By simulating the fluid dynamics of the intake and exhaust systems, as well as calculating exhaust flow, engine RPM, attenuation coefficients, etc., it determines the characteristics and intensity of the sound.

Finally, the results are written into the synthesizer (Synthesizer class). The synthesizer converts the simulated engine RPM and exhaust volume data into simulated engine sound signals through calculations, then feeds back to the Simulator class to generate real-time dynamic engine sound signals, which are played through audio output devices.

Core Algorithm#

First, how physical parameters affect sound intensity and timbre:

(Overall, it is through a series of physical parameters that ultimately affect the flow of the exhaust system, thereby changing the fundamental frequency of the sound; at the same time, the parameters of other engine modules change the timbre.)

  1. Engine RPM:
    The higher the RPM, the higher the exhaust frequency, leading to an increase in the frequency of exhaust pulses, which in turn raises the sound frequency.
  2. Intake Flow:
    An increase in intake volume usually leads to more complete and intense combustion, resulting in greater exhaust flow and louder sound.
  3. Fuel Injection Amount:
    More fuel injection leads to more intense combustion, generating higher pressure and exhaust flow, making the sound louder.
  4. Ignition Timing:
    Advancing or delaying the ignition timing changes the characteristics of the combustion process, affecting combustion efficiency and pressure fluctuations, thereby influencing exhaust flow and sound characteristics.
  5. Exhaust System Pressure:
    Pressure changes in the exhaust system directly affect the dynamic characteristics of exhaust flow and the way sound propagates.
  6. Cylinder Pressure:
    The frequency and amplitude of pressure fluctuations within the cylinder affect the pulsing characteristics of exhaust flow, thereby influencing sound frequency and intensity.
  7. Heat and Temperature:
    Temperature changes affect the expansion rate of gases and the stability of exhaust flow, thereby influencing sound characteristics.
  8. Engine Load:
    Changes in load affect the intensity and frequency of the combustion process, thereby changing exhaust flow and sound.
  9. Timing and Duration of Intake and Exhaust Valve Openings:
    The timing of the intake and exhaust valves affects the efficiency of gas exchange within the cylinder, altering the pulsing characteristics of exhaust flow and sound.
  10. Vibration and Resonance:
    The vibration characteristics of the engine and its components influence the modulation of exhaust flow and the spectral characteristics of sound through the vibration patterns of the exhaust system.

Next, how the sound synthesis system ultimately synthesizes sound signals through these parameters:

  1. First, the exhaust flow signal is input into the synthesizer, and its input values are interpolated and smoothed.
    image 1

  2. DC filtering of the signal.
    image 2

  3. Signal differentiation processing.
    image 3

  4. Air noise low-pass filtering.
    image 4

  5. Signal mixing.
    image 5

  6. Convolution filtering.
    image 6

  7. Level adjustment.
    image 7

  8. Signal quantization.
    image 8

  9. Finally, render the signal to the audio output device.

Conclusion and Outlook#

Currently, this article only provides a rough introduction to some core parts of the entire system; in reality, there are many specific details that have not been elaborated. Due to its complex calculations and physical modeling, this system is not yet suitable for direct application in game engines. As of the completion of this article, the author has been working on further lightweighting efforts and is committed to achieving its integration into the UE engine.

Loading...
Ownership of this post data is guaranteed by blockchain and smart contracts to the creator alone.