sw17ch/portaudio — pull request #1 by a-wild-tigger (2012-02-18 04:12:51+00:00)
Title: some api changes and an example.

Hi there! This is a great binding! Thanks for all the hardwork. I just wanted to add some changes, specifically:

1. Fixed Some Types in the hsc file to correspond with http://portaudio.com/docs/v19-doxydocs/portaudio_8h.html,

2. Added a working example

3. Added some additional helper functions to the main api.

The reason for 3 is mostly for usability, but its also important that users have access to latency. For instance, with the same C code, we could run at 64 items per buffer, (try changing line 25 in paex_sine.hs), and you'll realize that the sound is very jaggedy, now increase this number to 2000 and its very smooth. This is a result of the number of frames and line 90 where we specify the latency, with low frame count we can fix the sound by changing that to defaultHighOutputLatency.

The issue I believe is the FFI overhead actually becoming noticeable, but if you have other thoughts please let me know.

I hope to write a few more examples and maybe add some functions to the api to deal with high use cases.

Also, are you considering updating the version on hackage? I really think this current version is much simpler and easier to use!