Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

HAL - how to monitor audio output on a mac

There is an application called wiretap available at
http://www.ambrosiasw.com/utilities/wiretap/

This application can record the system audio. I would like to be able to do the same in my program. Any insights on what I need to do this? I am familiar with Core Audio but havent found anything on how to do this.

would this help getting the answer? I entered the command line: ioreg -w0 -l | grep io |more
this is what I found aboud wiretap....there might be more related info close to where i found it:
+-o com_AmbrosiaSW_AudioSupport <class com_AmbrosiaSW_AudioSupport, registered, matched, active, busy 0, retain 4 >
"CFBundleIdentifier" = "com.AmbrosiaSW.AudioSupport"
"IOMatchCategory" = "com_AmbrosiaSW_AudioSupport"
"version" = 2
"IOClass" = "com_AmbrosiaSW_AudioSupport"
yan-bellavances-mac-mini:~ ybellavance$ ioreg -w0 -l | grep io |more

like image 651
yan bellavance Avatar asked Nov 14 '22 15:11

yan bellavance


1 Answers

The short answer is no, unless you have connections and/or are really experienced/talented (i'm new to mac dev). Guess i'm gonna use the audioEngine example in the Darwin open source section.

Here is the answer I got from Jeff Moore at core-audio mailing list:

"There is no API for doing this, just various hacks/work-arounds that folks have come up with. The most straight forward way would be to write a fake driver to do what you want. Soundflower and JACK would be good examples of this approach. Soundflower uses a kernel driver while JACK uses a user-land driver.

Folks are clever and have come up with other ways to do it as well. But I'll let them speak for themselves if they are inclined to share their techniques. At any rate, you might want to start your education on this by reading the list archives as this topic comes up on a regular basis."

like image 130
yan bellavance Avatar answered Dec 26 '22 12:12

yan bellavance