For those of you who running a Perl script similar to flac2mp3.pl
on a multi core machine, it is an easy task to parallelize your script
and greatly increase processing speed. Note - As flac conversion is a
cpu
intensive task, running a flac job on every core will impair your
computer's response time.
Add the following code in "the appropriate places" to your .pl file.
use Parallel::ForkManager;
# 4 for a quad core machine
my $pm = new Parallel::ForkManager(4);
# this is your main processing loop
while ("still processing flac files") {
$pm->start and next;
# convert a file
$pm->finish;
}
$pm->wait_all_children;
--
pcMusicNewbie
------------------------------------------------------------------------
pcMusicNewbie's Profile: http://forums.slimdevices.com/member.php?userid=15707
View this thread: http://forums.slimdevices.com/showthread.php?t=14697
_______________________________________________
ripping mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/ripping