Doppler Shift

DirectSound automatically creates Doppler shift effects for any buffer or listener that has a velocity. Effects are cumulative: if the listener and the sound source are both moving, the system automatically calculates the relationship between their velocities and adjusts the Doppler effect accordingly.

The velocity of a sound source or listener does not necessarily reflect the speed at which it is moving through space. Setting an object's velocity does not move it, nor does moving the object affect the velocity. Velocity is simply a vector used to calculate the Doppler shift. In order to have realistic Doppler shift effects in your application, you must calculate the velocity of any object that is moving and set the appropriate value for that sound source or listener. You are free to exaggerate or minimize this value in order to create special effects.

You can also globally increase or decrease Doppler shift effects by setting the Doppler factor for the listener.