Game Development Stack Exchange is a question and answer site for professional and independent game developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've have read this interesting question, where is explained how to simulate positional sound with the left and right channel; but still I wonder: is it possible to simulate positional sound (with headphones) when the source is "in front" of you, "behind", "above", or "below"?

Again, all I can do is to adjust left/right volume.

EDIT: I can also alter the playback rate (pitch) of the sound, ranging from double to half the original pitch.

share|improve this question
Huh, there should be a way to somehow fake it (weakly) or make illusion, but in general - no. You might be able to achieve it for players with 5.1 - 7.1 Headphones. I bet it could be doable on those (ofc., if they have the drivers and you have the code to utilize those). – joltmode Apr 17 '12 at 8:20
@Tom 5.1 and 7.1 headphones are snakeoil. Because the sound is transferred directly into your auditory canal (skipping your body, head, ear lobes etc.) it is possible to simulate true 3D (beyond 7.1) sound: this is called HRTF. Jeff has a good write-up. – Jonathan Dickinson Apr 18 '12 at 10:27
Given my above comment, yes, it's possible to simulate these things with headphones. However, timing/volume/pitch is not enough. A commercial product that does this using your CPU is available: I tried it and my machine didn't have nearly enough punch to do the simulation. Modern sound cards can also do this in hardware, but Windows 7 removed support for it in DirectSound (so you need to check for Open AL support in games). – Jonathan Dickinson Apr 18 '12 at 10:29

There are some tricks to fake the "in front" and "behind" effects. But this is not simple to implement in order to have a real sexy effect. You will find some tricks in the Blumlein's approach on stereophonic system.

As far as I know you won't be able to have a good effect with only volume control.

share|improve this answer

True 3D positional sound is entirely possible, however, not using the simple effects at your disposal. You need to be well versed in digital signal processing and a sub-field of that called head relational transfer function.

HRTF basically seeks to emulate how sound is transferred through the air and your body, neck, ear lobes and head into your ears (your brain uses these subtle hints in order to position sound in 3-dimensional space). This works because, with headphones, the sound is delivered directly into your auditory canal: skipping any other mediums (such as your head). 5.1/7.1 headphones (which are complete snakeoil) might actually hinder HRTF because they introduce your outer ear into the equation.

Unfortunately HRTF is prohibitively expensive to simulate. For example, I evaluated MyEars and while my machine (Intel Core2 Extreme) could cope with with the samples running alone (and yes, it was extremely convincing) I couldn't use it in games. Mid-range sound cards (such as Creative X-Fi's) have HRTF processors and this will give you true 3D positional sound in games that support it (DirectSound in Windows 7 dropped support for hardware acceleration, so you will need to use OpenAL).

For a good example of what HRTF can actually achieve, this recording was done with a modelled head with embedded microphones (it isn't simulated HRTF, it's recorded): once again it will only work with headphones.

If you wish to use 3D positional sound simply use OpenAL - don't bother trying to roll it yourself.

Some more examples (made using simulated HRTF):

share|improve this answer
Pity it's so prohibitive to simulate. Here is another collection of actual HRTF recordings; just imagine if games could do this!... (headphones required) – romkyns Sep 27 '14 at 14:30
@romkyns, I wrote this answer 2 years ago. Modern CPUs have ample bandwidth to simulate this (I'm using an i5). The main problem is the current use of DirectX or failing to provide OpenAL with the correct positions of sounds. If a game doesn't support this, the fault now lies with the developer. – Jonathan Dickinson Sep 29 '14 at 12:12

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.