]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
update
authorAnthony Minessale <anthm@freeswitch.org>
Thu, 6 Oct 2011 14:47:34 +0000 (09:47 -0500)
committerAnthony Minessale <anthm@freeswitch.org>
Thu, 6 Oct 2011 14:47:39 +0000 (09:47 -0500)
scripts/perl/tonegen/rtttl2tgml.pl

index a8a3ed0632fc092c7799a09a041b64c6404e5a45..39d4ab715a945a3e5a1c4ceeb8a947de6eec6207 100644 (file)
@@ -56,16 +56,11 @@ if ($r->has_errors()) {
 
 $all = $r->get_notes();
 
-$ms_per_beat = int (60000 / $r->get_bpm());
+$ms_per_beat = int (6000 / $r->get_bpm());
 
 foreach (@{$all}) {
-
-  my $ms = $ms_per_beat * (1 / $_->[0]) * 4;
-
-  #print STDERR "$_->[0] $_->[1] $_->[2] $_->[3]\n";
-  
+  my $ms = ($ms_per_beat * $_->[2]);
   print "%($ms,0,$NOTES->{$_->[1]}->[$_->[2]]);" . $cr;
-
 }