Le Wednesday 12 December 2007 13:24:33 Samuel Mimram, vous avez écrit :
> > Ok, I'll correct only printf that are not binded by a debug parameter
> > then...
>
> Thanks! Do you know if there are any of these?
Here is the patch I will commit.
There a few un-binded printf, I've commented them out, but not for vumeter
since I couldn't understand if the let ... before had anything to do with
real processing..
Romain
Index: visualization/vumeter.ml
===================================================================
--- visualization/vumeter.ml (r�vision 4934)
+++ visualization/vumeter.ml (copie de travail)
@@ -24,6 +24,8 @@
open Source
+let log = Dtools.Log.make ["vumeter"]
+
let screen_width = 80
let rms_max = -5.
let rms_min = -25.
@@ -54,9 +56,9 @@
let vol = Array.fold_left (fun ans s -> ans ^ " " ^ s) "" vol in
let vol = String.sub vol 2 (String.length vol - 2) in
if scroll then
- Printf.printf "%s\n%!" vol
+ log#f 4 "%s\n%!" vol
else
- Printf.printf "\r%s%!" vol
+ log#f 4 "\r%s%!" vol
end
let () =
Index: operators/st_bpm.ml
===================================================================
--- operators/st_bpm.ml (r�vision 4934)
+++ operators/st_bpm.ml (copie de travail)
@@ -42,8 +42,8 @@
n <- n + 1;
if n >= every then
(
- n <- 0;
- Printf.printf "BPM: %.02f\n%!" (Soundtouch.BPM.get_bpm bpm)
+ n <- 0
+ (*Printf.printf "BPM: %.02f\n%!" (Soundtouch.BPM.get_bpm bpm)*)
)
end
Index: operators/pitch.ml
===================================================================
--- operators/pitch.ml (r�vision 4934)
+++ operators/pitch.ml (copie de travail)
@@ -97,10 +97,10 @@
d_opt := d;
wl_opt := l
)
- done;
- let f = samples_per_second /. float !wl_opt in
+ done
+ (*let f = samples_per_second /. float !wl_opt in
let f = if f > freq_max then 0. else f in
- Printf.printf "Found frequency: %.02f (%s)\n%!" f (string_of_note (note_of_freq f))
+ Printf.printf "Found frequency: %.02f (%s)\n%!" f (string_of_note (note_of_freq f))*)
end
let () =