On 24/02/2012 12:52, Adam Puckett wrote:
My biggest concern with audio programming languages is the audio
callback. I wonder if there is a way on Windows with the classic
mmsystem.h and winmm to get low latency?


This is borderline obsolete these days. It was never possible to get what musicians would call low latency (i.e. below 10msecs) using MME; it was not really designed for "real-time" use anyway, but to support simple file playback and recording. You needed at least DirectSound (which nominally gives you direct access to hardware buffers, at the cost of having to manage double-buffering yourself). With the emergence of Windows2000, you were also limited by the overhead of the Kernel Mixer engine, which sits between the application and the audio hardware, and adds some 30ms of latency (this was introduced partly to support multi-clent access, but mostly to handle as transparently as possible the rendering of multi-channel streams such as 5.1 to stereo or otherwise unmatched hardware). Developers (e.g. Cakewalk for "Sonar") worked around the KM layer by using very low-level IOCTL calls to the hardware (some undocumented), generally called "Kernel Streaming". This eventually became a more or less public and documented API, and portaudio for example supports both Kernel Streaming and the even more recent WASAPI API for Vista onwards.

An added problem, once these newer systems became more generally adopted, was that soundcard manufacturers sometimes only provided a skeleton and far from optimised MME driver, purely to support "legacy" applications, while everyone needing low-latency interactive audio knew that DirectSound or Kernel Streaming (or ASIO, of course) were the only systems to use, especially in full-duplex conditions.


Richard Dobson

--
dupswapdrop -- the music-dsp mailing list and website:
subscription info, FAQ, source code archive, list archive, book reviews, dsp 
links
http://music.columbia.edu/cmc/music-dsp
http://music.columbia.edu/mailman/listinfo/music-dsp

Reply via email to