home/ atoms/ atk-azimuth-elevation-convention

The ATK uses a right-hand coordinate system: azimuth 0°=front, positive=counter-clockwise, elevation 0°=horizon

In the ATK, you position sources using azimuth (theta) and elevation (phi), both in radians. The coordinate origin is the listener. X points forward, Y points left, Z points up — the right-hand rule with index=X, middle=Y, thumb=Z. Azimuth 0 = directly ahead. Positive azimuth rotates counter-clockwise: +π/2 (90°) = hard left, −π/2 = hard right, ±π = directly behind. Elevation 0 = horizon; +π/2 = straight up, −π/2 = straight down. This differs from common audio panning conventions where positive rotation is clockwise, and from geographic conventions where azimuth is measured clockwise from north. A frequent mistake is supplying degree values without converting: the ATK always requires radians, so use myDegrees.degrad in SuperCollider.

Examples

FoaEncoderMatrix.newDirection(45.degrad, 0) → encodes 45° left of center, on the horizon. FoaEncoderMatrix.newDirection(pi, 0) → encodes directly behind. FoaRotate.ar(sig, LFSaw.kr(1/12, 0, pi)) → slow CCW rotation.

Assessment

Convert “behind and 30° above the horizon” to ATK azimuth and elevation values in radians. Then identify the error in FoaEncoderMatrix.newDirection(90, 0).

“Azimuth is the rotational angle on the horizontal plane, and by convention, 0 degrees is straight ahead. Positive angular rotation goes counter-clockwise, so 45 degrees is halfway between front and left, negative 45 is halfway bet”
corpus · eli-fieldsteel-supercollider-tutorials-youtube-playlist · chunk 2