Changing speaker assignment dinamically in surround 5.1

I am developing an immersive VR environment (dome projection). The player is free to rotate on his axis, motion is captured by an inertial sensor and fed to the camera rotation. Now I am trying to implement the sound. I have the following issue. The Unity encoded 3d sound function assumes that the player is always facing the screen, therefore front objects are always played by the front speakers, rear objects by the rear speakers and so on. In my case the player is free to face any direction, while the speakers are in a fixed physical location in the real world, therefore the static assignment of speakers as front/rear/left/right won’t work. I would need the speakers to be dynamically specified as being front/rear/left/right according to the player line of sight (which we can extract in real time and feed in a C# script).
I was wondering if anyone has any idea of how to do that. I guess that any insight on how the unity 3d sound function assigns speakers location would be a useful starting point.
Thank you very much in advance.

I would have assumed that speaker assignment is done based on the AudioListener component on the camera. Try attaching that component to a GameObject and spinning it around, and see what happens to your audio positioning…

Thanks, indeed it is. I’ll try that and I’ll let you know if it works out.