D
Dave Saville
I am playing with sending audio to stereo speakers as part of a bigger
project. At the moment I am just generating a sine wave that moves
from left to right.
I pipe the data to pacat a sample at a time.
open my $PACAT, '|pacat ...................
while(1)
{
# generate $stuff - This is the angle sample value
print $PACAT $stuff; #
}
This works but is a little jerky. Wondering if it were a buffering
problem I tried to make it unbuffered.
open my $PACAT, '|pacat ...................
my $old_fh = select $PACAT; $| = 1; select $old_fh;
while (1)
{
# generate $stuff
print $PACAT $stuff;
}
And it just sits there doing nothing - I assume something has blocked.
project. At the moment I am just generating a sine wave that moves
from left to right.
I pipe the data to pacat a sample at a time.
open my $PACAT, '|pacat ...................
while(1)
{
# generate $stuff - This is the angle sample value
print $PACAT $stuff; #
}
This works but is a little jerky. Wondering if it were a buffering
problem I tried to make it unbuffered.
open my $PACAT, '|pacat ...................
my $old_fh = select $PACAT; $| = 1; select $old_fh;
while (1)
{
# generate $stuff
print $PACAT $stuff;
}
And it just sits there doing nothing - I assume something has blocked.