HOA Technical Notes - B-Format Rotation

Once you have a B-Format audio stream, it's possible to manipulate it in various ways. For instance, you can rotate it using matrix multiplication. This moves all material in the soundfield.

Conventions

This page includes second order rotation matrices for SN3D-encoded B-Format for each of the three axes (X, Y and Z) given a rotation angle. It's possible to form other rotations by combining these. These are left-hand-side matrices (and so should be applied as out[t]=matrix*in[t]).

These rotations are sometimes known as "rotate" (Z), "tilt" (X) and "tumble" (Y) in the Ambisonic literature, or "yaw" (Z), "pitch" (Y) and "roll" (X).

For first order rotation, just use the top left corner four-by-four matrix. For rotations up to third order, you can use the O3A Rotation plugin from the O3A Core VST plugin library.

X Axis Rotation ("Roll")

This rotates around the X (front/back) axis. This is sometimes known as "tilt" in the Ambisonic literature.

ACN 0 In 1 In2 In3 In 4 In5 In6 In7 In8 In
0 Out 1 000 00000
1 Out 0 cos(a)-sin(a)0 00000
2 Out 0 sin(a)cos(a)0 00000
3 Out 0 001 00000
4 Out 0 000 cos(a)00-sin(a)0
5 Out 0 000 0cos(2a)-sqrt(3/4) sin(2a)0-1/2 sin(2a)
6 Out 0 000 0sqrt(3/4) sin(2a)1/4 (1+3cos(2a))0-sqrt(3/16) (1-cos(2a))
7 Out 0 000 sin(a)00cos(a)0
8 Out 0 000 01/2 sin(2a)-sqrt(3/16) (1-cos(2a))01/4 (3+cos(2a))

Y Axis Rotation ("Pitch")

This rotates around the Y (left/right) axis. This is sometimes known as "tumble" in the Ambisonic literature.

ACN 0 In 1 In2 In3 In 4 In5 In6 In7 In8 In
0 Out 1 000 00000
1 Out 0 100 00000
2 Out 0 0cos(a)sin(a) 00000
3 Out 0 0-sin(a)cos(a) 00000
4 Out 0 000 cos(a)-sin(a)000
5 Out 0 000 sin(a)cos(a)000
6 Out 0 000 001/4 (1+3cos(2a))sqrt(3/4) sin(2a)sqrt(3/16) (1-cos(2a))
7 Out 0 000 00-sqrt(3/4) sin(2a)cos(2a)1/2 sin(2a)
8 Out 0 000 00sqrt(3/16) (1-cos(2a))-1/2 sin(2a)1/4 (3+cos(2a))

Z Axis Rotation ("Yaw")

This rotates around the Z (up/down) axis, i.e. horizontally. This is sometimes known as "rotate" in the Ambisonic literature.

ACN 0 In 1 In2 In3 In 4 In5 In6 In7 In8 In
0 Out 1 000 00000
1 Out 0 cos(a)0sin(a) 00000
2 Out 0 010 00000
3 Out 0 -sin(a)0cos(a) 00000
4 Out 0 000 cos(2a)000sin(2a)
5 Out 0 000 0cos(a)0sin(a)0
6 Out 0 000 00100
7 Out 0 000 0-sin(a)0cos(a)0
8 Out 0 000 -sin(2a)000cos(2a)