What exactly does not work?

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

use 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); }
There are plugins available that do filtering, delays, reverbs, oscillators etc. For instance in the CMT library

Good luck
Joost.


In reply to Re: building a "realtime" software synth by Joost
in thread building a "realtime" software synth by b4e

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.