Getting the final sound buffer from the sound card

I am trying to build a game that takes input in the form of all the audio the player is currently playing. So in theory the user could open and play a sound file, plug in a mic, etc. and the game would be able to react to all of it. However, I’m not sure where to start. I don’t know if FMOD has the functionality needed for that, or if it does how to use it, or what other library might offer something like that. Really any advice would be much appreciated.

it’s not generally possible to pull out the data that the sound card is currently playing.

having said that, there are ways to manually route audio between apps. on a Mac you can use Audio Hijack and on Mac and Linux you can use JACK. it’s not automatic and it requires the end-user to manually route things, however.

Thank you for the help. Granted, I scrapped the idea for the game because I realized even if I could get the data I wouldn’t know what to do with it. But thank you regardless.