changeset 65:5b02163ade2a

inter-onset-intervals bug fix darcs-hash:20070703170032-f76cc-2d3105245bacbb8eb25a568ac8a710af1a07c7af.gz
author David Lewis <d.lewis@gold.ac.uk>
date Tue, 03 Jul 2007 18:00:32 +0100
parents c8f1b0ab0007
children 6c8fd815603e
files utils/utils.lisp
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/utils/utils.lisp	Thu Jun 28 15:49:00 2007 +0100
+++ b/utils/utils.lisp	Tue Jul 03 18:00:32 2007 +0100
@@ -261,13 +261,13 @@
   ;; here?
   ;; FIXME: Should I (do I) filter out 0s?
   (let ((i-o-i-list) (i-o-i-secs-list) (prev)
-	(hits (make-array (/ 32 rounding-divisor))))
+	(hits (make-array (1+ (/ 32 rounding-divisor)))))
     (loop for event being the elements of composition
        do (progn
 	    (when prev
 	      (let* ((i-o-i-period (inter-onset-interval prev event))
 		     (i-o-i (duration i-o-i-period))
-		     (i-o-i-secs (amuse-utils:beats-to-seconds i-o-i-period composition)))
+		     (i-o-i-secs (beats-to-seconds i-o-i-period composition)))
 		(when (= i-o-i-secs 0)
 		  (format t "~D, ~D -- " (timepoint prev) (timepoint event)))
 		(push i-o-i i-o-i-list)