是否可以不断地混合音轨并将结果传输到浏览器?

I'm currently trying to work out how and if it's possible to mix audio tracks dynamically in a server environment and stream that result to a client/browser.

Scenario: Let's say we have 3 audio tracks: A, B, and C. I want to be able to mix these in and out on the server according to some code (running constantly) and push the resulting audio as a stream to a consumer/browser. Let's assume for simplicity that A, B, and C are 8 second, looping wav files playing simultaneously and that each of these needs to change in volume randomly at each iteration.

I've looked at SoX, icecast, and some other language specific libraries but so far I don't actually know how this would work. I can't wrap my head around the idea of streaming audio (with no beginning or end point) that is being dynamically rendered constantly, and how the layers would keep in sync with each other. I'm able to use PHP, C# or Node.JS as the backend coding language.

If anyone has any ideas for how to structure a program like this, I'd appreciate the tips.

One possible answer to your question may include a combination of buffering audio packets on the client side with WebAudio as well as sending packets from the server using BinaryJS, which is based on NodeJS. It is likely that other valid implementation strategies exist.