[visionegg] sound? and multitrial program examples?

hi VisionEgg users, I have two issues on which I'd love any advice or pointers:

1. Does anyone have an example of a multi-trial experiment program they could post on the list? It's not clear to me that I'm clearing the viewports and disposing of them properly, and I'd like to see how it should be done.

2. Has anyone found a way to play a sound which provides low variability in latency?
On a 2.3 GHz PowerPC G5 with built-in sound, we have tried:

-pyAudio:  on OSX10.5 and 10.4 we found regular variability of 20 ms

-psychopy.sound: on OSX10.4 it had variability of about 60 ms, and Jon Peirce on Windows reported something closer to 100 ms

-pygame.mixer: on OSX10.5, we often found variability of 50 ms. This library uses SDL I think

-pyOpenAL: has anyone used this? the library looks abandoned

-fastAudio: has anyone used this? it's not currently set up to compile on OSX

-python CoreAudio-0.4: on OSX10.5, it has less than 10 ms variability. Unfortunately it eventually crashes pygame, psychopy, and visionEgg programs (see below)

Overall, python CoreAudio (http://alias.dip.jp/capy/) has the least variability, which is expected since it calls Apple's low-level audio routines. It works fine on its own, but when I add use of it to a psychopy or visionEgg program, it crashes after a number of trials. It even crashes pygame (when it's added to pygame's chimp example program). I suspect the problem is something to do with threading or the GIL, which is way beyond my depth.




Alex Holcombe
www.psych.usyd.edu.au/staff/alexh/


======================================
The Vision Egg mailing list
Archives: http://www.freelists.org/archives/visionegg
Website: http://www.visionegg.org/mailinglist.html

Other related posts: