• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Injecting audio from user space into a kernel driver
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Injecting audio from user space into a kernel driver


  • Subject: Re: Injecting audio from user space into a kernel driver
  • From: Nuno Santos <email@hidden>
  • Date: Tue, 03 Sep 2013 16:52:21 +0100

On 09/03/2013 04:30 PM, Paul Davis wrote:
as a first step into the coreaudio API, this is a fairly insane way to begin.

Yeah, it probably is a bit but I don't consider myself to be in a complete darkness. I have a general understanding of the underlying concepts of audio, I just need to get familiar with the API's and I think that with some basic guidelines I can get there since i'm pretty much used to deal with different low level API's (KDMF, IOKit, Linux Kernel).


you can search the archives of this list to find a bit of info about this. however, the internal design of CoreAudio has changed substantially in the last several releases of OS X, and the mechanisms for creating a user space device have changed the most of all. you will find that most of the documentation and examples are inaccurate, incomplete and/or out of date. current header files tend to be the only "definitive" place to get answers.

Since I have already a kernel driver being instantiated i'm sticking to sending the audio to the underlying device from the user space.

I have found Soundflower project source code and it seems that somehow, it is possible to hook audio devices outputs. Soundflower creates a virtual audio device and then you can choose which audio output you want to connect to it. This is pretty much what I want to achieve so I think I'm on the right direction.

Simplifying the question:

To inject audio from user space to a kernel side device, should I look to any particular calls of CoreAudio?

Thanks

there are open source projects such as JACK that do what you are interested in, at least in part but please plan to respect the licensing used. also, be aware that any particular app that does this typically represents only 1 of several different approaches to the problem.


On Tue, Sep 3, 2013 at 11:20 AM, Nuno Santos <email@hidden> wrote:
Hi there,

I 'm building a solution which purpose it's to create a input device for applications to use however, the sound input doesn't come from an hardware device. The idea is to make it come from an user space audio source.

My first approach was to create a kernel driver based on the SimpleAudioDriver with one stereo input source only.

I have already a kernel extension creating the device driver and the applications can actually see it.

My question now is, how is the proper way of injecting audio onto this device driver from user space, in order to keep latency as low as possible?

I thought that it might be possible to create a user space device driver but i'm not sure of it since its my first step into CoreAudio API's. Is it possible? Or am I making the right choices so far?

Is there any example in particular that I should focus my attention on?

I would definitely love to hear the opinion of experienced users.

Thanks in advance,

With my best regards,

Nuno Santos


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Injecting audio from user space into a kernel driver (From: Nuno Santos <email@hidden>)
 >Re: Injecting audio from user space into a kernel driver (From: Paul Davis <email@hidden>)

  • Prev by Date: Re: Injecting audio from user space into a kernel driver
  • Next by Date: Re: Different sample types between Simulator and device
  • Previous by thread: Re: Injecting audio from user space into a kernel driver
  • Next by thread: Re: Different sample types between Simulator and device
  • Index(es):
    • Date
    • Thread