What is HRTF: Listening to Positional Audio in Games

Surely you use it or have used it, but do not know what it is called or what it does. It is the HRTF technology , in English called “Head-related transfer function” or “Head-related transfer function”, and is what allows us to have positional audio in games . Do you want to know what it is and how it works? Here we explain it to you.

Not all people perceive sound the same way, and not because of the level of hearing we can have, but also because of the shape and size of the head and ears, the ears. For this reason, HRTF technology exists, but before moving on to explain what it is and how it works, we must first explain some previous concepts.

HRTF

Hearing in humans

Humans can locate the origin of sounds in the three spatial dimensions that we all know. In the same way, we are able to weigh the distance at which sound is found thanks to a joint work of the brain, the inner ear and the outer ears.

The auditory cortex receives the signals from each of the ears separately in monaural signals , sending them to the association cortex where they are compared and result in information in the form of a binaural signal that combines the difference in arrival time and the difference in intensity. These monaural signals come from the interaction between the sound source and human anatomy , in which the sound of the source is modified before it reaches the ear canal to be processed.

These modifications encode the location of the origin and can be captured by an impulse response that relates the location of the origin of the sound and the location of the ear with respect to it. This impulse response is called the “Head Related Impulse” ( HRIR ), and the convolution (it is a mathematical operator that transforms two functions into a third one that represents the magnitude they superimpose) of an arbitrary source sound with the HRIR converts the sound that the listener would have listened to if it had been played back at the source location, with the listener’s ear and receiver location.

What is HRTF?

This is what we know as virtual surround sound . It is a function that characterizes how an ear receives sound from a point in space. As the sound impacts the listener, the density of the head and the size and shape of the ear buds transform the sound and affect the way it is perceived, increasing some frequencies and attenuating others.

Variación de sonido HRTF

Generally speaking, HRTF increases frequencies from 2 to 5 KHz with a primary resonance of +17 dB to 2,700 Hz, although the response curve varies significantly from person to person.

Currently, HRTF is used for both ears synthesizing a binaural sound that appears to come from a particular point in space (XYZ). It is, therefore, a transfer function that describes how a sound from a specific point will reach the ear .

How does this technology work?

The associated mechanism varies between people, since as we have explained, each one has a different head and ear shape. However, this technology tries to emulate the human average to provide the most accurate positional audio possible.

HRTF describes how a given sound wave input that has been parameterized as the frequency and location of the source is previously filtered (by game sound engineers, obviously) by the diffraction and reflection properties of the head, the pinna and torso before sound reaches the transduction machinery of the eardrum and inner ear.

It seems complicated, but in short, it simply means that it is a technology that allows audio engineers to parameterize the sound to indicate in which position we should listen to each sound. There is a transfer function in between, yes, but this is the subject of these audio engineers and what we need to understand is what defines the location of sound in virtual space .