title: Is there a simple and direct way of using audio as an output for a program?
body: <p>I want to try some C and C++ programming with audio processing, such as synthesizers, chorus, delay etc, but I only know working with a console as output. I wish to have, instead of a console application, a window that would be capable of sending an audio signal to the speakers, running the code at the background and working with it in a similar way as it goes with printf: every time I would call the "output function", it would send to the speakers (or sound card) a sample value, indicating current oscilator position. This output operation could be executed every time it is requested or in the end of a built in loop. Doing all this with a high sample rate would be just great.</p>
  
  <p>I think I could do all this using AudioWorker on Web Audio API, plus a flexible GUI on HTML5 canvas, but I'm new at this API and I'm not sure whether its resulting sound quality is good enough.</p>
  
  <p>Thanks in advance.</p>
  
  <p>Edit: I use Windows 8.1, but any answer for other platform is welcome.</p>
  
  <p>Edit2: Any programming languages other than C, C++ or JavaScript suggestions are also welcome.</p>