in reply to building a "realtime" software synth
I'm having very nice results with Audio::Play for playing sounds.
As for real time audio manipulation, I think you'd have to use PDL for anything complicated because of performance issues.
Also, (shameless plug here): Have you tried Audio::LADSPA? It uses ladspa plugins to do most of the real processing work, so it should be loads faster than pure perl. I'm not sure if any of the plugins can be compiled for win32, but it might be worth trying.
From the docs for Audio::LADSPA::Network
There are plugins available that do filtering, delays, reverbs, oscillators etc. For instance in the CMT libraryuse Audio::LADSPA::Network; use Audio::LADSPA::Plugin::Play; my $net = Audio::LADSPA::Network->new(); my $sine = $net->add_plugin( label => 'sine_fcac' ); my $delay = $net->add_plugin( label => 'delay_5s' ); my $play = $net->add_plugin('Audio::LADSPA::Plugin::Play'); $net->connect($sine,'Output',$delay,'Input'); $net->connect($delay,'Output',$play,'Input'); $sine->set('Frequency (Hz)' => 440); # set freq $sine->set(Amplitude => 1); # set amp $delay->set('Delay (Seconds)' => 1); # 1 sec delay $delay->set('Dry/Wet Balance' => 0.2); # balance - 0.2 for ( 0 .. 100 ) { $net->run(100); } $sine->set(Amplitude => 0); #just delay from now for ( 0 .. 500 ) { $net->run(100); }
Good luck
Joost.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: building a "realtime" software synth
by b4e (Sexton) on Jul 20, 2004 at 15:26 UTC | |
by Joost (Canon) on Jul 20, 2004 at 15:38 UTC | |
by b4e (Sexton) on Jul 20, 2004 at 15:57 UTC | |
by Joost (Canon) on Jul 20, 2004 at 16:11 UTC | |
by b4e (Sexton) on Jul 20, 2004 at 16:24 UTC | |
|