HOA Tutorial Exercise 01:
Filter:
SC-HOA/Tutorials (extension) | Libraries > HOA

HOA Tutorial Exercise 01
ExtensionExtension

Creating spatialized sounds in HOA b-format.

Next: Exercise_02_HOA_converting_SN3D_N3D_FuMa

In ambisonics, a sound field is approximated with spherical harmonics of a given order, the multichannel signal associated with the spherical harmonics is called the B-format. For order 0, consisting of one channel, no directional information is available, one can think of it as a mono signal with the spatial characteristics of an omni spherical microphone, which is also know as the W channel (see top of the pyramid in the image below). For order 1, top of the pyramid and second row, the spherical harmonics have shapes reminiscent of microphone patterns (figure 8) and are known as Y Z and X channels. Combinations of the W channel and the Y (or X) channel are the basis of the MS microphone technique. Similar to the MS technique, a weighted combination of the channels from the B-format is used to generate speaker signals for the reconstruction of the approximated soundfield.

A given order n results in (n+1)^2 channels in the b-format.

order n# of channels
01
14
29
316
425
536

For a listing of spherical harmonics and their equations see http://ambisonics.ch/standards/channels/index.


Spherical Harmonics up to degree 5, as used in fifth-order, Image made by Dr. Franz Zotter, taken from Wikipedia

https://en.wikipedia.org/wiki/Ambisonic_data_exchange_formats#Prerequisites_for_successful_data_exchange

The code examples below show how to generate b-format signals and how to monitor them in the oscilloscope. Let's start the sound server, which we configure first to get more audio buses and 36 output channels.

Start the oscilloscope showing all the channels for the selected order of the b-format.

Let's try some spatialized white noise in the x y plane, observe constant signal in channel 1 and the varying signal in channel 2 (y) and 4 (x), 3 (z) is flat, so is 6, 8, 11, etc., all spherical harmonics with a vertical component

Change the source of the node ~hoaSignal and it will fade into a spatialized sound which allows you to move the white noise in x,y,z.

Change the source again, now it only switches between -pi/2 and +pi/2 in the elevation argument.

You did not see any change in the oscilloscope? The directional information is not only in the gain that you see in the white noise, but also in the sign relative to the W channel. Now we do the same with a very slow sine wave, so that we can observe the phase relations in the channels, chose a freq so that the scope stands still, keep the default zoom value of 1 @ 48000. Compare with the spherical harmonics from the image above, particularly the symetries of the spherical harmonics in the vertical central column and the sign of the sinewave flipping along the z-axis.

Next: Exercise_02_HOA_converting_SN3D_N3D_FuMa