NB: this module works only on Linux now and requires an external program! (beep)
Download the whole thing from my CPAN directory.#functional simple way use Beep; beep($freq, $milliseconds); #OO more musical way use Beep; my $beeper = Beep->new(); #lilypond subset syntax accepted my $music = "g f bes c'8 f d4 c8 f d4 bes, c' g, f2"; # Pictures at an Exhibition by Modest Mussorgsky $beeper->play( $music );
Look at http://lilypond.org/ for more info about Lilypond format.
Some questions:
- Is the namespace fine?
- Is anybody willing to write an XS backend? (maybe even simply porting the beep program inside an XS module)
- Any other suggestion is gladly accepted
Update: looking at the posts below i decided the namespace should be Audio::Beep (thanks everybody for the suggestions).
The Prima effort is pretty cool. Looking at the code i think we could take the Win32 beep code directly (i wrote "we" cause i think i will need some help in this). For the Linux backend i would stick to a "beep" (the program) implementation as the one found in Prima requires X.
About the problem with Makefile.PL requiring Perl 5.8: i'm sorry, i don't think we require 5.8. It's just that h2xs produced the Makefile.PL with that header and I didn't realize it was bad. I will update it in next version.
Update2: updated the link to point to my CPAN directory. The new version in Audio::Beep namespace also feature a PurePerl backend (doesn't require the beep executable for root users).
$|=$_="1g2i1u1l2i4e2n0k",map{print"\7",chop;select$,,$,,$,,$_/7}m{..}g
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Beep.pm
by tachyon (Chancellor) on Feb 11, 2003 at 19:38 UTC | |
Re: Beep.pm
by PodMaster (Abbot) on Feb 12, 2003 at 00:35 UTC | |
Re: Beep.pm
by grantm (Parson) on Feb 11, 2003 at 19:58 UTC | |
Re: Beep.pm
by valdez (Monsignor) on Feb 11, 2003 at 19:58 UTC | |
Re: Beep.pm
by belg4mit (Prior) on Feb 11, 2003 at 20:42 UTC | |
Re: Beep.pm
by toma (Vicar) on Feb 12, 2003 at 05:59 UTC | |
Re: Beep.pm
by samtregar (Abbot) on Feb 11, 2003 at 22:26 UTC | |
Re: Beep.pm
by zentara (Archbishop) on Feb 12, 2003 at 23:28 UTC | |
Re: Beep.pm
by t'mo (Pilgrim) on Feb 12, 2003 at 17:47 UTC | |
by giulienk (Curate) on Feb 12, 2003 at 18:03 UTC | |
by t'mo (Pilgrim) on Feb 12, 2003 at 18:57 UTC |