|
Author |
Topic: Delay on moussePressed (Read 1563 times) |
|
PiOtr.
|
Delay on moussePressed
« on: Jan 26th, 2005, 12:01am » |
|
Hello, I downloaded latest version of Sonia and also JSyn plugin. My aim is simply to play a sound on a mouse clic. My problem is I am getting a delay between the clic and the sound being plaid... Here's my code: ---------- Sample sound; void setup () { size(100, 100); Sonia.start(this, 44100); sound = new Sample("sound.wav"); } void mousePressed () { sound.play(); } ---------- The sound is plaid on mouse clic, but I get a half second delay, and this message in the console: ---------- JSyn using native library JSynV142 PortAudio on WMME - Latency = 18432 frames, 417 msec Input Device #0: Mappeur de sons Microsoft - Input has 2 channels Input Device #2: Mappeur de sons Microsoft - Output has 2 channels ---------- Do anybody know what could my problem be? I also tried with an older version of Sonia, it didn't change...
|
Yaaah!
|
|
|
PiOtr
|
Re: Delay on moussePressed
« Reply #1 on: Jan 31st, 2005, 3:58pm » |
|
Hey, I found the solution... In facts I must adjust the system. Check that: http://www.softsynth.com/jsyn/docs/host_pc.html and search for "Adjusting Latency to Remove Glitches" in the page... To edit the Autoexec.bat in Windows XP, I opened a new task: "sysedit" (start menu -> run ->"sysedit")
|
Yaaah!
|
|
|
|